AWFMapContentDelegate

Objective-C

@protocol AWFMapContentDelegate <NSObject>

Swift

protocol AWFMapContentDelegate : NSObjectProtocol

The AWFMapContentDelegate protocol defines a set of optional methods that can be used to receive messages related to data changes for a particular map content source. The delegate should handle any data cleanup on the map that is required in response to these messages.

  • Tells the delegate that the map source is about to request data for the layer with the specified options. This is called immediately before the request begins and allows you to override request options as needed.

    Declaration

    Objective-C

    - (void)contentSource:(nonnull AWFMapContentSource *)source
        willRequestDataWithOptions:(id)options;

    Swift

    optional func contentSource(_ source: AWFMapContentSource, willRequestDataWithOptions options: Any!)

    Parameters

    source

    The map content source that is about to perform the request

    options

    The request options

  • Tells the delegate that the map source will remove an array of annotation from the map. This is called before the annotations property on the map source will be reset with a new value.

    Declaration

    Objective-C

    - (void)contentSource:(nonnull AWFMapContentSource *)source
        willRemoveAnnotations:(nonnull NSArray<id<AWFAnnotation>> *)annotations;

    Swift

    optional func contentSource(_ source: AWFMapContentSource, willRemove annotations: [AWFAnnotation])

    Parameters

    source

    The map content source that will remove annotations

    annotations

    An array of annotations that will be removed

  • Tells the delegate that the map source will remove an array of overlays from the map. This is called before the overlays property on the map source will be reset with a new value.

    Declaration

    Objective-C

    - (void)contentSource:(nonnull AWFMapContentSource *)source
        willRemoveOverlays:(nonnull NSArray *)overlays;

    Swift

    optional func contentSource(_ source: AWFMapContentSource, willRemoveOverlays overlays: [Any])

    Parameters

    source

    The map content source that will remove overlays

    overlays

    An array of overlays that will be removed

  • Tells the delegate that the map source needs to be invalidated.

    Declaration

    Objective-C

    - (void)contentSourceNeedsInvalidating:(nonnull AWFMapContentSource *)source;

    Swift

    optional func contentSourceNeedsInvalidating(_ source: AWFMapContentSource)

    Parameters

    source

    The map content source that requested the invalidation.