import ElevationProfileResult from "@arcgis/core/views/analysis/ElevationProfile/ElevationProfileResult.js";
const ElevationProfileResult = await $arcgis.import("@arcgis/core/views/analysis/ElevationProfile/ElevationProfileResult.js");
@arcgis/core/views/analysis/ElevationProfile/ElevationProfileResult
Represents the result for each profile line configured in the ElevationProfileAnalysis.profiles collection. This result is initialized by the analysis view and is dynamically updated as the elevation profile is generated.
Property Overview
Name | Type | Summary | Class |
---|---|---|---|
Indicates whether the line is available. | ElevationProfileResult | ||
The name of the class. | Accessor | ||
The profile line whose elevation is represented by this result. | ElevationProfileResult | ||
Represents the progress of the elevation profile generation, ranging from 0 to 1. | ElevationProfileResult | ||
Contains the samples that make up the elevation profile. | ElevationProfileResult | ||
Provides statistics about the elevation profile, including minimum, maximum, and average elevation values, elevation gain and loss, and slope information. | ElevationProfileResult |
Property Details
-
available
available Booleanreadonly
-
Indicates whether the line is available. Unavailable lines are not sampled or displayed, and the corresponding samples and statistics will be empty.
Availability rules for each line type:
ground
: Available if any ground layers are visible.input
: Always available.query
: Available if the source is visible and any layers in that source (e.g. ground elevation layers) are also visible.scene
: Always available in 3D.
-
profile
profile ElevationProfileLineGround |ElevationProfileLineInput |ElevationProfileLineQuery |ElevationProfileLineScenereadonly
-
The profile line whose elevation is represented by this result.
-
progress
progress Numberreadonly
-
Represents the progress of the elevation profile generation, ranging from 0 to 1.
-
Contains the samples that make up the elevation profile. Each sample represents a point along the profile.
The distance and elevation values are given in the effective units specified in ElevationProfileAnalysisView2D.effectiveDisplayUnits or ElevationProfileAnalysisView3D.effectiveDisplayUnits.
-
statistics
statistics Statistics |null |undefinedreadonly
-
Provides statistics about the elevation profile, including minimum, maximum, and average elevation values, elevation gain and loss, and slope information.
The distance and elevation values are given in the effective units specified in ElevationProfileAnalysisView2D.effectiveDisplayUnits or ElevationProfileAnalysisView3D.effectiveDisplayUnits.
Method Overview
Name | Return Type | Summary | Class |
---|---|---|---|
Adds one or more handles which are to be tied to the lifecycle of the object. | Accessor | ||
this | Creates a deep clone of this object. | ElevationProfileResult | |
Returns true if a named group of handles exist. | Accessor | ||
Removes a group of handles owned by the object. | Accessor |
Method Details
-
Inherited from Accessor
-
Adds one or more handles which are to be tied to the lifecycle of the object. The handles will be removed when the object is destroyed.
// Manually manage handles const handle = reactiveUtils.when( () => !view.updating, () => { wkidSelect.disabled = false; }, { once: true } ); this.addHandles(handle); // Destroy the object this.destroy();
ParametershandleOrHandles WatchHandle|WatchHandle[]Handles marked for removal once the object is destroyed.
groupKey *optionalKey identifying the group to which the handles should be added. All the handles in the group can later be removed with Accessor.removeHandles(). If no key is provided the handles are added to a default group.
-
Creates a deep clone of this object. Any properties that store values by reference will be assigned copies of the referenced values on the cloned instance.
ReturnsType Description this A deep clone of the class instance that invoked this method.
-
hasHandles
InheritedMethodhasHandles(groupKey){Boolean}
Inherited from Accessor -
Returns true if a named group of handles exist.
ParametergroupKey *optionalA group key.
ReturnsType Description Boolean Returns true
if a named group of handles exist.Example// Remove a named group of handles if they exist. if (obj.hasHandles("watch-view-updates")) { obj.removeHandles("watch-view-updates"); }
-
Inherited from Accessor
-
Removes a group of handles owned by the object.
ParametergroupKey *optionalA group key or an array or collection of group keys to remove.
Exampleobj.removeHandles(); // removes handles from default group obj.removeHandles("handle-group"); obj.removeHandles("other-handle-group");
Type Definitions
-
Sample
Sample Object
-
Represents an elevation sample in the profile.
- Properties
-
x Number
The x coordinate of the sample, in the spatial reference of the view.
y NumberThe y coordinate of the sample, in the spatial reference of the view.
optional The z coordinate of the sample, in the spatial reference of the view.
distance NumberHorizontal (2D) distance from the beginning of the path, in the effective units. 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).
optional The elevation of the sample, in the effective units.
-
Statistics
Statistics Object
-
Represents the statistics for the generated profile line.
- Properties
-
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).
The minimum elevation along the path.
The maximum elevation along the path.
The average elevation along the path.
The cumulative elevation gain along the path.
The cumulative elevation loss along the path.
The maximum positive slope along the path. Profiles are sampled at a minimum distance of 10 meters (32.8 feet). Higher resolution profiles are downsampled to that minimum sampling distance before calculating the slope.
The average positive slope along the path. Profiles are sampled at a minimum distance of 10 meters (32.8 feet). Higher resolution profiles are downsampled to that minimum sampling distance before calculating the slope.
The maximum negative slope along the path. Profiles are sampled at a minimum distance of 10 meters (32.8 feet). Higher resolution profiles are downsampled to that minimum sampling distance before calculating the slope.
The average negative slope along the path. Profiles are sampled at a minimum distance of 10 meters (32.8 feet). Higher resolution profiles are downsampled to that minimum sampling distance before calculating the slope.