Struct neon::types::Deferred [−][src]
pub struct Deferred { /* fields omitted */ }This is supported on crate feature
promise-api only.Expand description
Deferred is a handle that can be used to resolve or reject a JsPromise
It is recommended to settle a Deferred with Deferred::settle_with to ensure
exceptions are caught.
On Node-API versions less than 6, dropping a Deferred without settling will
cause a panic. On Node-API 6+, the associated JsPromise will be automatically
rejected.