@arcgis/core
Version:
ArcGIS Maps SDK for JavaScript: A complete 2D and 3D mapping and data visualization API
66 lines (64 loc) • 4.88 kB
TypeScript
import type FormTemplate from "../../../form/FormTemplate.js";
import type EditingCapabilities from "../../../layers/support/EditingCapabilities.js";
import type { EditingCapabilitiesProperties } from "../../../layers/support/EditingCapabilities.js";
import type { AttachmentCapabilities, CreateCapabilities, DeleteCapabilities, RelationshipCapabilities, UpdateCapabilities } from "../../../layers/support/types.js";
import type { LayerInfo } from "../types.js";
/** @since 5.0 */
export interface EditorEditingCapabilitiesProperties extends EditingCapabilitiesProperties, Partial<Pick<EditorEditingCapabilities, "layerInfo">> {}
/**
* The current editing capabilities for the provided layer and read by the [Editor](https://developers.arcgis.com/javascript/latest/references/core/widgets/Editor/). This takes into
* account what is set on the [EditorItem.layerInfo](https://developers.arcgis.com/javascript/latest/references/core/widgets/Editor/support/EditorItem/#layerInfo)
*
* @since 5.0
*/
export default class EditorEditingCapabilities extends EditingCapabilities {
constructor(properties: EditorEditingCapabilitiesProperties);
/**
* Specific permissions for attachment operations. It takes into account the [Editor's layerInfo](https://developers.arcgis.com/javascript/latest/references/core/widgets/Editor/types/#LayerInfo) settings.
*
* @since 5.0
*/
get attachments(): AttachmentCapabilities;
/**
* Specific permissions for create operations. It takes into account the [Editor's layerInfo](https://developers.arcgis.com/javascript/latest/references/core/widgets/Editor/types/#LayerInfo) settings.
*
* @since 5.0
*/
get create(): CreateCapabilities;
/**
* The default editing capabilities for the provided layer. This does not take into account what may be set on the [EditorItem.layerInfo](https://developers.arcgis.com/javascript/latest/references/core/widgets/Editor/support/EditorItem/#layerInfo) settings.
*
* @since 5.0
*/
get defaults(): EditingCapabilities;
/**
* Specific permissions for delete operations. It takes into account the [Editor's layerInfo](https://developers.arcgis.com/javascript/latest/references/core/widgets/Editor/types/#LayerInfo) settings.
*
* @since 5.0
*/
get delete(): DeleteCapabilities;
/**
* The primary form template in use. It takes into account the Editor's [layerInfos](https://developers.arcgis.com/javascript/latest/references/core/widgets/Editor/types/#LayerInfo) and whether a form template is set on a `layerInfo` within it. If so, the form template set on a [LayerInfo](https://developers.arcgis.com/javascript/latest/references/core/widgets/Editor/types/#LayerInfo) within the Editor takes precedence over a form template set directly on a [FeatureLayer](https://developers.arcgis.com/javascript/latest/references/core/layers/FeatureLayer/) or [SubtypeSublayer](https://developers.arcgis.com/javascript/latest/references/core/layers/support/SubtypeSublayer/). A form template set within the [Editor](https://developers.arcgis.com/javascript/latest/references/core/widgets/Editor/) widget's [layerInfos](https://developers.arcgis.com/javascript/latest/references/core/widgets/Editor/types/#LayerInfo) takes priority over a form template set directly on a [FeatureLayer](https://developers.arcgis.com/javascript/latest/references/core/layers/FeatureLayer/) or [SubtypeSublayer](https://developers.arcgis.com/javascript/latest/references/core/layers/support/SubtypeSublayer/).
*
* @since 5.0
*/
get formTemplate(): FormTemplate | null | undefined;
/**
* The layer's associated [LayerInfo](https://developers.arcgis.com/javascript/latest/references/core/widgets/Editor/types/#LayerInfo) .
*
* @since 5.0
*/
accessor layerInfo: LayerInfo | null | undefined;
/**
* Indicates if the layer contains at least one relationship in addition to child [Workflow](https://developers.arcgis.com/javascript/latest/references/core/widgets/Editor/Workflow/) permissions. It takes into account what is set on the [EditorItem.layerInfo](https://developers.arcgis.com/javascript/latest/references/core/widgets/Editor/support/EditorItem/#layerInfo). It does not take into account whether a parent or related layer has the ability to edit. A collection of all [EditorItems](https://developers.arcgis.com/javascript/latest/references/core/widgets/Editor/support/EditorItem/) that represent potential related layers should be referenced if accessing editing permissions per related layer.
*
* @since 5.0
*/
get relationship(): RelationshipCapabilities;
/**
* Specific permissions for update operations. It takes into account the [Editor's layerInfo](https://developers.arcgis.com/javascript/latest/references/core/widgets/Editor/types/#LayerInfo) settings.
*
* @since 5.0
*/
get update(): UpdateCapabilities;
}