Skip to contents

Map manager class

Map manager class

Details

Definition for the MapManager class.

The argument to value should be a list with the following elements:

id

character (optional) name of layer.

setting

character name of setting. Available options are: "order", "feature_order" and "visible". Note that the "id" element is required for "feature_order" and "visible" settings.

id

character (optional) identifier for layer.

setting

character name of setting. Available options are: "order", "remove", "visible", "feature_order", "feature_visible". Note that the "id"element is required for"remove", "visible", "feature_order", "feature_visible" settings.} \item{value}{numericorlogical` value for new setting.

Public fields

layers

list of Theme, Weight, Include, Exclude, Solution objects.

ids

character vector of identifiers for the layers.

order

numeric vector indicating the order each layer should appear on them map. A value of 1 indicates that a layer should appear beneath every other layer.

Methods


Method new()

Create a MapManager object.

Usage

MapManager$new(layers, order)

Arguments

layers

list of Theme, Weight, Include, Exclude, Solution objects.

order

numeric vector.

Returns

A new MapManager object.


Method print()

Print the object.

Usage

MapManager$print(...)

Arguments

...

not used.


Method repr()

Generate a character summarizing the representation of the object.

Usage

MapManager$repr()

Returns

character value.


Method get_order()

Get information on the plot order of each layer.

Usage

MapManager$get_order()


Method get_layer()

Get a layer.

Usage

MapManager$get_layer(value)

Arguments

value

character layer identifier.

Returns

Theme object.


Method get_layer_names()

Get layer names.

Usage

MapManager$get_layer_names(download_only)

Arguments

download_only

get only layer names that are flagged as downloadable. Available options are TRUE or FALSE.

Returns

character vector.


Method get_layer_indices()

Get layer index values.

Usage

MapManager$get_layer_indices(download_only)

Arguments

download_only

get only layer indices that are flagged as downloadable. Available options are TRUE or FALSE.

Returns

character vector.


Method get_layer_ids()

Get layer ids values.

Usage

MapManager$get_layer_ids()

Returns

character vector.


Method get_layer_panes()

Get panes.

Usage

MapManager$get_layer_panes()

Returns

character vector.


Method get_layer_visible()

Get layer visible values.

Usage

MapManager$get_layer_visible()

Returns

character vector.


Method get_layer_invisible()

Get layer invisible values.

Usage

MapManager$get_layer_invisible()

Returns

date/time vector.


Method get_layer_loaded()

Get layer loaded values.

Usage

MapManager$get_layer_loaded()

Returns

logical vector.


Method get_setting()

Get a setting for the object.

Usage

MapManager$get_setting(value)

Arguments

value

list with setting information (see Details section)


Method set_order()

Set information on the plot order of each layer.

Usage

MapManager$set_order(value)

Arguments

value

logical vector indicating if each layer is visible or not.


Method set_visible()

Set visibility for all layers.

Usage

MapManager$set_visible(value)

Arguments

value

logical vector indicating if layers should be visible or not.


Method set_loaded()

Set loaded for all layers.

Usage

MapManager$set_loaded(value)

Arguments

value

logical vector indicating if layers are loaded or not.


Method set_setting()

Set a setting for the object.

Usage

MapManager$set_setting(value)

Arguments

value

list with new setting information (see Details section)


Method add_layer()

Add a new layer.

Usage

MapManager$add_layer(value, map)

Arguments

value

Layer object.

map

leaflet::leafletProxy() object.


Method drop_layer()

Remove a layer.

Usage

MapManager$drop_layer(value, map)

Arguments

value

character layer identifier.

map

leaflet::leafletProxy() object.


Method get_widget_data()

Get data for displaying the theme in a mapManager() widget.

Usage

MapManager$get_widget_data()

Returns

list with widget data.


Method get_group_layer_ids()

Get group layer ids.

Usage

MapManager$get_group_layer_ids()

Returns

character vector.


Method get_layer_classes()

Get group layer ids.

Usage

MapManager$get_layer_classes()

Returns

character vector.


Method get_lazyload()

Get data frame of map manager layers.

Usage

MapManager$get_lazyload()

Returns

data.frame object.


Method initialize_map()

Initial map by adding data to it.

Usage

MapManager$initialize_map(map)

Arguments


Method update_map()

Update map.

Usage

MapManager$update_map(map)

Arguments


Method delete_sinlge_map_pane()

Delete single map pane

Usage

MapManager$delete_sinlge_map_pane(map)

Arguments


Method delete_all_map_panes()

Delete all map panes.

Usage

MapManager$delete_all_map_panes(map)

Arguments


Method clone()

The objects of this class are cloneable with this method.

Usage

MapManager$clone(deep = FALSE)

Arguments

deep

Whether to make a deep clone.