SelectionController
The Selection controller allows you to listen for changes to the selection on the map.
Extended by
Methods
getSelection()
getSelection():
Promise
<EntityNode
[]>
Gets the current selection as a list of entity identifiers.
Returns
Promise
<EntityNode
[]>
Example
selectFeature()
selectFeature(
params
:FeatureSelection
):Promise
<void
>
Selects a feature on a layer. This will show the feature's popup, modal or sidebar (if configured) and highlight the feature.
Parameters
Parameter
Type
params
Returns
Promise
<void
>
Example
Events
onSelectionChange()
onSelectionChange(
params
: {handler
: (change
: {selection
:EntityNode
[]; }) =>void
; }):VoidFunction
Adds a listener for when the selection changes.
Parameters
Parameter
Type
params
object
params.handler
(change
: {selection
: EntityNode
[]; }) => void
Returns
VoidFunction
A function to unsubscribe from the listener
Example
Last updated