AWFTileDataSource

Objective-C

@protocol AWFTileDataSource <NSObject>

Swift

protocol AWFTileDataSource : NSObjectProtocol

The AWFTileDataSource protocol is adopted by an object that provides information a tile overlay needs to request and load tiles.

  • Returns the URL for the specified tile path structure.

    Declaration

    Objective-C

    - (nonnull NSURL *)URLForTilePath:(nonnull AWFTileOverlayPath *)path;

    Swift

    func url(forTilePath path: AWFTileOverlayPath) -> URL

    Parameters

    path

    The path structure that identifies the specific tile.

    Return Value

    The URL to use to retrive the tile.

  • Returns the tile URL for the region defined by the specified coordinate bounds, image size and time string for the data relative to the current time.

    Declaration

    Objective-C

    - (nonnull NSURL *)URLForBounds:(nonnull AWFMapCoordinateBounds *)bounds
                               size:(CGSize)size
                          timestamp:(nonnull NSString *)timestamp;

    Swift

    func url(for bounds: AWFMapCoordinateBounds, size: CGSize, timestamp: String) -> URL

    Parameters

    bounds

    The region’s coordinate bounds.

    size

    The image size.

    timestamp

    The time string to use for the data.