Inherits from RMAnnotation : NSObject
Declared in RMShapeAnnotation.h

Overview

An RMShapeAnnotation is an abstract subclass of RMAnnotation that is used to represent a shape consisting of one or more points. You should not create instances of this class directly. Instead, you should create instances of the RMPolylineAnnotation or RMPolygonAnnotation classes. However, you can use the properties of this class to access information about the specific points associated with the line or polygon.

Providing a layer manually for instances of RMShapeAnnotation subclasses will not have any effect.

Properties

fillColor

A fill color for the annotation’s shape.

@property (nonatomic, strong) UIColor *fillColor

Discussion

A fill color for the annotation’s shape.

Declared In

RMShapeAnnotation.h

lineColor

A line color for the annotation’s shape.

@property (nonatomic, strong) UIColor *lineColor

Discussion

A line color for the annotation’s shape.

Declared In

RMShapeAnnotation.h

lineWidth

A line width for the annotation’s shape.

@property (nonatomic, assign) CGFloat lineWidth

Discussion

A line width for the annotation’s shape.

Declared In

RMShapeAnnotation.h

points

The array of points associated with the shape. (read-only)

@property (nonatomic, readonly, strong) NSArray *points

Discussion

The array of points associated with the shape. (read-only)

Declared In

RMShapeAnnotation.h

Instance Methods

initWithMapView:points:

Initialize a shape annotation.

- (id)initWithMapView:(RMMapView *)aMapView points:(NSArray *)points

Parameters

aMapView

The map view on which to place the annotation.

points

An array of CLLocation points defining the shape. The data in this array is copied to the new object.

Return Value

An initialized shape annotation object, or nil if an annotation was unable to be initialized.

Discussion

Initialize a shape annotation.

Declared In

RMShapeAnnotation.h