Class YMKAnimatedIcon

Animated placemark icon.

Provides an interface to load and control animation.

Instance Methods

- pause

Pauses animation.

- play

Starts animation.

- playWithCallback:

Starts animation and handles the callback.

- resume

Resumes paused animation.

- setIconStyleWithStyle:

Changes the icon style.

- setIconWithImage:style:

Sets the animated icon and its style.

- setIconWithImage:style:callback:

Sets the animated icon and its style.

- stop

Stops animation.

Properties

reversed

If true, animation will be played in the reverse direction.

valid

Tells if this object is valid or no.

Method Detail

-pause

- (void)pause

Pauses animation.

-play

- (void)play

Starts animation.

Removes the current play callback. Same as play(null).

-playWithCallback:

- (void)playWithCallback:(nonnull YMKCallback)callback 

Starts animation and handles the callback.

Parameters:
onFinished

is called when animation finishes and replaces the previous callback.

-resume

- (void)resume

Resumes paused animation.

Callback (if any) is NOT removed.

-setIconStyleWithStyle:

- (void)setIconStyleWithStyle:(nonnull YMKIconStyle *)style 

Changes the icon style.

-setIconWithImage:style:

- (void)setIconWithImage:(nonnull id< YRTAnimatedImageProvider >)image
                   style:(nonnull YMKIconStyle *)style 

Sets the animated icon and its style.

Animation is created in the paused state.

-setIconWithImage:style:callback:

- (void)setIconWithImage:(nonnull id< YRTAnimatedImageProvider >)image
                   style:(nonnull YMKIconStyle *)style
                callback:(nonnull YMKCallback)callback 

Sets the animated icon and its style.

Animation is created in the paused state.
Parameters:
onFinished

is called when the icon is loaded.

-stop

- (void)stop

Stops animation.

Animation returns to the initial paused state.

Property Detail

reversed

(assign, readwrite, getter=isReversed) BOOL reversed

If true, animation will be played in the reverse direction.

Default value is false.

valid

(assign, readonly, getter=isValid) BOOL valid

Tells if this object is valid or no.

Any method called on an invalid object will throw an exception. The object becomes invalid only on UI thread, and only when its implementation depends on objects already destroyed by now. Please refer to general docs about the interface for details on its invalidation.