import type { ElevationProfileState, ElevationProfileLineUnion, ElevationQuerySource, ElevationProfileSample, ElevationProfileStatistics } from "@arcgis/core/widgets/ElevationProfile/types.js";Type definitions
ElevationProfileState
- Since
- ArcGIS Maps SDK for JavaScript 5.0
The public state (mostly related to interaction) the elevation profile can be in.
- disabled: widget is being created
- ready: widget is ready. No path configured and no interactive operation ongoing.
- creating: user is creating a new input path.
- created: input path is configured but no interactive operation is ongoing.
- selecting: user is selecting an existing input path.
- selected: user selected an existing input path.
- Type
- "disabled" | "ready" | "creating" | "created" | "selecting" | "selected"
ElevationQuerySource
- Since
- ArcGIS Maps SDK for JavaScript 5.0
queryElevation
- Signature
-
queryElevation (geometry: ElevationQueryGeometry, options?: ElevationQueryOptions): Promise<ElevationQueryResult<ElevationQueryGeometry>>
- Since
- ArcGIS Maps SDK for JavaScript 5.0
Function used to query elevation values for a geometry (Point, Multipoint or Polyline). It returns a promise that resolves with an ElevationQueryResult.
Parameters
| Parameter | Type | Description | Required |
|---|---|---|---|
| geometry | The geometry to use for sampling elevation data. | | |
| options | Additional query options. | |
- Returns
- Promise<ElevationQueryResult<ElevationQueryGeometry>>
Resolves to an object with the sampled geometry, resolution information, and no data value.
ElevationProfileSample
- Since
- ArcGIS Maps SDK for JavaScript 5.0
A sample/point in a generated elevation profile. The x, y and z properties are in the spatial reference of the view and distance and elevation are in the units specified in the view model.
x
- Type
- number
- Since
- ArcGIS Maps SDK for JavaScript 5.0
The x coordinate of the sample, in the spatial reference of the view.
y
- Type
- number
- Since
- ArcGIS Maps SDK for JavaScript 5.0
The y coordinate of the sample, in the spatial reference of the view.
distance
- Type
- number
- Since
- ArcGIS Maps SDK for JavaScript 5.0
Horizontal (2D) distance from the beginning of the path, in the effective unit selected by the user. In geographic coordinate systems (GCS) and in WebMercator, the distance is the geodesic distance. In projected coordinate systems (PCS), apart from WebMercator, the distance is computed in a Euclidean manner (in the respective PCS).
ElevationProfileStatistics
- Since
- ArcGIS Maps SDK for JavaScript 5.0
Statistics about a generated elevation profile.
maxDistance
- Since
- ArcGIS Maps SDK for JavaScript 5.0
The maximum horizontal (2D) distance of the path. In geographic coordinate systems (GCS) and in WebMercator, the distance is the geodesic distance. In projected coordinate systems (PCS), apart from WebMercator, the distance is computed in a Euclidean manner (in the respective PCS).
elevationGain
- Since
- ArcGIS Maps SDK for JavaScript 5.0
The cumulative elevation gain along the path. See https://en.wikipedia.org/wiki/Cumulative_elevation_gain
elevationLoss
- Since
- ArcGIS Maps SDK for JavaScript 5.0
The cumulative elevation loss along the path. See https://en.wikipedia.org/wiki/Cumulative_elevation_gain
EffectiveUnits
- Since
- ArcGIS Maps SDK for JavaScript 5.0
The units which have been selected according to the magnitude of the elevations and distances that are to be displayed in the widget, according to the selected unit or unit system.
distance
- Type
- LengthUnit
- Since
- ArcGIS Maps SDK for JavaScript 5.0
Units used for displaying distance or length values.
elevation
- Type
- LengthUnit
- Since
- ArcGIS Maps SDK for JavaScript 5.0
Units used for displaying elevation values.
ElevationProfileLineType
- Since
- ArcGIS Maps SDK for JavaScript 5.0
- Type
- "ground" | "input" | "query" | "view"
InteractionMode
- Since
- ArcGIS Maps SDK for JavaScript 5.0
- Type
- "select" | "sketch"
InteractionStartOptions
- Since
- ArcGIS Maps SDK for JavaScript 5.0
mode
- Type
- InteractionMode
- Since
- ArcGIS Maps SDK for JavaScript 5.0
The mode that the widget will start with. In "sketch" mode the user can draw a new line and in "select" mode the user can click on the view to select an existing line.
- Default value
- "sketch"