web_sys/features/
gen_NamedNodeMap.rs1#![allow(unused_imports)]
2#![allow(clippy::all)]
3use super::*;
4use wasm_bindgen::prelude::*;
5#[wasm_bindgen]
6extern "C" {
7 # [wasm_bindgen (extends = :: js_sys :: Object , js_name = NamedNodeMap , typescript_type = "NamedNodeMap")]
8 #[derive(Debug, Clone, PartialEq, Eq)]
9 #[doc = "The `NamedNodeMap` class."]
10 #[doc = ""]
11 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/NamedNodeMap)"]
12 #[doc = ""]
13 #[doc = "*This API requires the following crate features to be activated: `NamedNodeMap`*"]
14 pub type NamedNodeMap;
15 # [wasm_bindgen (structural , method , getter , js_class = "NamedNodeMap" , js_name = length)]
16 #[doc = "Getter for the `length` field of this object."]
17 #[doc = ""]
18 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/NamedNodeMap/length)"]
19 #[doc = ""]
20 #[doc = "*This API requires the following crate features to be activated: `NamedNodeMap`*"]
21 pub fn length(this: &NamedNodeMap) -> u32;
22 #[cfg(feature = "Attr")]
23 # [wasm_bindgen (method , structural , js_class = "NamedNodeMap" , js_name = getNamedItem)]
24 #[doc = "The `getNamedItem()` method."]
25 #[doc = ""]
26 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/NamedNodeMap/getNamedItem)"]
27 #[doc = ""]
28 #[doc = "*This API requires the following crate features to be activated: `Attr`, `NamedNodeMap`*"]
29 pub fn get_named_item(this: &NamedNodeMap, name: &str) -> Option<Attr>;
30 #[cfg(feature = "Attr")]
31 # [wasm_bindgen (method , structural , js_class = "NamedNodeMap" , js_name = getNamedItemNS)]
32 #[doc = "The `getNamedItemNS()` method."]
33 #[doc = ""]
34 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/NamedNodeMap/getNamedItemNS)"]
35 #[doc = ""]
36 #[doc = "*This API requires the following crate features to be activated: `Attr`, `NamedNodeMap`*"]
37 pub fn get_named_item_ns(
38 this: &NamedNodeMap,
39 namespace_uri: Option<&str>,
40 local_name: &str,
41 ) -> Option<Attr>;
42 #[cfg(feature = "Attr")]
43 # [wasm_bindgen (method , structural , js_class = "NamedNodeMap" , js_name = item)]
44 #[doc = "The `item()` method."]
45 #[doc = ""]
46 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/NamedNodeMap/item)"]
47 #[doc = ""]
48 #[doc = "*This API requires the following crate features to be activated: `Attr`, `NamedNodeMap`*"]
49 pub fn item(this: &NamedNodeMap, index: u32) -> Option<Attr>;
50 #[cfg(feature = "Attr")]
51 # [wasm_bindgen (catch , method , structural , js_class = "NamedNodeMap" , js_name = removeNamedItem)]
52 #[doc = "The `removeNamedItem()` method."]
53 #[doc = ""]
54 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/NamedNodeMap/removeNamedItem)"]
55 #[doc = ""]
56 #[doc = "*This API requires the following crate features to be activated: `Attr`, `NamedNodeMap`*"]
57 pub fn remove_named_item(this: &NamedNodeMap, name: &str) -> Result<Attr, JsValue>;
58 #[cfg(feature = "Attr")]
59 # [wasm_bindgen (catch , method , structural , js_class = "NamedNodeMap" , js_name = removeNamedItemNS)]
60 #[doc = "The `removeNamedItemNS()` method."]
61 #[doc = ""]
62 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/NamedNodeMap/removeNamedItemNS)"]
63 #[doc = ""]
64 #[doc = "*This API requires the following crate features to be activated: `Attr`, `NamedNodeMap`*"]
65 pub fn remove_named_item_ns(
66 this: &NamedNodeMap,
67 namespace_uri: Option<&str>,
68 local_name: &str,
69 ) -> Result<Attr, JsValue>;
70 #[cfg(feature = "Attr")]
71 # [wasm_bindgen (catch , method , structural , js_class = "NamedNodeMap" , js_name = setNamedItem)]
72 #[doc = "The `setNamedItem()` method."]
73 #[doc = ""]
74 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/NamedNodeMap/setNamedItem)"]
75 #[doc = ""]
76 #[doc = "*This API requires the following crate features to be activated: `Attr`, `NamedNodeMap`*"]
77 pub fn set_named_item(this: &NamedNodeMap, arg: &Attr) -> Result<Option<Attr>, JsValue>;
78 #[cfg(feature = "Attr")]
79 # [wasm_bindgen (catch , method , structural , js_class = "NamedNodeMap" , js_name = setNamedItemNS)]
80 #[doc = "The `setNamedItemNS()` method."]
81 #[doc = ""]
82 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/NamedNodeMap/setNamedItemNS)"]
83 #[doc = ""]
84 #[doc = "*This API requires the following crate features to be activated: `Attr`, `NamedNodeMap`*"]
85 pub fn set_named_item_ns(this: &NamedNodeMap, arg: &Attr) -> Result<Option<Attr>, JsValue>;
86 #[cfg(feature = "Attr")]
87 #[wasm_bindgen(method, structural, js_class = "NamedNodeMap", indexing_getter)]
88 #[doc = "Indexing getter. As in the literal Javascript `this[key]`."]
89 #[doc = ""]
90 #[doc = ""]
91 #[doc = ""]
92 #[doc = "*This API requires the following crate features to be activated: `Attr`, `NamedNodeMap`*"]
93 pub fn get_with_name(this: &NamedNodeMap, name: &str) -> Option<Attr>;
94 #[cfg(feature = "Attr")]
95 #[wasm_bindgen(method, structural, js_class = "NamedNodeMap", indexing_getter)]
96 #[doc = "Indexing getter. As in the literal Javascript `this[key]`."]
97 #[doc = ""]
98 #[doc = ""]
99 #[doc = ""]
100 #[doc = "*This API requires the following crate features to be activated: `Attr`, `NamedNodeMap`*"]
101 pub fn get_with_index(this: &NamedNodeMap, index: u32) -> Option<Attr>;
102}