Interface AssetsProvider

com.yandex.mapkit.search.search_layer

public interface AssetsProvider

Interface for providing images, image sizes and icon styles to the search layer.

Call with static_cast<int>(PlacemarkIconType) in all methods.

Methods

IconStyle iconStyle(@NonNull SearchResultItem searchResult, int placemarkIconType)

Returns the icon style for certain placemark type with given search result.

ImageProvider image(@NonNull SearchResultItem searchResult, int placemarkIconType)

Returns an image for certain placemark type with given search result.

Size size(@NonNull SearchResultItem searchResult, int placemarkIconType)

Returns the size of the icon of certain placemark type with given search result.

Method Detail

iconStyle

public IconStyle iconStyle (@NonNull SearchResultItem searchResult, int placemarkIconType)

Returns the icon style for certain placemark type with given search result.

If obtainAdIcons mode is enabled, IconStyle.anchor will be replaced for advertisement pins

image

public ImageProvider image (@NonNull SearchResultItem searchResult, int placemarkIconType)

Returns an image for certain placemark type with given search result.

size

public Size size (@NonNull SearchResultItem searchResult, int placemarkIconType)

Returns the size of the icon of certain placemark type with given search result.