Class
JimuLayerView
is the wrapper class for ArcGIS Maps SDK for JavaScript Layer and LayerView
.
It is created by a JimuMapView
using a layer DataSource
.
A layer view may have a related data source. If it has the data source, the feature selection will be synced to data source selection and will use the data source URL params. If it does not have the data source, the feature selection will use the feature_selection URL param.
Properties
Property | Type | Notes |
---|---|---|
boolean | true means the JimuLayerView is created from runtime. e.g. The JimuLayerView is created by AddData widget at runtime. false means the layer is a builtin layer of WebMap or WebScene. | |
string | The id of the JimuLayerView instance. It connects the JimuMapView.id and the JimuLayerId with "-" | |
number | The order defined in the webmap | |
string | The jimuMapViewId is the corresponding JimuMapView instance id. | |
any | The layer is the corresponding layer object in ArcGIS JavaScript API View.map. | |
string | The layerDataSourceId is the corresponding data source id. This id always has value, but the layer data source may not be created. | |
string | The layer type, see ArcGIS Maps SDK for JavaScript Layer type. | |
LayerView | BuildingComponentSublayerView | The |
fromRuntime
Class PropertyfromRuntime: boolean
true means the JimuLayerView is created from runtime. e.g. The JimuLayerView is created by AddData widget at runtime. false means the layer is a builtin layer of WebMap or WebScene.
id
Class Propertyid: string
The id of the JimuLayerView instance. It connects the JimuMapView.id and the JimuLayerId with "-"
jimuMapViewId
Class PropertyjimuMapViewId: string
The jimuMapViewId is the corresponding JimuMapView instance id.
layer
Class Propertylayer: any
The layer is the corresponding layer object in ArcGIS JavaScript API View.map.
layerDataSourceId
Class PropertylayerDataSourceId: string
The layerDataSourceId is the corresponding data source id. This id always has value, but the layer data source may not be created.
type
Class Propertytype: string
The layer type, see ArcGIS Maps SDK for JavaScript Layer type.
view
Class Propertyview: LayerView | BuildingComponentSublayerView
The view
is the ArcGIS Maps SDK for JavaScript LayerView
or BuildingComponentSublayerView
.
Methods
Method | Returns | Notes |
---|---|---|
Promise<DataSource> | Create corresponding data source for the layer. | |
destroy() | void | Destroy the JimuLayerView instance. |
Get all ancestor JimuLayerViews. | ||
Get the JimuMapView that the current JimuLayerView belongs to. | ||
Return the corresponding data source of the layer. | ||
Get the map data source of the layer. | ||
MapView | SceneView | Return the MapView or SceneView of the layer view. | |
Get parent JimuLayerView. | ||
boolean | If any layer in the layer tree is invisible, the layer is considered invisible. |
createLayerDataSource
Class MethodcreateLayerDataSource(): Promise<DataSource>
Create corresponding data source for the layer.
Returns
Promise<DataSource>
getAllAncestorJimuLayerViews
Class MethodgetAllAncestorJimuLayerViews(): JimuLayerView[]
Get all ancestor JimuLayerViews.
Returns
JimuLayerView[]
getJimuMapView
Class MethodgetJimuMapView(): JimuMapView
Get the JimuMapView that the current JimuLayerView belongs to.
Returns
JimuMapView
getLayerDataSource
Class MethodgetLayerDataSource(): DataSource
Return the corresponding data source of the layer.
Returns
DataSource
getMapDataSource
Class MethodgetMapDataSource(): MapDataSource
Get the map data source of the layer.
Returns
MapDataSource
getMapSceneView
Class MethodgetMapSceneView(): MapView | SceneView
Return the MapView or SceneView of the layer view.
Returns
MapView | SceneView
getParentJimuLayerView
Class MethodgetParentJimuLayerView(): JimuLayerView
Get parent JimuLayerView.
Returns
JimuLayerView