HERE iOS SDK Developer's Guide

<NMAMapViewDelegate>

Protocol Summary

protocol <NMAMapViewDelegate>

Derived from: <NSObject>

Represents a delegate that offers listeners and callback methods related to visible actions that result from user interaction.

Include: NMAKit.framework/headers/NMAMapView.h

Inheritance Diagrams

Figure 1. Public inheritance diagram for <NMAMapViewDelegate> – <NMAMapViewDelegate>

[For complete information, see the section Protocol Details]

Instance Method Summary

Table 1. Instance Methods
Instance Method Summary

- @optional (void) mapView:(nonnull NMAMapView *) mapView didRenderBitmap:(nonnull void *) bitmap withWidth:(NSUInteger) width height:(NSUInteger) height bytesPerPixel:(NSUInteger) bytesPerPixel

A callback indicating that the map has been drawn to a bitmap by the software renderer

- @optional (void) mapView:(nonnull NMAMapView *) mapView didSelectObjects:(nonnull NSArray< NMAViewObject * > *) objects

A callback indicating that NMAViewObject objects have been selected

- @optional (void) mapViewDidBeginAnimation:(nonnull NMAMapView *) mapView

A callback indicating the beginning of an animation on the map

- @optional (void) mapViewDidBeginMovement:(nonnull NMAMapView *) mapView

A callback indicating that a map movement has begun due to user interaction

- @optional (void) mapViewDidDraw:(nonnull NMAMapView *) mapView

A callback indicating that map data has been drawn

- @optional (void) mapViewDidEndAnimation:(nonnull NMAMapView *) mapView

A callback indicating the end of an animation on the map

- @optional (void) mapViewDidEndMovement:(nonnull NMAMapView *) mapView

A callback indicating that a map movement has ended

Protocol Details

Represents a delegate that offers listeners and callback methods related to visible actions that result from user interaction.

Note:

Methods of this protocol are called on the main queue.

Instance Method Details

- @optional (void) mapView:(nonnull NMAMapView *) mapView didRenderBitmap:(nonnull void *) bitmap withWidth:(NSUInteger) width height:(NSUInteger) height bytesPerPixel:(NSUInteger) bytesPerPixel

A callback indicating that the map has been drawn to a bitmap by the software renderer.

This method will not be called if the softwareRenderToBitmap property is set to NO or if software rendering is not currently active. See the softwareRenderToBitmap property for more information.

IMPORTANT: Software Rendering is a Beta feature, and associated methods and behaviours are subject to change without notice.

Note:

This method is called on NMAMapView's render thread and not the main thread. Spending a lot of time in this callback will degrade map rendering performance.

Parameters:

  • mapView

    The NMAMapView instance sending the callback.

  • bitmap

    Bitmap data in the NMAPixelFormatRGBA format. IT IS ONLY SAFE TO ACCESS THE BITMAP IN THE CONTEXT OF THIS CALLBACK.

  • width

    Width of the bitmap in pixels.

  • height

    Height of the bitmap in pixels.

  • bytesPerPixel

    Number of bytes used to represent the color of each pixel.

- @optional (void) mapView:(nonnull NMAMapView *) mapView didSelectObjects:(nonnull NSArray< NMAViewObject * > *) objects

A callback indicating that NMAViewObject objects have been selected.

Parameters:

  • mapView

    The NMAMapView instance sending the callback

  • objects

    A NSArray of selected objects

- @optional (void) mapViewDidBeginAnimation:(nonnull NMAMapView *) mapView

A callback indicating the beginning of an animation on the map.

This is fired after one of the following operations starts:
  • setting the map center (with animation). E.g. with NMAMapView setCenter:
  • setting the map orientation (with animation). E.g. with NMAMapView setOrientation:
  • setting the map tilt (with animation). E.g. with NMAMapView setTilt:
  • setting the map zoom level (with animation). E.g. with NMAMapView setZoomLevel:

- @optional (void) mapViewDidBeginMovement:(nonnull NMAMapView *) mapView

A callback indicating that a map movement has begun due to user interaction.

This callback will be sent at the start of the gesture when the map is panned, tilted, pinch zoomed, or rotated (only for user gestures).

Note:

If the map receives more than one of these gestures at the same time, only a single callback will be sent until all map movement has stopped.

- @optional (void) mapViewDidDraw:(nonnull NMAMapView *) mapView

A callback indicating that map data has been drawn.

- @optional (void) mapViewDidEndAnimation:(nonnull NMAMapView *) mapView

A callback indicating the end of an animation on the map.

This is fired after one of the following operations ends:
  • setting the map center (with animation). E.g. with NMAMapView setCenter:
  • setting the map orientation (with animation). E.g. with NMAMapView setOrientation:
  • setting the map tilt (with animation). E.g. with NMAMapView setTilt:
  • setting the map zoom level (with animation). E.g. with NMAMapView setZoomLevel:

- @optional (void) mapViewDidEndMovement:(nonnull NMAMapView *) mapView

A callback indicating that a map movement has ended.

Note:

There will be a one-to-one correspondence with this callback and the mapViewDidBeginMovement callback.