web_sys/features/
gen_PresentationConnectionCloseEvent.rs1#![allow(unused_imports)]
2#![allow(clippy::all)]
3use super::*;
4use wasm_bindgen::prelude::*;
5#[wasm_bindgen]
6extern "C" {
7 # [wasm_bindgen (extends = Event , extends = :: js_sys :: Object , js_name = PresentationConnectionCloseEvent , typescript_type = "PresentationConnectionCloseEvent")]
8 #[derive(Debug, Clone, PartialEq, Eq)]
9 #[doc = "The `PresentationConnectionCloseEvent` class."]
10 #[doc = ""]
11 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/PresentationConnectionCloseEvent)"]
12 #[doc = ""]
13 #[doc = "*This API requires the following crate features to be activated: `PresentationConnectionCloseEvent`*"]
14 pub type PresentationConnectionCloseEvent;
15 #[cfg(feature = "PresentationConnectionClosedReason")]
16 # [wasm_bindgen (structural , method , getter , js_class = "PresentationConnectionCloseEvent" , js_name = reason)]
17 #[doc = "Getter for the `reason` field of this object."]
18 #[doc = ""]
19 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/PresentationConnectionCloseEvent/reason)"]
20 #[doc = ""]
21 #[doc = "*This API requires the following crate features to be activated: `PresentationConnectionCloseEvent`, `PresentationConnectionClosedReason`*"]
22 pub fn reason(this: &PresentationConnectionCloseEvent) -> PresentationConnectionClosedReason;
23 # [wasm_bindgen (structural , method , getter , js_class = "PresentationConnectionCloseEvent" , js_name = message)]
24 #[doc = "Getter for the `message` field of this object."]
25 #[doc = ""]
26 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/PresentationConnectionCloseEvent/message)"]
27 #[doc = ""]
28 #[doc = "*This API requires the following crate features to be activated: `PresentationConnectionCloseEvent`*"]
29 pub fn message(this: &PresentationConnectionCloseEvent) -> ::alloc::string::String;
30 #[cfg(feature = "PresentationConnectionCloseEventInit")]
31 #[wasm_bindgen(catch, constructor, js_class = "PresentationConnectionCloseEvent")]
32 #[doc = "The `new PresentationConnectionCloseEvent(..)` constructor, creating a new instance of `PresentationConnectionCloseEvent`."]
33 #[doc = ""]
34 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/PresentationConnectionCloseEvent/PresentationConnectionCloseEvent)"]
35 #[doc = ""]
36 #[doc = "*This API requires the following crate features to be activated: `PresentationConnectionCloseEvent`, `PresentationConnectionCloseEventInit`*"]
37 pub fn new(
38 type_: &str,
39 event_init_dict: &PresentationConnectionCloseEventInit,
40 ) -> Result<PresentationConnectionCloseEvent, JsValue>;
41}