Skip to main content

MarkerLayerToolState

geovisto-map • Readme | API


geovisto-map / MarkerLayerToolState

Class: MarkerLayerToolState

This class provide functions for using the state of the layer tool.

Author​

Jiri Hynek

Extends​

Implements​

Constructors​

new MarkerLayerToolState()​

new MarkerLayerToolState(tool): MarkerLayerToolState

It creates a tool state.

Parameters​

• tool: IMarkerLayerTool\<IMarkerLayerToolProps, IMarkerLayerToolDefaults, IMarkerLayerToolState\<IMarkerLayerToolProps, IMarkerLayerToolDefaults, IMarkerLayerToolConfig, object, object>, IMarkerLayerToolConfig, IMapToolInitProps\<IMarkerLayerToolConfig>>

Returns​

MarkerLayerToolState

Overrides​

LayerToolState.constructor

Source​

tools/layers/marker/model/internal/tool/MarkerLayerToolState.ts:34

Properties​

bucketData​

private bucketData: Map\<string, Map\<string, IMapAggregationBucket>>

Source​

tools/layers/marker/model/internal/tool/MarkerLayerToolState.ts:28


currentDataCategories​

private currentDataCategories: string[]

Source​

tools/layers/marker/model/internal/tool/MarkerLayerToolState.ts:27


layerGroup?​

private optional layerGroup: any

Source​

tools/layers/marker/model/internal/tool/MarkerLayerToolState.ts:29


markers​

private markers: IMarker\<IMarkerIcon\<any>>[]

Source​

tools/layers/marker/model/internal/tool/MarkerLayerToolState.ts:26

Methods​

deserialize()​

deserialize(config): void

The metod takes config and deserializes the values.

Parameters​

• config: IMarkerLayerToolConfig

Returns​

void

Implementation of​

IMarkerLayerToolState.deserialize

Overrides​

LayerToolState.deserialize

Source​

tools/layers/marker/model/internal/tool/MarkerLayerToolState.ts:89


deserializeDimensions()​

deserializeDimensions(dimensionsConfig): void

It sets the map layer dimensions property of tool state.

Parameters​

• dimensionsConfig

• dimensionsConfig.aggregation?: string

• dimensionsConfig.category?: string

• dimensionsConfig.geoData?: string

• dimensionsConfig.geoId?: string

• dimensionsConfig.round?: number

• dimensionsConfig.units?: string

• dimensionsConfig.unitsDesc?: string

• dimensionsConfig.unitsEnabled?: boolean

• dimensionsConfig.value?: string

Returns​

void

Implementation of​

IMarkerLayerToolState.deserializeDimensions

Overrides​

LayerToolState.deserializeDimensions

Source​

tools/layers/marker/model/internal/tool/MarkerLayerToolState.ts:101


getBucketData()​

getBucketData(): Map\<string, Map\<string, IMapAggregationBucket>>

It returns the bucket data.

Returns​

Map\<string, Map\<string, IMapAggregationBucket>>

Implementation of​

IMarkerLayerToolState.getBucketData

Source​

tools/layers/marker/model/internal/tool/MarkerLayerToolState.ts:210


getCurrentDataCategories()​

getCurrentDataCategories(): string[]

It returns the current data categories.

Returns​

string[]

Implementation of​

IMarkerLayerToolState.getCurrentDataCategories

Source​

tools/layers/marker/model/internal/tool/MarkerLayerToolState.ts:192


getDimensions()​

getDimensions(): object

It returns the map layer dimensions property of the tool state.

Returns​

object

aggregation​

aggregation: IMapDomainDimension\<IMapAggregationFunction>

category​

category: IMapDomainDimension\<IMapDataDomain>

geoData​

geoData: IMapDomainDimension\<IGeoData>

geoId​

geoId: IMapDomainDimension\<IMapDataDomain>

round​

round: IMapTypeDimension\<number, ITypeManager\<number>>

units​

units: IMapTypeDimension\<string, ITypeManager\<string>>

unitsDesc​

unitsDesc: IMapTypeDimension\<string, ITypeManager\<string>>

unitsEnabled​

unitsEnabled: IMapTypeDimension\<boolean, ITypeManager\<boolean>>

value​

value: IMapDomainDimension\<IMapDataDomain>

Implementation of​

IMarkerLayerToolState.getDimensions

Overrides​

LayerToolState.getDimensions

Source​

tools/layers/marker/model/internal/tool/MarkerLayerToolState.ts:142


getIcon()​

getIcon(): string

It returns the icon property of the tool state.

Returns​

string

Implementation of​

IMarkerLayerToolState.getIcon

Inherited from​

LayerToolState.getIcon

Source​

model/internal/tool/MapToolState.ts:120


getId()​

