Class LayerOptions

com.yandex.mapkit.layers

java.lang.Object ⇽ LayerOptions

public class LayerOptions

Options that are used when adding a layer to the map.

Constructors

LayerOptions(boolean active, boolean nightModeAvailable, boolean cacheable, boolean animateOnActivation, @NonNull OverzoomMode overzoomMode)
LayerOptions()

Use constructor with parameters in your code.

Methods

boolean getActive()

Inactive layers are not displayed on the map and do not request any tiles from TileProvider.

boolean getAnimateOnActivation()

Indicates whether layer activation should be animated.

boolean getCacheable()

Determines whether tiles are cached on persistent storage or not.

boolean getNightModeAvailable()

Indicates the availability of night mode for this layer (for example, night mode is disabled for the satellite layer).

OverzoomMode getOverzoomMode()

Whether to render tiles from adjacent zoom levels in place of absent or translucent tiles.

void serialize(Archive archive)
LayerOptions setActive(boolean active)

See getActive().

LayerOptions setAnimateOnActivation(boolean animateOnActivation)

See getAnimateOnActivation().

LayerOptions setCacheable(boolean cacheable)

See getCacheable().

LayerOptions setNightModeAvailable(boolean nightModeAvailable)

See getNightModeAvailable().

LayerOptions setOverzoomMode(@NonNull OverzoomMode overzoomMode)

See getOverzoomMode().

Constructor Detail

LayerOptions

public LayerOptions (boolean active, boolean nightModeAvailable, boolean cacheable, boolean animateOnActivation, @NonNull OverzoomMode overzoomMode)

LayerOptions

public LayerOptions ()

Use constructor with parameters in your code.

This one is for bindings only!

Method Detail

getActive

public boolean getActive ()

Inactive layers are not displayed on the map and do not request any tiles from TileProvider.

getAnimateOnActivation

public boolean getAnimateOnActivation ()

Indicates whether layer activation should be animated.

getCacheable

public boolean getCacheable ()

Determines whether tiles are cached on persistent storage or not.

getNightModeAvailable

public boolean getNightModeAvailable ()

Indicates the availability of night mode for this layer (for example, night mode is disabled for the satellite layer).

Default: true.

getOverzoomMode

public OverzoomMode getOverzoomMode ()

Whether to render tiles from adjacent zoom levels in place of absent or translucent tiles.

serialize

public void serialize (Archive archive)

setActive

public LayerOptions setActive (boolean active)

See getActive().

setAnimateOnActivation

public LayerOptions setAnimateOnActivation (boolean animateOnActivation)

See getAnimateOnActivation().

setCacheable

public LayerOptions setCacheable (boolean cacheable)

See getCacheable().

setNightModeAvailable

public LayerOptions setNightModeAvailable (boolean nightModeAvailable)

See getNightModeAvailable().

setOverzoomMode

public LayerOptions setOverzoomMode (@NonNull OverzoomMode overzoomMode)

See getOverzoomMode().