web_sys/features/
gen_WorkerDebuggerGlobalScope.rs

1#![allow(unused_imports)]
2#![allow(clippy::all)]
3use super::*;
4use wasm_bindgen::prelude::*;
5#[wasm_bindgen]
6extern "C" {
7    # [wasm_bindgen (extends = EventTarget , extends = :: js_sys :: Object , js_name = WorkerDebuggerGlobalScope , typescript_type = "WorkerDebuggerGlobalScope")]
8    #[derive(Debug, Clone, PartialEq, Eq)]
9    #[doc = "The `WorkerDebuggerGlobalScope` class."]
10    #[doc = ""]
11    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/WorkerDebuggerGlobalScope)"]
12    #[doc = ""]
13    #[doc = "*This API requires the following crate features to be activated: `WorkerDebuggerGlobalScope`*"]
14    pub type WorkerDebuggerGlobalScope;
15    # [wasm_bindgen (structural , catch , method , getter , js_class = "WorkerDebuggerGlobalScope" , js_name = global)]
16    #[doc = "Getter for the `global` field of this object."]
17    #[doc = ""]
18    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/WorkerDebuggerGlobalScope/global)"]
19    #[doc = ""]
20    #[doc = "*This API requires the following crate features to be activated: `WorkerDebuggerGlobalScope`*"]
21    pub fn global(this: &WorkerDebuggerGlobalScope) -> Result<::js_sys::Object, JsValue>;
22    # [wasm_bindgen (structural , method , getter , js_class = "WorkerDebuggerGlobalScope" , js_name = onmessage)]
23    #[doc = "Getter for the `onmessage` field of this object."]
24    #[doc = ""]
25    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/WorkerDebuggerGlobalScope/onmessage)"]
26    #[doc = ""]
27    #[doc = "*This API requires the following crate features to be activated: `WorkerDebuggerGlobalScope`*"]
28    pub fn onmessage(this: &WorkerDebuggerGlobalScope) -> Option<::js_sys::Function>;
29    # [wasm_bindgen (structural , method , setter , js_class = "WorkerDebuggerGlobalScope" , js_name = onmessage)]
30    #[doc = "Setter for the `onmessage` field of this object."]
31    #[doc = ""]
32    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/WorkerDebuggerGlobalScope/onmessage)"]
33    #[doc = ""]
34    #[doc = "*This API requires the following crate features to be activated: `WorkerDebuggerGlobalScope`*"]
35    pub fn set_onmessage(this: &WorkerDebuggerGlobalScope, value: Option<&::js_sys::Function>);
36    # [wasm_bindgen (catch , method , structural , js_class = "WorkerDebuggerGlobalScope" , js_name = createSandbox)]
37    #[doc = "The `createSandbox()` method."]
38    #[doc = ""]
39    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/WorkerDebuggerGlobalScope/createSandbox)"]
40    #[doc = ""]
41    #[doc = "*This API requires the following crate features to be activated: `WorkerDebuggerGlobalScope`*"]
42    pub fn create_sandbox(
43        this: &WorkerDebuggerGlobalScope,
44        name: &str,
45        prototype: &::js_sys::Object,
46    ) -> Result<::js_sys::Object, JsValue>;
47    # [wasm_bindgen (method , structural , js_class = "WorkerDebuggerGlobalScope" , js_name = dump)]
48    #[doc = "The `dump()` method."]
49    #[doc = ""]
50    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/WorkerDebuggerGlobalScope/dump)"]
51    #[doc = ""]
52    #[doc = "*This API requires the following crate features to be activated: `WorkerDebuggerGlobalScope`*"]
53    pub fn dump(this: &WorkerDebuggerGlobalScope);
54    # [wasm_bindgen (method , structural , js_class = "WorkerDebuggerGlobalScope" , js_name = dump)]
55    #[doc = "The `dump()` method."]
56    #[doc = ""]
57    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/WorkerDebuggerGlobalScope/dump)"]
58    #[doc = ""]
59    #[doc = "*This API requires the following crate features to be activated: `WorkerDebuggerGlobalScope`*"]
60    pub fn dump_with_string(this: &WorkerDebuggerGlobalScope, string: &str);
61    # [wasm_bindgen (method , structural , js_class = "WorkerDebuggerGlobalScope" , js_name = enterEventLoop)]
62    #[doc = "The `enterEventLoop()` method."]
63    #[doc = ""]
64    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/WorkerDebuggerGlobalScope/enterEventLoop)"]
65    #[doc = ""]
66    #[doc = "*This API requires the following crate features to be activated: `WorkerDebuggerGlobalScope`*"]
67    pub fn enter_event_loop(this: &WorkerDebuggerGlobalScope);
68    # [wasm_bindgen (method , structural , js_class = "WorkerDebuggerGlobalScope" , js_name = leaveEventLoop)]
69    #[doc = "The `leaveEventLoop()` method."]
70    #[doc = ""]
71    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/WorkerDebuggerGlobalScope/leaveEventLoop)"]
72    #[doc = ""]
73    #[doc = "*This API requires the following crate features to be activated: `WorkerDebuggerGlobalScope`*"]
74    pub fn leave_event_loop(this: &WorkerDebuggerGlobalScope);
75    # [wasm_bindgen (catch , method , structural , js_class = "WorkerDebuggerGlobalScope" , js_name = loadSubScript)]
76    #[doc = "The `loadSubScript()` method."]
77    #[doc = ""]
78    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/WorkerDebuggerGlobalScope/loadSubScript)"]
79    #[doc = ""]
80    #[doc = "*This API requires the following crate features to be activated: `WorkerDebuggerGlobalScope`*"]
81    pub fn load_sub_script(this: &WorkerDebuggerGlobalScope, url: &str) -> Result<(), JsValue>;
82    # [wasm_bindgen (catch , method , structural , js_class = "WorkerDebuggerGlobalScope" , js_name = loadSubScript)]
83    #[doc = "The `loadSubScript()` method."]
84    #[doc = ""]
85    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/WorkerDebuggerGlobalScope/loadSubScript)"]
86    #[doc = ""]
87    #[doc = "*This API requires the following crate features to be activated: `WorkerDebuggerGlobalScope`*"]
88    pub fn load_sub_script_with_sandbox(
89        this: &WorkerDebuggerGlobalScope,
90        url: &str,
91        sandbox: &::js_sys::Object,
92    ) -> Result<(), JsValue>;
93    # [wasm_bindgen (method , structural , js_class = "WorkerDebuggerGlobalScope" , js_name = postMessage)]
94    #[doc = "The `postMessage()` method."]
95    #[doc = ""]
96    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/WorkerDebuggerGlobalScope/postMessage)"]
97    #[doc = ""]
98    #[doc = "*This API requires the following crate features to be activated: `WorkerDebuggerGlobalScope`*"]
99    pub fn post_message(this: &WorkerDebuggerGlobalScope, message: &str);
100    # [wasm_bindgen (method , structural , js_class = "WorkerDebuggerGlobalScope" , js_name = reportError)]
101    #[doc = "The `reportError()` method."]
102    #[doc = ""]
103    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/WorkerDebuggerGlobalScope/reportError)"]
104    #[doc = ""]
105    #[doc = "*This API requires the following crate features to be activated: `WorkerDebuggerGlobalScope`*"]
106    pub fn report_error(this: &WorkerDebuggerGlobalScope, message: &str);
107    # [wasm_bindgen (catch , method , structural , js_class = "WorkerDebuggerGlobalScope" , js_name = retrieveConsoleEvents)]
108    #[doc = "The `retrieveConsoleEvents()` method."]
109    #[doc = ""]
110    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/WorkerDebuggerGlobalScope/retrieveConsoleEvents)"]
111    #[doc = ""]
112    #[doc = "*This API requires the following crate features to be activated: `WorkerDebuggerGlobalScope`*"]
113    pub fn retrieve_console_events(
114        this: &WorkerDebuggerGlobalScope,
115    ) -> Result<::js_sys::Array, JsValue>;
116    # [wasm_bindgen (catch , method , structural , js_class = "WorkerDebuggerGlobalScope" , js_name = setConsoleEventHandler)]
117    #[doc = "The `setConsoleEventHandler()` method."]
118    #[doc = ""]
119    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/WorkerDebuggerGlobalScope/setConsoleEventHandler)"]
120    #[doc = ""]
121    #[doc = "*This API requires the following crate features to be activated: `WorkerDebuggerGlobalScope`*"]
122    pub fn set_console_event_handler(
123        this: &WorkerDebuggerGlobalScope,
124        handler: Option<&::js_sys::Function>,
125    ) -> Result<(), JsValue>;
126    # [wasm_bindgen (catch , method , structural , js_class = "WorkerDebuggerGlobalScope" , js_name = setImmediate)]
127    #[doc = "The `setImmediate()` method."]
128    #[doc = ""]
129    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/WorkerDebuggerGlobalScope/setImmediate)"]
130    #[doc = ""]
131    #[doc = "*This API requires the following crate features to be activated: `WorkerDebuggerGlobalScope`*"]
132    pub fn set_immediate(
133        this: &WorkerDebuggerGlobalScope,
134        handler: &::js_sys::Function,
135    ) -> Result<(), JsValue>;
136}