Skip to main content

web_sys/features/
gen_DomStringMap.rs

1#![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 = DOMStringMap , typescript_type = "DOMStringMap")]
8    #[derive(Debug, Clone, PartialEq, Eq)]
9    #[doc = "The `DomStringMap` class."]
10    #[doc = ""]
11    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/DOMStringMap)"]
12    #[doc = ""]
13    #[doc = "*This API requires the following crate features to be activated: `DomStringMap`*"]
14    pub type DomStringMap;
15    #[wasm_bindgen(method, structural, js_class = "DOMStringMap", indexing_getter)]
16    #[doc = "Indexing getter. As in the literal Javascript `this[key]`."]
17    #[doc = ""]
18    #[doc = ""]
19    #[doc = "*This API requires the following crate features to be activated: `DomStringMap`*"]
20    pub fn get(this: &DomStringMap, name: &str) -> Option<::alloc::string::String>;
21    #[wasm_bindgen(catch, method, structural, js_class = "DOMStringMap", indexing_setter)]
22    #[doc = "Indexing setter. As in the literal Javascript `this[key] = value`."]
23    #[doc = ""]
24    #[doc = ""]
25    #[doc = "*This API requires the following crate features to be activated: `DomStringMap`*"]
26    pub fn set(this: &DomStringMap, name: &str, value: &str) -> Result<(), JsValue>;
27    #[wasm_bindgen(method, structural, js_class = "DOMStringMap", indexing_deleter)]
28    #[doc = "Indexing deleter. As in the literal Javascript `delete this[key]`."]
29    #[doc = ""]
30    #[doc = ""]
31    #[doc = "*This API requires the following crate features to be activated: `DomStringMap`*"]
32    pub fn delete(this: &DomStringMap, name: &str);
33}