electron_sys/class/
debugger.rs

1use js_sys::Promise;
2use node_sys::events::EventEmitter;
3use wasm_bindgen::prelude::*;
4
5#[wasm_bindgen(module = "electron")]
6extern {
7    #[wasm_bindgen(extends = EventEmitter)]
8    #[derive(Clone, Debug)]
9    /// Docs: http://electronjs.org/docs/api/debugger
10    pub type Debugger;
11
12    //******************//
13    // Instance Methods //
14    //******************//
15
16    #[wasm_bindgen(method)]
17    pub fn attach(this: &Debugger, protocol_version: Option<&str>);
18
19    #[wasm_bindgen(method)]
20    pub fn detach(this: &Debugger);
21
22    #[wasm_bindgen(method, js_name = "isAttached")]
23    pub fn is_attached(this: &Debugger);
24
25    #[must_use]
26    #[wasm_bindgen(method, js_name = "sendCommand")]
27    pub fn send_command(this: &Debugger, method: &str, command_params: &JsValue) -> Promise;
28}