getId(): string

It returns the id property of the tool state.

Returns​

string

Implementation of​

IMarkerLayerToolState.getId

Inherited from​

LayerToolState.getId

Source​

model/internal/object/MapObjectState.ts:87


getLabel()​

getLabel(): string

It returns the label property of the tool state.

Returns​

string

Implementation of​

IMarkerLayerToolState.getLabel

Inherited from​

LayerToolState.getLabel

Source​

model/internal/tool/MapToolState.ts:104


getLayerItems()​

getLayerItems(): undefined | Layer[]

It returns the layer items property of the tool state.

Returns​

undefined | Layer[]

Implementation of​

IMarkerLayerToolState.getLayerItems

Inherited from​

LayerToolState.getLayerItems

Source​

model/internal/layer/LayerToolState.ts:104


getLayerName()​

getLayerName(): string

It returns the layer name property of the tool state.

Returns​

string

Implementation of​

IMarkerLayerToolState.getLayerName

Inherited from​

LayerToolState.getLayerName

Source​

model/internal/layer/LayerToolState.ts:88


getMap()​

getMap(): IMap\<IMapProps, IMapDefaults, IMapState\<IMapProps, IMapDefaults, IMapConfig>, IMapConfig, IMapInitProps\<IMapConfig>>

It returns the map property of the tool state.

Returns​

IMap\<IMapProps, IMapDefaults, IMapState\<IMapProps, IMapDefaults, IMapConfig>, IMapConfig, IMapInitProps\<IMapConfig>>

Implementation of​

IMarkerLayerToolState.getMap

Inherited from​

LayerToolState.getMap

Source​

model/internal/tool/MapToolState.ts:136


getMapObject()​

protected getMapObject(): IMapObject\<IMapObjectProps, IMapObjectDefaults\<IMapObjectProps, IMapObjectConfig>, IMapObjectState\<IMapObjectProps, IMapObjectDefaults\<IMapObjectProps, IMapObjectConfig>, IMapObjectConfig, IMapObjectInitProps\<IMapObjectConfig>>, IMapObjectConfig, IMapObjectInitProps\<IMapObjectConfig>>

It makes the map object visible to extended classes.

Returns​

IMapObject\<IMapObjectProps, IMapObjectDefaults\<IMapObjectProps, IMapObjectConfig>, IMapObjectState\<IMapObjectProps, IMapObjectDefaults\<IMapObjectProps, IMapObjectConfig>, IMapObjectConfig, IMapObjectInitProps\<IMapObjectConfig>>, IMapObjectConfig, IMapObjectInitProps\<IMapObjectConfig>>

Inherited from​

LayerToolState.getMapObject

Source​

model/internal/object/MapObjectState.ts:39


getMarkerLayerGroup()​

getMarkerLayerGroup(): any

It returns a Leaflet layer group.

Returns​

any

Implementation of​

IMarkerLayerToolState.getMarkerLayerGroup

Source​

tools/layers/marker/model/internal/tool/MarkerLayerToolState.ts:158


getMarkers()​

getMarkers(): IMarker\<IMarkerIcon\<any>>[]

It returns the markers.

Returns​

IMarker\<IMarkerIcon\<any>>[]

Implementation of​

IMarkerLayerToolState.getMarkers

Source​

tools/layers/marker/model/internal/tool/MarkerLayerToolState.ts:174


getType()​

getType(): string

It returns the type property of the tool state.

Returns​

string

Implementation of​

IMarkerLayerToolState.getType

Inherited from​

LayerToolState.getType

Source​

model/internal/object/MapObjectState.ts:80


initialize()​

initialize(defaults, props, initProps): void

It resets state with respect to initial props.

Parameters​

• defaults: IMarkerLayerToolDefaults

• props: IMarkerLayerToolProps

• initProps: IMapToolInitProps\<IMarkerLayerToolConfig>

Returns​

void

Implementation of​

IMarkerLayerToolState.initialize

Overrides​

LayerToolState.initialize

Source​

tools/layers/marker/model/internal/tool/MarkerLayerToolState.ts:45


isEnabled()​

isEnabled(): boolean

It returns the enabled property of the tool state.

Returns​

boolean

Implementation of​

IMarkerLayerToolState.isEnabled

Inherited from​

LayerToolState.isEnabled

Source​

model/internal/tool/MapToolState.ts:88


serialize()​

serialize(defaults): IMarkerLayerToolConfig

The method serializes the tool state. Optionally, defaults can be set if property is undefined.

Parameters​

• defaults: undefined | IMarkerLayerToolDefaults

Returns​

IMarkerLayerToolConfig

Implementation of​

IMarkerLayerToolState.serialize

Overrides​

LayerToolState.serialize

Source​

