Protocol

MKAnnotation

An interface for associating your content with a specific map location.

Overview

An object that adopts this protocol manages the data that you want to display on the map surface. It does not provide the visual representation displayed by the map. Instead, your map view's delegate provides the MKAnnotationView objects needed to display the content of your annotations. When you want to display content at a specific point on the map, add an annotation object to the map view. When the annotation's coordinate is visible on the map, the map view asks its delegate to provide an appropriate view to display any content associated with the annotation. You implement the mapView:viewForAnnotation: method of the delegate to provide that view.

An object that adopts this protocol must implement the coordinate property. The other methods of this protocol are optional.

Topics

Position Attributes

coordinate

The center point (specified as a map coordinate) of the annotation.

Required.

setCoordinate:

Sets the new center point of the annotation.

Title Attributes

title

The string containing the annotation’s title.

subtitle

The string containing the annotation’s subtitle.

Relationships

Inherits From

Inherited By

See Also

Annotations and Overlays

MKPlacemark

A user-friendly description of a location on the map.

MKAnnotationView

The visual representation of one of your annotation objects.

MKOverlay

An interface for associating content with a specific map region.

MKOverlayRenderer

The shared infrastructure used to draw overlays on the map surface.

MapKit Annotations

Use these annotation objects as-is in your maps.

MapKit Overlays

Use these overlays as-is in your maps.