Extends the capabilities of an Esri SceneLayer object.

Hierarchy (view full)

Constructors

Properties

Accessors

Methods

Constructors

Properties

_handles: Handles<unknown, ResourceHandle>
_id: string

The unique ID for this entity. Once set, this should never change.

_itemType: string = ItemType.LAYER_EXTENSION

The item type for this entity when it participates in an App.

Do not directly reference this property. Use EventNames and EventTypes helpers from @arcgis/core/Evented.

allSublayerExtensions: SublayerExtensionCollection

All descendant sublayer extensions associated with this layer.

iconUrl?: string

URL to an icon that represents this feature source.

layerListSettings: LayerListSettings

Settings that affect the behavior and presentation of the layer in the layer list.

onAddFeature?: Action

The action to be executed when a feature is added.

onEditFeature?: Action

The action to be executed when a feature is edited.

queryService?: QueryService

An optional query service that the feature source can use to get features.

tpkSource: string

An optional remote source for a .tpk, .tpkx or .vtpk file. May be a portal item URL or a portal item ID. Mobile Only.

The factory that will be used whenever a new layer extension needs to be created. Applications can supply their own factory to customize layer extension creation.

Accessors

  • get canChangeDefinitionExpression(): boolean
  • Determines whether the type of layer being extended supports changing its definition expression.

    Returns boolean

  • get canChangeLabels(): boolean
  • Determines whether the type of layer being extended supports changing labels. Default is false.

    Returns boolean

  • get canChangeOpacity(): boolean
  • Determines whether the type of layer being extended supports changing opacity.

    Returns boolean

  • get canChangeRenderer(): boolean
  • Determines whether the type of layer being extended supports changing its renderer.

    Returns boolean

  • get canChangeScale(): boolean
  • Determines whether the type of layer being extended supports changing Scale.

    Returns boolean

  • get dynamicallyAddedLayer(): boolean
  • Indicates that the layer was added dynamically.

    Returns boolean

  • set dynamicallyAddedLayer(value): void
  • Parameters

    • value: boolean

    Returns void

  • get effectiveFullExtent(): Extent
  • The effective full extent of this layer extension.

    Returns Extent

  • get effectiveMaxScale(): number
  • The effective max scale for this layer extension.

    Returns number

  • get effectiveMinScale(): number
  • The effective min scale for this layer extension.

    Returns number

  • get enableClientSideData(): boolean
  • Indicates that the layer's data should be available client-side, within the graphics that render on the map. Client-side data allows for fast identify operations to be performed, as no external queries are necessary; however, this can cause the map's load time to increase. When enabled, all fields that are configured in the layer's PopupTemplate will load client-side. The default is false.

    Returns boolean

  • set enableClientSideData(isEnabled): void
  • Parameters

    • isEnabled: boolean

    Returns void

  • get featureSettings(): FeatureSettings
  • Default settings that apply to features originating from this source.

    Returns FeatureSettings

  • get groundExtension(): GroundExtension
  • The parent ground extension if the extended layer is an elevation layer in a ground object.

    Returns GroundExtension

  • get hasFeatures(): boolean
  • Determines whether this type of layer is capable of producing features.

    Returns boolean

  • Hyperlinks associated with the feature source.

    Returns Collection<Hyperlink>

  • get id(): string
  • The unique ID for this entity.

    Returns string

  • get initialDefinitionExpression(): string
  • String value containing the initial definition expression configured on the layer.

    Returns string

  • get initialRenderer(): RendererUnion
  • A clone of the initial renderer, if any, that the ESRI layer uses to display data on the map.

    Returns RendererUnion

  • get initialVisibility(): boolean
  • Indicates the initial layer visibility.

    Returns boolean

  • get isEffectivelyVisible(): boolean
  • The effective visibility for this layer extension.

    Returns boolean

  • get itemType(): string
  • The item type for this entity when it participates in an App.

    Returns string

  • get layer(): SceneLayer
  • The Esri Layer object being extended.

    Returns SceneLayer

  • get mapExtension(): MapExtension
  • The parent map extension.

    Returns MapExtension

  • get relationships(): Collection<Relationship>
  • Relationships to other feature sources.

    Returns Collection<Relationship>

  • get renderer(): RendererUnion
  • The renderer, if any, that the ESRI layer uses to display data on the map.

    Returns RendererUnion

  • get schema(): Schema
  • Metadata about features originating from this source, such as fields, domains, and geometry type.

    Returns Schema

  • get sublayersAreReadOnly(): boolean
  • Determines whether the type of layer being extended has a readonly sublayer collection.

    Returns boolean

  • get supportsSublayers(): boolean
  • Determines whether this type of layer is capable of having sublayers.

    Returns boolean

  • get taskSettings(): TaskSettings
  • Settings that affect whether a feature source participates in various tasks that are performed on a map.

    Returns TaskSettings

  • get visibilityMode(): GroupLayerVisibilityMode
  • Indicates how to manage the visibility of the children layers or sublayers.

    Returns GroupLayerVisibilityMode

  • set visibilityMode(value): void
  • Parameters

    • value: GroupLayerVisibilityMode

    Returns void

