HookCallbacks
[<Interface>]
type HookCallbacks =
abstract member after: (float -> unit) option with get, set
abstract member before: (float -> unit) option with get, set
abstract member destroy: (float -> unit) option with get, set
abstract member init: Init option with get, set
abstract member promiseResolve: (float -> unit) option with get, set
static member Create (?init: Init, ?before: (float -> unit), ?after: (float -> unit), ?promiseResolve: (float -> unit), ?destroy: (float -> unit)) : HookCallbacks| Assembly | Xantham.Fable.Node |
| Attributes | [<Interface>] |
Properties
abstract member after: (float -> unit) option with get, set
abstract member after: (float -> unit) option with get, setCalled immediately after the callback specified in before is completed.
If an uncaught exception occurs during execution of the callback, then after will run after the 'uncaughtException' event is emitted or a domain's handler runs.
| Parameter | |
|---|---|
asyncId | the unique identifier assigned to the resource which has executed the callback. |
abstract member before: (float -> unit) option with get, set
abstract member before: (float -> unit) option with get, setWhen an asynchronous operation is initiated or completes a callback is called to notify the user. The before callback is called just before said callback is executed.
| Parameter | |
|---|---|
asyncId | the unique identifier assigned to the resource about to execute the callback. |
abstract member destroy: (float -> unit) option with get, set
abstract member destroy: (float -> unit) option with get, setCalled after the resource corresponding to asyncId is destroyed
| Parameter | |
|---|---|
asyncId | a unique ID for the async resource |
abstract member init: Init option with get, set
abstract member init: Init option with get, setCalled when a class is constructed that has the possibility to emit an asynchronous event.
| Parameter | |
|---|---|
asyncId | A unique ID for the async resource |
type | The type of the async resource |
triggerAsyncId | The unique ID of the async resource in whose execution context this async resource was created |
resource | Reference to the resource representing the async operation, needs to be released during destroy |
abstract member promiseResolve: (float -> unit) option with get, set
abstract member promiseResolve: (float -> unit) option with get, setCalled when a promise has resolve() called. This may not be in the same execution id as the promise itself.
| Parameter | |
|---|---|
asyncId | the unique id for the promise that was resolve()d. |