import TraceResult from "@arcgis/core/rest/networks/support/TraceResult.js";const TraceResult = await $arcgis.import("@arcgis/core/rest/networks/support/TraceResult.js");- Inheritance:
- TraceResult→
Accessor
- Subclasses:
- TraceJobInfo
- Since
- ArcGIS Maps SDK for JavaScript 4.20
This class defines the collection of results returned from the trace function. The trace can return network elements, aggregated geometries, and functions.
- See also
Constructors
Constructor
Parameters
| Parameter | Type | Description | Required |
|---|---|---|---|
| properties | | |
Properties
| Property | Type | Class |
|---|---|---|
aggregatedGeometry readonly | | |
circuits readonly | CircuitTraceResult[] | null | undefined | |
declaredClass readonly inherited | ||
elements readonly | | |
globalFunctionResults readonly | | |
kFeaturesForKNNFound readonly | | |
paths readonly | CircuitPath[] | null | undefined | |
startingPointsIgnored readonly | | |
warnings readonly | |
aggregatedGeometry
- Type
- AggregatedGeometry | null | undefined
This property defines an aggregation of geometries returned by the trace. The aggregated geometries will only include geometries that belong to features with assetgroups/assettypes specified in the trace output.
This is returned only if the aggregated geometries results type is defined in the trace configuration.
circuits
- Type
- CircuitTraceResult[] | null | undefined
- Since
- ArcGIS Maps SDK for JavaScript 4.34
An array of circuits returned by the trace. Used in the telecom domain network. This is returned only if the "circuits" result type is defined in the trace configuration.
elements
- Type
- NetworkElement[]
An array of network elements returned by the trace. The network element is a representation of how the network topology defines its graph. This is returned only if the elements results type is defined in the trace configuration.
The elements property returning a TelecomNetworkElement is in beta and is reserved for future use in a telecom domain network.
globalFunctionResults
- Type
- FunctionResult[]
Returns an array of function aggregation results.
kFeaturesForKNNFound
- Type
- boolean
This parameter is specific to the K-Nearest Neighbors Algorithm, when the nearest filter is provided in the trace configuration. It returns true if any neighbors were found.
- Default value
- false
paths
- Type
- CircuitPath[] | null | undefined
- Since
- ArcGIS Maps SDK for JavaScript 4.34
The paths returned by a path trace.
startingPointsIgnored
- Type
- boolean
Returns true if the starting points in the network trace operation are ignored.
- Default value
- false
Methods
fromJSON
- Signature
-
fromJSON (json: any): any
Creates a new instance of this class and initializes it with values from a JSON object
generated from an ArcGIS product. The object passed into the input json
parameter often comes from a response to a query operation in the REST API or a
toJSON()
method from another ArcGIS product. See the Using fromJSON()
topic in the Guide for details and examples of when and how to use this function.
Parameters
| Parameter | Type | Description | Required |
|---|---|---|---|
| json | A JSON representation of the instance in the ArcGIS format. See the ArcGIS REST API documentation for examples of the structure of various input JSON objects. | |
- Returns
- any
Returns a new instance of this class.
toJSON
- Signature
-
toJSON (): any
Converts an instance of this class to its ArcGIS portal JSON representation. See the Using fromJSON() guide topic for more information.
- Returns
- any
The ArcGIS portal JSON representation of an instance of this class.