Struct quickjs_runtime::quickjsruntime::QuickJsRuntime [−][src]
pub struct QuickJsRuntime { /* fields omitted */ }Implementations
pub fn add_context_init_hook<H>(&self, hook: H) -> Result<(), JsError> where
H: Fn(&QuickJsRuntime, &QuickJsContext) -> Result<(), JsError> + 'static, Safety
When passing a context pointer please make sure the corresponding QuickJsContext is still valid
pub fn set_interrupt_handler<I: Fn(&QuickJsRuntime) -> bool + 'static>(
&mut self,
interrupt_handler: I
) -> &mut Selfpub fn with_all_module_loaders<C, R>(&self, consumer: C) -> Option<R> where
C: Fn(&dyn ModuleLoader) -> Option<R>, run pending jobs if avail
todo
move this to a quickjs_utils::pending_jobs so it can be used without doing QuickjsRuntime.do_with()
Trait Implementations
type JsValueAdapterType = JSValueReftype JsPromiseAdapterType = PromiseReftype JsRealmAdapterType = QuickJsContextAuto Trait Implementations
impl !RefUnwindSafe for QuickJsRuntimeimpl !Send for QuickJsRuntimeimpl !Sync for QuickJsRuntimeimpl Unpin for QuickJsRuntimeimpl !UnwindSafe for QuickJsRuntime