pub struct Instance {
pub runtime: Runtime,
/* private fields */
}Expand description
The runtime, and the state that outlives a single call.
One per module instance. Node can load an addon into several contexts
(worker threads, vm realms), and each gets its own.
Fields§
§runtime: RuntimeSomewhere to run futures. Node’s loop is not ours to block, so the crate’s futures run on a thread of their own and results come back through a threadsafe function.
Implementations§
Auto Trait Implementations§
impl !Freeze for Instance
impl !RefUnwindSafe for Instance
impl !UnwindSafe for Instance
impl Send for Instance
impl Sync for Instance
impl Unpin for Instance
impl UnsafeUnpin for Instance
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more