Skip to content
import SplitFeatureWorkflowData from "@arcgis/core/widgets/Editor/SplitFeatureWorkflowData.js";
Inheritance:
SplitFeatureWorkflowDataAccessor
Since
ArcGIS Maps SDK for JavaScript 4.34

This object contains data for the SplitFeatureWorkflow. This is accessed via the property SplitFeatureWorkflow.data.

See also

Constructors

Constructor

Constructor
Parameters
ParameterTypeDescriptionRequired
properties
See the properties table for a list of all the properties that may be passed into the constructor.

Properties

Any properties can be set, retrieved or listened to. See the Watch for changes topic.

declaredClass

readonlyinherited Property
Type
string
Inherited from: Accessor

The name of the class. The declared class name is formatted as esri.folder.className.

editorItem

readonly Property
Type
EditorItem

The EditorItem object from EditorViewModel corresponding to the layer being updated.

existingFeatureEdits

Property
Type
Edits | null | undefined

Information about the feature to be updated as a result of the split operation.

A split workflow results in two edits: the existing feature is updated to have one of the geometries resulting from the split, and a new feature is created with the other geometry. This property references the feature that will be updated.

See also

feature

Property
Type
Graphic

The feature to be split.

This feature's Graphic.attributes object must contain all fields for which values are set on the feature, and its Graphic.geometry must be full resolution. If the Graphic was obtained from a layer view query, it is likely that the geometry is not full resolution and that the attributes do not contain all fields.

newFeatureEdits

Property
Type
Edits | null | undefined

Information about the feature to be created as a result of the split operation.

See also

splitterGeometry

Property
Type
SplitterGeometry | null | undefined

The geometry to be used to split the geometry of the initial feature.

viewModel

Property
Type
EditorViewModel

The associated EditorViewModel for this workflow.

Methods

MethodSignatureClass
getEditsForFeature(feature: Graphic): Edits | null
getRoleForFeature(feature: Graphic): "existing" | "new" | null

getEditsForFeature

Method
Signature
getEditsForFeature (feature: Graphic): Edits | null

Returns the instance of Edits corresponding to the given feature. Returns the value of either existingFeatureEdits or newFeatureEdits, depending on which feature is passed. If feature is not one of the two Graphics generated by the workflow, this method returns null.

The primary way of accessing the Graphics generated by the workflow is through the Edits.feature property of the Edits objects referenced by existingFeatureEdits and newFeatureEdits. This method is useful if you obtain one of the Graphics outside of this context and need to access the Edits object it belongs to.

Parameters
ParameterTypeDescriptionRequired
feature

Either of the two Graphics created by the workflow.

Returns
Edits | null

getRoleForFeature

Method
Signature
getRoleForFeature (feature: Graphic): "existing" | "new" | null

Identifies whether the given Graphic represents the feature to be updated or the feature to be created.

Parameters
ParameterTypeDescriptionRequired
feature

Either of the two Graphics created by the workflow.

Returns
"existing" | "new" | null

The role of the feature in the split operation, or null if the feature does not belong to this workflow.