Instance Method

insertOverlay:atIndex:level:

Inserts an overlay object into the level at the specified index.

Declaration

- (void)insertOverlay:(id<MKOverlay>)overlay atIndex:(NSUInteger)index level:(MKOverlayLevel)level;

Parameters

overlay

The overlay object to insert.

index

The index at which to insert the overlay object. If this value is greater than the number of objects in the overlays property, this method appends the object to the end of the array.

level

The map level at which to place the overlay. For a list of possible values for this parameter, see MKOverlayLevel.

Discussion

Inserting an overlay at a specific level places that overlay’s visual representation in front of or behind other map content such as map labels and point-of-interest icons.

See Also

Adding and Inserting Overlays

addOverlay:level:

Adds the overlay object to the map at the specified level.

addOverlays:level:

Adds an array of overlay objects to the map at the specified level.

addOverlay:

Adds a single overlay object to the map.

addOverlays:

Adds an array of overlay objects to the map.

insertOverlay:atIndex:

Inserts an overlay object into the list associated with the map.

insertOverlay:aboveOverlay:

Inserts one overlay object on top of another.

insertOverlay:belowOverlay:

Inserts one overlay object below another.

exchangeOverlay:withOverlay:

Exchanges the positions of the two overlay objects.

exchangeOverlayAtIndex:withOverlayAtIndex:

Exchanges the position of two overlay objects.