TileKey

public struct TileKey : Hashable

Key of a data source tile.

Note: This is a beta release of this feature and may contain bugs or exhibit unexpected behaviour. Related APIs are subject to change without a deprecation process.

  • x

    X coordinate of the tile. This ranges from 0 to 2^level − 1.

    Declaration

    Swift

    public var x: Int32
  • y

    Y coordinate of the tile. This ranges from 0 to 2^level − 1.

    Declaration

    Swift

    public var y: Int32
  • Level of the tile. Supported range [0, 31].

    Declaration

    Swift

    public var level: Int32
  • Creates a new instance.

    Declaration

    Swift

    public init(x: Int32, y: Int32, level: Int32)
  • Creates a tile key containing specified coordinates at specified storage level and tiling scheme.

    For tiling schemes using Web Mercator projection, the latitude of input coordinates is clamped to [-85.05113, 85.05113] range.

    Declaration

    Swift

    public static func fromGeoCoordinates(_ coordinates: GeoCoordinates, storageLevel: Int32, tilingScheme: TilingScheme) -> TileKey

    Parameters

    coordinates

    The coordinates for which to create the tile key.

    storageLevel

    The storage level of the tile key, clamped to [0, 31].

    tilingScheme

    The tiling scheme to use for the tile key.

    Return Value

    Tile key containing specified coordinates.