MapMarkerAnimation

public class MapMarkerAnimation
extension MapMarkerAnimation: NativeBase
extension MapMarkerAnimation: Hashable

An animation that can be applied to the MapMarker object.

  • Thrown when a problem occurs while trying to create a MapMarkerAnimation.

    Declaration

    Swift

    public typealias InstantiationError = InstantiationErrorCode
  • Creates an animation of MapMarker based on provided keyframe track.

    Supports tracks created with MapItemKeyFrameTrack ‘moveTo’, ‘scale’ and ‘opacity’ methods.

    For starting the animation see MapMarker.startAnimation(...) or MapMarker3D.startAnimation(...).

    Throws

    MapMarkerAnimation.InstantiationError If the specified keyframe track cannot be used to create animation of a marker.

    Declaration

    Swift

    public init(track: MapItemKeyFrameTrack) throws

    Parameters

    track

    The track holding the keyframes for the animation.

  • Creates an animation based on multiple keyframe tracks.

    Allows combining multiple property animations (e.g. scale and opacity) into a single animation that plays them simultaneously.

    Throws

    MapMarkerAnimation.InstantiationError If the list of tracks is empty or any of the specified keyframe tracks cannot be used to create animation of a marker.

    Declaration

    Swift

    public init(tracks: [MapItemKeyFrameTrack], repeatCount: Int32) throws

    Parameters

    tracks

    List of keyframe tracks for the animation. Must not be empty.

    repeatCount

    Number of times to play the animation. 0 means repeat infinitely, 1 means play once, N means play N times. Negative values are treated as 1. The duration of one iteration is determined by the longest track. Shorter tracks hold their final value until the iteration ends. When repeating, all tracks restart together from their first keyframe without interpolation from the previous iteration’s last keyframe.

  • Describes a reason for failing to create a MapMarkerAnimation.

    See more

    Declaration

    Swift

    public enum InstantiationErrorCode : UInt32, CaseIterable, Codable
    extension MapMarkerAnimation.InstantiationErrorCode : Error