Methods

  • Called to add new features. Subclasses must override this if they support adding features.

    Parameters

    • features: Iterable<Feature, any, any>

      The features to add.

    • Optionaloptions: FeatureWriteOptions

      Additional options that control how the feature is saved.

    Returns Promise<void>

  • Called to apply layer properties to a layer.

    Parameters

    • properties: LayerProperties

      The layer properties to apply.

    • layer: Layer

      The layer to apply properties to.

    Returns Promise<void>

  • Apply properties from a portal item to an ESRI API Layer object.

    Parameters

    • portalItem: PortalItem

      The portal item to apply.

    Returns Promise<void>

  • Called to create an Esri layer from layer properties.

    Parameters

    Returns Promise<Layer>

  • Called to remove attachments from a feature. Subclasses must override this if they support feature attachments.

    Parameters

    • feature: Feature

      The feature to delete attachments from.

    • attachments: (string | Attachment)[]

      The attachments or the IDs of the attachments to delete.

    Returns Promise<void>

  • Called to delete features. Subclasses must override this if they support deleting features.

    Parameters

    • ids: string[]

      The IDs of the features to delete.

    • Optionaloptions: FeatureWriteOptions

      Additional options that control how the features are deleted.

    Returns Promise<void>

  • Called to retrieve attachments for a feature. Subclasses must override this if they support feature attachments.

    Parameters

    • feature: Feature

      The feature to get attachments for.

    Returns Promise<Attachment[]>

  • Called to retrieve features. Subclasses must override this if they support querying for features.

    Parameters

    • ids: string[]

      The unique IDs of features to retrieve.

    • Optionaloptions: FeatureReadOptions

      Options that control what gets returned.

    Returns AsyncIterable<Feature, any, any>

  • Overridden in child sublayer extensions that need to add additional properties when serializing layer references.

    Returns Record<string, unknown>

  • Called prior to loading the layer in order to perform any extra initialization.

    Returns Promise<void>

  • Determines whether the layer is of the right type for the type of layer extension.

    Parameters

    • layer: Layer

      The layer to validate.

    Returns boolean

  • Called to perform cleanup. Subclasses should override this method rather than destroy() to perform custom cleanup.

    Returns Promise<void>

  • Called after normal initialization. Note: Child items are initialized before this is called.

    Returns Promise<void>

  • Called to update features. Subclasses must override this if they support updating features.

    Parameters

    • features: Iterable<Feature, any, any>

      The feature to update.

    • Optionaloptions: FeatureWriteOptions

      Additional options that control how the feature is saved.

    Returns Promise<void>

  • Deletes attachments from a feature.

    Parameters

    • feature: Feature

      The feature to delete attachments from.

    • attachments: (string | Attachment)[]

      The attachments or the IDs of the attachments to delete from the feature.

    Returns Promise<void>

  • Deletes features from their source. If the source does not support deleting features, then an InvalidOperationError will be thrown (see capabilities).

    Parameters

    • ids: string[]

      The IDs of the features to delete.

    • Optionaloptions: FeatureWriteOptions

      Additional options that control how the features are deleted.

    Returns Promise<void>

  • Deletes features from their source. If the source does not support deleting features, then an InvalidOperationError will be thrown (see capabilities).

    Parameters

    • features: Iterable<Feature, any, any>

      The features to delete.

    • Optionaloptions: FeatureWriteOptions

      Additional options that control how the features are deleted.

    Returns Promise<void>

  • A clean-up function that should get called whenever the item is disposed of.

    Returns Promise<void>

  • Gets a feature by ID. If no such feature exists, the promise is rejected with an instance of NotFoundError.

    Parameters

    • id: string

      The ID of the feature to retrieve.

    • Optionaloptions: FeatureReadOptions

      Additional options that control how the feature is retrieved.

    Returns Promise<Feature>

  • Gets a set of features by their IDs.

    Parameters

    • ids: string[]

      The IDs of the features to retrieve.

    • Optionaloptions: FeatureReadOptions

      Additional Options that control how the features are retrieved.

    Returns AsyncIterable<Feature, any, any>

  • Returns the full extent of the source that contains all included features.

    Returns Extent

  • Creates an item:// URI reference to this entity.

    Returns string