Constructor
new LayerTreeItemState(mapItemState, parentGroupStateopt)
Instantiate a layer tree item
Parameters:
Name | Type | Attributes | Description |
---|---|---|---|
mapItemState |
MapItemState | the map item state | |
parentGroupState |
LayerTreeItemState |
<optional> |
the parent layer tree group |
- Source:
Extends
Members
checked :boolean
Layer tree item is checked
Type:
- boolean
- Source:
checked :boolean
Set layer tree item is checked
Type:
- boolean
- Source:
expanded :boolean
Layer tree item is expanded
Type:
- boolean
- Source:
expanded :boolean
Set layer tree item is expanded
Type:
- boolean
- Source:
(nullable) layerConfig :LayerConfig
Lizmap layer config
Type:
- LayerConfig
- Source:
level :number
Layer tree item level
Type:
- number
- Source:
(nullable) mapItemState :MapItemState
Map item state
Type:
- MapItemState
- Source:
name :string
Config layers
Type:
- string
- Source:
opacity :number
Layer tree item opacity
Type:
- number
- Source:
opacity :number
Set layer tree item opacity
Type:
- number
- Source:
type :string
Config layers
Type:
- string
- Source:
visibility :boolean
Layer tree item is visible
It depends on the parent visibility
Type:
- boolean
- Source:
wmsBoundingBoxes :Array.<LayerBoundingBoxConfig>
WMS layer Bounding Boxes
Type:
- Array.<LayerBoundingBoxConfig>
- Source:
(nullable) wmsGeographicBoundingBox :LayerGeographicBoundingBoxConfig
WMS layer Geographic Bounding Box
Type:
- LayerGeographicBoundingBoxConfig
- Source:
wmsMaxScaleDenominator :number
WMS layer maximum scale denominator
If the maximum scale denominator is not defined: -1 is returned
If the WMS layer is a group, the maximum scale denominator is the largest of the layers in the group
Type:
- number
- Source:
wmsMinScaleDenominator :number
WMS Minimum scale denominator
If the minimum scale denominator is not defined: -1 is returned
If the WMS layer is a group, the minimum scale denominator is -1 if only one layer
minimum scale denominator is not defined else the smallest layer minimum scale denominator
in the group
Type:
- number
- Source:
(nullable) wmsName :string
WMS layer name
Type:
- string
- Source:
wmsTitle :string
WMS layer title
Type:
- string
- Source:
Methods
calculateVisibility() → {boolean}
Calculate and save visibility
- Source:
Returns:
the calculated visibility
- Type
- boolean
isVisible(scaleDenominator) → {boolean}
Get item visibility taking care of this.visibility and scale
Parameters:
Name | Type | Description |
---|---|---|
scaleDenominator |
number | the scale denominator for which the visibility has to be evaluated |
- Source:
Returns:
the item visibility
- Type
- boolean