A class for managing blockchain events.

Constructors

Properties

_eventCallbackManager: default

The event callback manager.

_eventChannelClient: default

The event channel client.

Methods

  • Opens a new event channel.

    Parameters

    • Optional connectionCallback: ConnectionCallback
    • Optional disconnectionCallback: DisconnectionCallback

      The disconnection callback function.

    • Optional customClientId: string

      The custom client id to set.

    Returns Promise<void>

  • Returns the custom client id of the event channel saved on the client side.

    Returns string

  • Subscribes to blockchain events.

    Parameters

    Returns string

    The created filter ID.

  • Subscribes to blockchain events.

    Parameters

    • eventType: "VALUE_CHANGED"
    • config: ValueChangedEventConfig

      The blockchain event configuraiton.

    • Optional eventCallback: ((event) => void)

      The blockchain event callback function.

    • Optional errorCallback: BlockchainErrorCallback

      The blockchain error callback function.

    Returns string

    The created filter ID.

  • Subscribes to blockchain events.

    Parameters

    Returns string

    The created filter ID.