tools/layers/marker/model/internal/tool/MarkerLayerToolState.ts:119


setBucketData()​

setBucketData(bucketData): void

It sets the bucket data.

Parameters​

• bucketData: Map\<string, Map\<string, IMapAggregationBucket>>

Returns​

void

Implementation of​

IMarkerLayerToolState.setBucketData

Source​

tools/layers/marker/model/internal/tool/MarkerLayerToolState.ts:219


setCurrentDataCategories()​

setCurrentDataCategories(currentDataCategories): void

It sets the current data categories.

Parameters​

• currentDataCategories: string[]

Returns​

void

Implementation of​

IMarkerLayerToolState.setCurrentDataCategories

Source​

tools/layers/marker/model/internal/tool/MarkerLayerToolState.ts:201


setDimensions()​

setDimensions(dimensions): void

It sets the map layer dimensions property of tool state.

Parameters​

• dimensions

• dimensions.aggregation: IMapDomainDimension\<IMapAggregationFunction>

• dimensions.category: IMapDomainDimension\<IMapDataDomain>

• dimensions.geoData: IMapDomainDimension\<IGeoData>

• dimensions.geoId: IMapDomainDimension\<IMapDataDomain>

• dimensions.round: IMapTypeDimension\<number, ITypeManager\<number>>

• dimensions.units: IMapTypeDimension\<string, ITypeManager\<string>>

• dimensions.unitsDesc: IMapTypeDimension\<string, ITypeManager\<string>>

• dimensions.unitsEnabled: IMapTypeDimension\<boolean, ITypeManager\<boolean>>

• dimensions.value: IMapDomainDimension\<IMapDataDomain>

Returns​

void

Implementation of​

IMarkerLayerToolState.setDimensions

Overrides​

LayerToolState.setDimensions

Source​

tools/layers/marker/model/internal/tool/MarkerLayerToolState.ts:151


setEnabled()​

setEnabled(enabled): void

It sets the enabled property of tool state.

Parameters​

• enabled: boolean

Returns​

void

Implementation of​

IMarkerLayerToolState.setEnabled

Inherited from​

LayerToolState.setEnabled

Source​

model/internal/tool/MapToolState.ts:97


setIcon()​

setIcon(icon): void

It sets the icon property of the tool state.

Parameters​

• icon: string

Returns​

void

Implementation of​

IMarkerLayerToolState.setIcon

Inherited from​

LayerToolState.setIcon

Source​

model/internal/tool/MapToolState.ts:129


setId()​

setId(id): void

It sets the id property of the tool state.

Parameters​

• id: string

Returns​

void

Implementation of​

IMarkerLayerToolState.setId

Inherited from​

LayerToolState.setId

Source​

model/internal/object/MapObjectState.ts:96


setLabel()​

setLabel(label): void

It sets the label property of the tool state.

Parameters​

• label: string

Returns​

void

Implementation of​

IMarkerLayerToolState.setLabel

Inherited from​

LayerToolState.setLabel

Source​

model/internal/tool/MapToolState.ts:113


setLayerItems()​

setLayerItems(layerItems): void

It sets the layer items property of tool state.

Parameters​

• layerItems: Layer[]

Returns​

void

Implementation of​

IMarkerLayerToolState.setLayerItems

Inherited from​

LayerToolState.setLayerItems

Source​

model/internal/layer/LayerToolState.ts:113


setLayerName()​

setLayerName(layerName): void

It sets the layer name property of the tool state.

Parameters​

• layerName: string

Returns​

void

Implementation of​

IMarkerLayerToolState.setLayerName

Inherited from​

LayerToolState.setLayerName

Source​

model/internal/layer/LayerToolState.ts:97


setMap()​

protected setMap(map): void

It sets the map property of the tool state.

Parameters​

• map: IMap\<IMapProps, IMapDefaults, IMapState\<IMapProps, IMapDefaults, IMapConfig>, IMapConfig, IMapInitProps\<IMapConfig>>

Returns​

void

Inherited from​

LayerToolState.setMap

Source​

model/internal/tool/MapToolState.ts:145


setMarkerLayerGroup()​

setMarkerLayerGroup(layerGroup): void

It sets a Leaflet layer group.

Parameters​

• layerGroup: LayerGroup

Returns​

void

Implementation of​

IMarkerLayerToolState.setMarkerLayerGroup

Source​

tools/layers/marker/model/internal/tool/MarkerLayerToolState.ts:167


setMarkers()​

setMarkers(markers): void

It sets the markers.

Parameters​

• markers: IMarker\<IMarkerIcon\<any>>[]

Returns​

void

Implementation of​

IMarkerLayerToolState.setMarkers

Source​

tools/layers/marker/model/internal/tool/MarkerLayerToolState.ts:183