Appearance
GeoJsonLayer (GeoJSON Vector Data Layer)
Layer for loading and displaying GeoJSON data.
Constructor
ts
new ge3d.object.GeoJsonLayer(options?: any): GeoJsonLayerParameters
| Parameter | Type | Default | Description |
|---|---|---|---|
| url | String | - | GeoJSON file produced by SDK plotting or service URL address |
| data | Object | - | GeoJSON format specification data object produced by SDK plotting |
| crs | String | - | Coordinate system of original data |
| format | Function | - | Format or transform loaded GeoJSON data |
| symbol | Object/Function | - | Style of vector data |
| buildings | Object | - | Identify current layer as building white model type data |
| mask | Boolean/Object | false | Whether to draw inverse selection mask layer for area boundaries |
Properties
| Property | Type | Description |
|---|---|---|
| clustering | any | Whether to cluster (for point data) |
| features | any[] | Collection of Feature objects within the layer |
| id | any | Object id identifier |
| show | any | Show/hide state |
| opacity | any | Opacity, range 0.0-1.0 |
Methods
addFeature
Add feature
ts
addFeature(feature: any[]): anyloadGeoJSON
Load GeoJSON data
ts
loadGeoJSON(geojson: any, options?: any): anytoGeoJSON
Convert to GeoJSON
ts
toGeoJSON(options: any): { features: any; layer: { id: any; name: any }; type: string }