Class: DataDependency

DataDependency~DataDependency(setup, parent)

new DataDependency(setup, parent)

Constructs a DataDependency instance.

Parameters:
Name Type Description
setup Object

The setup object containing name, type, collectionName, and filter properties.

parent Object

The parent component associated with this data dependency.

Source:
Throws:
  • Throws an error if the setup object is not valid.
Type
Error

Members

parent

Gets the parent component associated with this data dependency.

Source:

Methods

addSocketUpdateListener(socketConnection, subsUID)

Adds a socket update listener for real-time data updates.

Parameters:
Name Type Description
socketConnection Object

The socket connection object.

subsUID string

The unique identifier for the subscription.

Source:

(async) load() → {Object|Array}

Loads data based on the data dependency type (doc or list).

Source:
Throws:
  • Throws an error if the data loading fails.
Type
Error
Returns:
  • The loaded data object or array.
Type
Object | Array

(async) updateComponentHandler(ev, socketConnection, subsUID)

Handles real-time component updates and emits the updated component data to the client.

Parameters:
Name Type Description
ev Object

The event object containing update information.

socketConnection Object

The socket connection object.

subsUID string

The unique identifier for the subscription.

Source:
Throws:
  • Throws an error if an update operation fails.
Type
Error