YMKCompositeIcon

class YMKCompositeIcon : YMKPlacemarkPresentation

Combines multiple icons into one.

Summary

Instance methods

func setIconWithName(_ name: String, image: UIImage)
Creates or resets a named layer with an icon and its style

func setIconWithName(_ name: String, image: UIImage, style: YMKIconStyle?)
Creates or resets a named layer with an icon and its style

func setIconWithName(_ name: String,
                      image: UIImage,
                      style: YMKIconStyle?,
                   callback: YMKCallback? = nil)
Creates or resets a named layer with an icon and its style

func setIconStyleWithName(_ name: String, style: YMKIconStyle)
Changes the icon style for a specific layer

func icon(withName name: String) -> YMKIcon
Returns named Icon object that can be used to set icon and its style

func remove(withName name: String)
Removes the named layer

func removeAll()
Removes all layers

Instance methods

setIconWithName(_:image:)

func setIconWithName(_ name: String, image: UIImage)

Creates or resets a named layer with an icon and its style.

Parameters

name

Unique identifier of the icon layer. Used to create or update.

style

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

onFinished

Optional callback invoked when the icon is loaded.


setIconWithName(_:image:style:)

func setIconWithName(_ name: String, image: UIImage, style: YMKIconStyle?)

Creates or resets a named layer with an icon and its style.

Parameters

name

Unique identifier of the icon layer. Used to create or update.

style

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

onFinished

Optional callback invoked when the icon is loaded.


setIconWithName(_:image:style:callback:)

func setIconWithName(_ name: String,
                      image: UIImage,
                      style: YMKIconStyle?,
                   callback: YMKCallback? = nil)

Creates or resets a named layer with an icon and its style.

Parameters

name

Unique identifier of the icon layer. Used to create or update.

style

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

onFinished

Optional callback invoked when the icon is loaded.


setIconStyleWithName(_:style:)

func setIconStyleWithName(_ name: String, style: YMKIconStyle)

Changes the icon style for a specific layer.


icon(withName:)

func icon(withName name: String) -> YMKIcon

Returns named Icon object that can be used to set icon and its style. Creates an empty Icon if it didn't exist.


remove(withName:)

func remove(withName name: String)

Removes the named layer.


removeAll()

func removeAll()

Removes all layers.