A data/_Relationship!Relationship that works by querying the queryRelatedRecords endpoint of a FeatureLayer, Table, or ArcGIS Sublayer.

Hierarchy (view full)

Constructors

Properties

_handles: Handles<unknown, ResourceHandle>
_id: string

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

_itemType: string = ItemType.RELATIONSHIP

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

_source: FeatureSource

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

cardinality: Cardinality

The cardinality of the relationship.

destinationForeignKey: string

In attributed relationships, this is the foreign key in the intermediate table that relates the rows of the intermediate table to the destination layer or table. This property will only be exposed if the relationship is attributed.

keyField: string

The key field in the source.

originForeignKey: string

In an attributed relationship, originForeignKey is the foreign key in the intermediate table, which relates the rows of the intermediate table to the origin layer or table. This property will only be exposed if the relationship is attributed.

queryService: QueryService

The tasks/query/QueryService!QueryService to use for fetching related features. The service must be configured with a provider that can handle the related source.

relatedKeyField: string

The key field in the related source.

relatedSource: FeatureSource

The feature source with related data, if available.

relationshipTableId: number

The ID of the intermediate table in the feature service for attributed relationships. This property will only be exposed if the relationship is attributed.

relationshipType: string = "ArcGISRelationship"

The type of relationship.

title: string

The human-readable name for the relationship.

Accessors

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

    Returns string

  • get isAttributed(): boolean
  • Whether the relationship is attributed.

    Returns boolean

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

    Returns string

  • get source(): FeatureSource
  • The feature source that owns this relationship.

    Returns FeatureSource

Methods

  • 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>

  • Sets the properties for this item.

    This version will also await any asynchronous logic that is needed to set the properties.

    Parameters

    Returns Promise<void>

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

    Returns Promise<void>

  • Waits for all deserialization logic initiated thus far to finish, whether invoked by passing properties into the constructor, or by invoking assignProperties() or assignPropertiesAsync().

    Returns Promise<void>