web_sys/features/
gen_NetworkInformation.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 = NetworkInformation , typescript_type = "NetworkInformation")]
8    #[derive(Debug, Clone, PartialEq, Eq)]
9    #[doc = "The `NetworkInformation` class."]
10    #[doc = ""]
11    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/NetworkInformation)"]
12    #[doc = ""]
13    #[doc = "*This API requires the following crate features to be activated: `NetworkInformation`*"]
14    pub type NetworkInformation;
15    #[cfg(feature = "ConnectionType")]
16    # [wasm_bindgen (structural , method , getter , js_class = "NetworkInformation" , js_name = type)]
17    #[doc = "Getter for the `type` field of this object."]
18    #[doc = ""]
19    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/NetworkInformation/type)"]
20    #[doc = ""]
21    #[doc = "*This API requires the following crate features to be activated: `ConnectionType`, `NetworkInformation`*"]
22    pub fn type_(this: &NetworkInformation) -> ConnectionType;
23    # [wasm_bindgen (structural , method , getter , js_class = "NetworkInformation" , js_name = ontypechange)]
24    #[doc = "Getter for the `ontypechange` field of this object."]
25    #[doc = ""]
26    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/NetworkInformation/ontypechange)"]
27    #[doc = ""]
28    #[doc = "*This API requires the following crate features to be activated: `NetworkInformation`*"]
29    pub fn ontypechange(this: &NetworkInformation) -> Option<::js_sys::Function>;
30    # [wasm_bindgen (structural , method , setter , js_class = "NetworkInformation" , js_name = ontypechange)]
31    #[doc = "Setter for the `ontypechange` field of this object."]
32    #[doc = ""]
33    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/NetworkInformation/ontypechange)"]
34    #[doc = ""]
35    #[doc = "*This API requires the following crate features to be activated: `NetworkInformation`*"]
36    pub fn set_ontypechange(this: &NetworkInformation, value: Option<&::js_sys::Function>);
37}