pub trait WorkerGlobalScopeMethods {
Show 20 methods // Required methods fn Self_(&self) -> Root<Dom<WorkerGlobalScope>>; fn Location(&self) -> Root<Dom<WorkerLocation>>; fn GetOnerror(&self) -> Option<Rc<OnErrorEventHandlerNonNull>>; fn SetOnerror(&self, value: Option<Rc<OnErrorEventHandlerNonNull>>); fn ImportScripts( &self, urls: Vec<DOMString>, _can_gc: CanGc, ) -> Result<(), Error>; fn Navigator(&self) -> Root<Dom<WorkerNavigator>>; fn Origin(&self) -> USVString; fn Btoa(&self, data: DOMString) -> Result<DOMString, Error>; fn Atob(&self, data: DOMString) -> Result<DOMString, Error>; fn SetTimeout( &self, cx: SafeJSContext, handler: StringOrFunction, timeout: i32, arguments: Vec<HandleValue<'_>>, ) -> i32; fn ClearTimeout(&self, handle: i32); fn SetInterval( &self, cx: SafeJSContext, handler: StringOrFunction, timeout: i32, arguments: Vec<HandleValue<'_>>, ) -> i32; fn ClearInterval(&self, handle: i32); fn QueueMicrotask(&self, callback: Rc<VoidFunction>); fn CreateImageBitmap( &self, image: HTMLImageElementOrHTMLCanvasElementOrOffscreenCanvasOrCSSStyleValueOrBlobOrImageData, options: &ImageBitmapOptions, _can_gc: CanGc, ) -> Rc<Promise>; fn StructuredClone( &self, cx: SafeJSContext, value: HandleValue<'_>, options: RootedTraceableBox<StructuredSerializeOptions>, rval: MutableHandleValue<'_>, ) -> Result<(), Error>; fn Crypto(&self) -> Root<Dom<Crypto>>; fn Performance(&self) -> Root<Dom<Performance>>; fn IsSecureContext(&self) -> bool; fn Fetch( &self, input: RequestOrUSVString, init: RootedTraceableBox<RequestInit>, _comp: InRealm<'_>, _can_gc: CanGc, ) -> Rc<Promise>;
}

Required Methods§

source

fn Self_(&self) -> Root<Dom<WorkerGlobalScope>>

source

fn Location(&self) -> Root<Dom<WorkerLocation>>

source

fn GetOnerror(&self) -> Option<Rc<OnErrorEventHandlerNonNull>>

source

fn SetOnerror(&self, value: Option<Rc<OnErrorEventHandlerNonNull>>)

source

fn ImportScripts( &self, urls: Vec<DOMString>, _can_gc: CanGc, ) -> Result<(), Error>

source

fn Navigator(&self) -> Root<Dom<WorkerNavigator>>

source

fn Origin(&self) -> USVString

source

fn Btoa(&self, data: DOMString) -> Result<DOMString, Error>

source

fn Atob(&self, data: DOMString) -> Result<DOMString, Error>

source

fn SetTimeout( &self, cx: SafeJSContext, handler: StringOrFunction, timeout: i32, arguments: Vec<HandleValue<'_>>, ) -> i32

source

fn ClearTimeout(&self, handle: i32)

source

fn SetInterval( &self, cx: SafeJSContext, handler: StringOrFunction, timeout: i32, arguments: Vec<HandleValue<'_>>, ) -> i32

source

fn ClearInterval(&self, handle: i32)

source

fn QueueMicrotask(&self, callback: Rc<VoidFunction>)

source

fn CreateImageBitmap( &self, image: HTMLImageElementOrHTMLCanvasElementOrOffscreenCanvasOrCSSStyleValueOrBlobOrImageData, options: &ImageBitmapOptions, _can_gc: CanGc, ) -> Rc<Promise>

source

fn StructuredClone( &self, cx: SafeJSContext, value: HandleValue<'_>, options: RootedTraceableBox<StructuredSerializeOptions>, rval: MutableHandleValue<'_>, ) -> Result<(), Error>

source

fn Crypto(&self) -> Root<Dom<Crypto>>

source

fn Performance(&self) -> Root<Dom<Performance>>

source

fn IsSecureContext(&self) -> bool

source

fn Fetch( &self, input: RequestOrUSVString, init: RootedTraceableBox<RequestInit>, _comp: InRealm<'_>, _can_gc: CanGc, ) -> Rc<Promise>

Implementors§