Constructors
Methods
didSignal
- didSignal(maximumWaitMs): Promise<boolean>
Returns Promise<boolean>
flush
- flush(): void
Returns void
forSignal
- forSignal(maximumWaitMs?): Promise<void>
Parameters
Optional
maximumWaitMs: number
Returns Promise<void>
signal
- signal(): void
Returns void
Simple synchronisation. Supports only a single signal/waiter. Expects one or more calls to .signal() for .forSignal() to resolve
forSignal
can also take a maximum time to wait. If the time elapses, an exception is thrown.didSignal returns true/false if signal happened rather than throwing an exception.