The Monitor Module is useful to poll for changes, e.g. on the Burst blockchain, especially for confirmations of transactions
It is designed to be generic, such that it's not only usable for the blockchain also.
Monitors are serializable, such they can be persisted and restored, which is useful for web apps.
A singleton instance of the ConsoleLogger
A singleton instance of the VoidLogger
This is the type definition for the monitor's fetch function. The fetch function will be called periodically by the monitor. It returns arbitrary data that will be processed by the MonitorPredicateFunction
This is the type definition for the monitor's post-fetch processing function.
This predicate function will be called immediately after the monitor fetched
data using the MonitorFetchFunction. This function checks for
a certain condition and returns true or false. On
true the monitor stops fetching
and triggers the Monitor.onFulfilled callback