Options
All
  • Public
  • Public/Protected
  • All
Menu

Coordinates implementations of AbstractActionReaders and AbstractActionHandlers in a polling loop.

Hierarchy

Index

Constructors

constructor

Properties

Protected actionHandler

actionHandler: AbstractActionHandler

Protected actionReader

actionReader: AbstractActionReader

Private clean

clean: boolean = true

Private error

error: Error | null = null

Protected log

log: Logger
param

An instance of an implemented AbstractActionReader

param

An instance of an implemented AbstractActionHandler

param

Number of milliseconds between each polling loop iteration

Protected pollInterval

pollInterval: number

Private running

running: boolean = false

Private shouldPause

shouldPause: boolean = false

Accessors

info

info:

Information about the current state of Demux

Private status

status:

Methods

Protected checkForBlocks

  • checkForBlocks(isReplay?: boolean): Promise<void>
  • Use the actionReader and actionHandler to process new blocks.

    Parameters

    • Default value isReplay: boolean = false

      Set to true to disable Effects from running until caught up with head block.

    Returns Promise<void>

pause

  • pause(): boolean

replay

  • replay(): Promise<void>

start

  • start(): boolean

watch

  • watch(isReplay?: boolean): Promise<void>
  • Start a polling loop

    Parameters

    • Default value isReplay: boolean = false

      Set to true to disable Effects from running until caught up with head block.

    Returns Promise<void>