YMKIcon

class YMKIcon : YMKPlacemarkPresentation

Provides an interface to set icon and its style for a placemark.

Summary

Instance methods

func setImageWith(_ image: UIImage)
Sets the image for the icon

func setImageWith(_ image: UIImage, style: YMKIconStyle?)
Sets the image for the icon

func setImageWith(_ image: UIImage,
                    style: YMKIconStyle?,
                 callback: YMKCallback? = nil)
Sets the image for the icon

func setViewWithView(_ view: YRTViewProvider)
Sets the view for the icon

func setViewWithView(_ view: YRTViewProvider, style: YMKIconStyle?)
Sets the view for the icon

func setViewWithView(_ view: YRTViewProvider,
                      style: YMKIconStyle?,
                   callback: YMKCallback? = nil)
Sets the view for the icon

Properties

var styleYMKIconStyle { get set }
The style properties (scale, zIndex, etc

Instance methods

setImageWith(_:)

func setImageWith(_ image: UIImage)

Sets the image for the icon.

Parameters

style

The icon style. If not specified, the default style is used.

onFinished

Optional callback invoked when the icon is loaded.


setImageWith(_:style:)

func setImageWith(_ image: UIImage, style: YMKIconStyle?)

Sets the image for the icon.

Parameters

style

The icon style. If not specified, the default style is used.

onFinished

Optional callback invoked when the icon is loaded.


setImageWith(_:style:callback:)

func setImageWith(_ image: UIImage,
                    style: YMKIconStyle?,
                 callback: YMKCallback? = nil)

Sets the image for the icon.

Parameters

style

The icon style. If not specified, the default style is used.

onFinished

Optional callback invoked when the icon is loaded.


setViewWithView(_:)

func setViewWithView(_ view: YRTViewProvider)

Sets the view for the icon.

Parameters

style

The icon style. If not specified, the default style is used.

onFinished

Optional callback invoked when the icon is loaded.


setViewWithView(_:style:)

func setViewWithView(_ view: YRTViewProvider, style: YMKIconStyle?)

Sets the view for the icon.

Parameters

style

The icon style. If not specified, the default style is used.

onFinished

Optional callback invoked when the icon is loaded.


setViewWithView(_:style:callback:)

func setViewWithView(_ view: YRTViewProvider,
                      style: YMKIconStyle?,
                   callback: YMKCallback? = nil)

Sets the view for the icon.

Parameters

style

The icon style. If not specified, the default style is used.

onFinished

Optional callback invoked when the icon is loaded.


Properties

style

var style: YMKIconStyle { get set }

The style properties (scale, zIndex, etc.) of the icon placemark. Note: The current style cannot be modified directly - you must reset it to apply changes.