import UtilityNetworkTraceAnalysis from "@arcgis/core/networks/UtilityNetworkTraceAnalysis.js";const UtilityNetworkTraceAnalysis = await $arcgis.import("@arcgis/core/networks/UtilityNetworkTraceAnalysis.js");- Inheritance:
- UtilityNetworkTraceAnalysis→
Accessor
- Since
- ArcGIS Maps SDK for JavaScript 5.0
Provides the logic for the UtilityNetworkTraceAnalysis component.
- See also
Constructors
Constructor
Parameters
| Parameter | Type | Description | Required |
|---|---|---|---|
| properties | | |
Properties
| Property | Type | Class |
|---|---|---|
declaredClass readonly inherited | ||
executionError readonly | | |
loadError readonly | | |
state readonly | | |
| | ||
| |
utilityNetwork
- Type
- UtilityNetwork | null | undefined
Determines the utility network to use.
Methods
| Method | Signature | Class |
|---|---|---|
executeNamedTraceConfiguration(parameters: NamedTraceConfigurationParameters): Promise<TraceResult> | | |
executeTraceConfiguration(parameters: TraceConfigurationParameters): Promise<TraceResult> | |
executeNamedTraceConfiguration
- Signature
-
executeNamedTraceConfiguration (parameters: NamedTraceConfigurationParameters): Promise<TraceResult>
Method used to execute a trace using a named trace configuration.
Parameters
| Parameter | Type | Description | Required |
|---|---|---|---|
| parameters | The parameters used to execute a trace based using named trace configurations. | |
- Returns
- Promise<TraceResult>
When resolved, returns the trace results which could include elements, function results or aggregated geometries.
Example
const traceLocations = [ { type: "starting-point", globalId: "{699C9FDB-3B39-46DC-90D2-13553F3C6694}", percentAlong: 0.05, }, { type: "barrier", globalId: "{8E99EB07-3BA0-4D7D-A1C0-4D69F5487470}", percentAlong: 0.7 },];const traceResult = await utilityNetworkTraceAnalysis.executeNamedTraceConfiguration({ namedTraceConfigurationGlobalId: "{E43E4D2C-E191-4547-AFB8-392860694392}", traceLocations: traceLocations}); executeTraceConfiguration
- Signature
-
executeTraceConfiguration (parameters: TraceConfigurationParameters): Promise<TraceResult>
Executes a trace using custom trace parameters and returns trace results.
Parameters
| Parameter | Type | Description | Required |
|---|---|---|---|
| parameters | The parameters used to execute a custom trace. | |
- Returns
- Promise<TraceResult>
When resolved, returns the trace results which could include elements, function results or aggregated geometries.
Example
const traceConfiguration = new UNTraceConfiguration({ domainNetworkName: "ElectricDistribution", tierName: "Medium Voltage Radial", subnetworkName: "RMT001", conditionBarriers: [ { name: "Operational Device Status", type: "networkAttribute", operator: "equal", value: 1, combineUsingOr: false, isSpecificValue: true, }, ],});
const traceResults = await utilityNetworkTraceAnalysis.executeTraceConfiguration({ traceConfiguration, traceType: "subnetwork",});Type definitions
TraceConfigurationParameters
- Since
- ArcGIS Maps SDK for JavaScript 4.34
Object used to execute a custom trace.
traceConfiguration
- Type
- UNTraceConfiguration
The collection of trace configuration properties. Depending on the trace type, some of the trace configuration properties are required.
traceType
- Type
- TraceType
The trace type. This specifies the core algorithm that will be run to analyze the network.
outSpatialReference
- Type
- SpatialReference | undefined
The desired out SpatialReference of the trace.
traceLocations
- Type
- TraceLocation[] | undefined
To perform the trace analytic, users can optionally supply a list of locations in forms of globalIds (UUID) and terminals. These locations indicate starting points and barriers. A starting point is set on network features to define the location in the network where a trace begins. Most traces require one or more starting points to be defined. Barriers are used in traces, export subnetwork operations, and update subnetwork operations to mark the locations to stop tracing. Use barriers to represent a location in the network beyond which the trace cannot travel.
NamedTraceConfigurationParameters
- Since
- ArcGIS Maps SDK for JavaScript 4.32
Object used to execute a trace using a named trace configuration.
outSpatialReference
- Type
- SpatialReference | undefined
The desired out SpatialReference of the trace.
traceLocations
- Type
- TraceLocation[] | undefined
To perform the trace analytic, users can optionally supply a list of locations in forms of globalIds (UUID) and terminals. These locations indicate starting points and barriers. A starting point is set on network features to define the location in the network where a trace begins. Most traces require one or more starting points to be defined. Barriers are used in traces, export subnetwork operations, and update subnetwork operations to mark the locations to stop tracing. Use barriers to represent a location in the network beyond which the trace cannot travel.