AWFMKAnnotationView
Objective-C
@interface AWFMKAnnotationView : MKAnnotationView <AWFAnnotationView>
Swift
class AWFMKAnnotationView : MKAnnotationView, AWFAnnotationView
The AWFMKAnnotationView
class is a sublcass of MKAnnotationView
that supports annotation style and animation effects
when rendered on an Apple MapKit map view.
-
The annotation object currently associated with the view.
Declaration
Objective-C
@property (nonatomic, strong) AWFMKAnnotation *_Nonnull annotation;
Swift
var annotation: AWFMKAnnotation { get set }
-
The annotation style used for rendering the annotation.
Declaration
Objective-C
@property (nonatomic, strong, readonly, nullable) AWFAnnotationStyle *style;
Swift
var style: AWFAnnotationStyle? { get }
-
The layer in which the annotation is rendered.
Declaration
Objective-C
@property (nonatomic, strong, readonly) CAShapeLayer *_Nonnull pointLayer;
Swift
var pointLayer: CAShapeLayer { get }
-
A Boolean value that determines whether the annotation view should reduce or eliminate animations.
Declaration
Objective-C
@property (nonatomic) BOOL reduceAnimatedEffects;
Swift
var reduceAnimatedEffects: Bool { get set }
-
A Boolean value that determines whether the annotation view should be rendered before being added to a map view.
Declaration
Objective-C
@property (nonatomic) BOOL needsDisplayBeforeAddingToMap;
Swift
var needsDisplayBeforeAddingToMap: Bool { get set }
-
A Boolean value that indicates whether the initial presentation animation has completed.
Declaration
Objective-C
@property (nonatomic, readonly) BOOL hasAnimationCompleted;
Swift
var hasAnimationCompleted: Bool { get }
-
Initializes and returns a newly allocated annotation view for the specified annotation, identifier and style.
Declaration
Objective-C
- (nonnull instancetype)initWithAnnotation:(nonnull AWFMKAnnotation *)annotation reuseIdentifier:(nonnull NSString *)reuseIdentifier style:(nullable AWFAnnotationStyle *)style;
Swift
init(annotation: AWFMKAnnotation, reuseIdentifier: String, style: AWFAnnotationStyle?)
Parameters
annotation
The annotation object to associate with the view.
reuseIdentifier
The identifier string for the view when reusing annotation views.
style
The style specification for the annotation view.
Return Value
An initialized annotation view.
-
Performs the presentation animation if one has been configured with for the associated annotation
style
.If the annotation belongs to a timeline animation, this animation will be only be performed once instead of repeating.
Declaration
Objective-C
- (void)startAnimating;
Swift
func startAnimating()
-
Removes all animations from the annotation.
Declaration
Objective-C
- (void)stopAnimating;
Swift
func stopAnimating()
-
Performs the dismissal animation if one has been configured with for the associated annotation
style
.Declaration
Objective-C
- (void)animateOut;
Swift
func animateOut()