web_sys/features/
gen_RcwnStatus.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 = RcwnStatus)]
8    #[derive(Debug, Clone, PartialEq, Eq)]
9    #[doc = "The `RcwnStatus` dictionary."]
10    #[doc = ""]
11    #[doc = "*This API requires the following crate features to be activated: `RcwnStatus`*"]
12    pub type RcwnStatus;
13    #[doc = "Get the `cacheNotSlowCount` field of this object."]
14    #[doc = ""]
15    #[doc = "*This API requires the following crate features to be activated: `RcwnStatus`*"]
16    #[wasm_bindgen(method, getter = "cacheNotSlowCount")]
17    pub fn get_cache_not_slow_count(this: &RcwnStatus) -> Option<u32>;
18    #[doc = "Change the `cacheNotSlowCount` field of this object."]
19    #[doc = ""]
20    #[doc = "*This API requires the following crate features to be activated: `RcwnStatus`*"]
21    #[wasm_bindgen(method, setter = "cacheNotSlowCount")]
22    pub fn set_cache_not_slow_count(this: &RcwnStatus, val: u32);
23    #[doc = "Get the `cacheSlowCount` field of this object."]
24    #[doc = ""]
25    #[doc = "*This API requires the following crate features to be activated: `RcwnStatus`*"]
26    #[wasm_bindgen(method, getter = "cacheSlowCount")]
27    pub fn get_cache_slow_count(this: &RcwnStatus) -> Option<u32>;
28    #[doc = "Change the `cacheSlowCount` field of this object."]
29    #[doc = ""]
30    #[doc = "*This API requires the following crate features to be activated: `RcwnStatus`*"]
31    #[wasm_bindgen(method, setter = "cacheSlowCount")]
32    pub fn set_cache_slow_count(this: &RcwnStatus, val: u32);
33    #[doc = "Get the `perfStats` field of this object."]
34    #[doc = ""]
35    #[doc = "*This API requires the following crate features to be activated: `RcwnStatus`*"]
36    #[wasm_bindgen(method, getter = "perfStats")]
37    pub fn get_perf_stats(this: &RcwnStatus) -> Option<::js_sys::Array>;
38    #[doc = "Change the `perfStats` field of this object."]
39    #[doc = ""]
40    #[doc = "*This API requires the following crate features to be activated: `RcwnStatus`*"]
41    #[wasm_bindgen(method, setter = "perfStats")]
42    pub fn set_perf_stats(this: &RcwnStatus, val: &::wasm_bindgen::JsValue);
43    #[doc = "Get the `rcwnCacheWonCount` field of this object."]
44    #[doc = ""]
45    #[doc = "*This API requires the following crate features to be activated: `RcwnStatus`*"]
46    #[wasm_bindgen(method, getter = "rcwnCacheWonCount")]
47    pub fn get_rcwn_cache_won_count(this: &RcwnStatus) -> Option<u32>;
48    #[doc = "Change the `rcwnCacheWonCount` field of this object."]
49    #[doc = ""]
50    #[doc = "*This API requires the following crate features to be activated: `RcwnStatus`*"]
51    #[wasm_bindgen(method, setter = "rcwnCacheWonCount")]
52    pub fn set_rcwn_cache_won_count(this: &RcwnStatus, val: u32);
53    #[doc = "Get the `rcwnNetWonCount` field of this object."]
54    #[doc = ""]
55    #[doc = "*This API requires the following crate features to be activated: `RcwnStatus`*"]
56    #[wasm_bindgen(method, getter = "rcwnNetWonCount")]
57    pub fn get_rcwn_net_won_count(this: &RcwnStatus) -> Option<u32>;
58    #[doc = "Change the `rcwnNetWonCount` field of this object."]
59    #[doc = ""]
60    #[doc = "*This API requires the following crate features to be activated: `RcwnStatus`*"]
61    #[wasm_bindgen(method, setter = "rcwnNetWonCount")]
62    pub fn set_rcwn_net_won_count(this: &RcwnStatus, val: u32);
63    #[doc = "Get the `totalNetworkRequests` field of this object."]
64    #[doc = ""]
65    #[doc = "*This API requires the following crate features to be activated: `RcwnStatus`*"]
66    #[wasm_bindgen(method, getter = "totalNetworkRequests")]
67    pub fn get_total_network_requests(this: &RcwnStatus) -> Option<u32>;
68    #[doc = "Change the `totalNetworkRequests` field of this object."]
69    #[doc = ""]
70    #[doc = "*This API requires the following crate features to be activated: `RcwnStatus`*"]
71    #[wasm_bindgen(method, setter = "totalNetworkRequests")]
72    pub fn set_total_network_requests(this: &RcwnStatus, val: u32);
73}
74impl RcwnStatus {
75    #[doc = "Construct a new `RcwnStatus`."]
76    #[doc = ""]
77    #[doc = "*This API requires the following crate features to be activated: `RcwnStatus`*"]
78    pub fn new() -> Self {
79        #[allow(unused_mut)]
80        let mut ret: Self = ::wasm_bindgen::JsCast::unchecked_into(::js_sys::Object::new());
81        ret
82    }
83    #[deprecated = "Use `set_cache_not_slow_count()` instead."]
84    pub fn cache_not_slow_count(&mut self, val: u32) -> &mut Self {
85        self.set_cache_not_slow_count(val);
86        self
87    }
88    #[deprecated = "Use `set_cache_slow_count()` instead."]
89    pub fn cache_slow_count(&mut self, val: u32) -> &mut Self {
90        self.set_cache_slow_count(val);
91        self
92    }
93    #[deprecated = "Use `set_perf_stats()` instead."]
94    pub fn perf_stats(&mut self, val: &::wasm_bindgen::JsValue) -> &mut Self {
95        self.set_perf_stats(val);
96        self
97    }
98    #[deprecated = "Use `set_rcwn_cache_won_count()` instead."]
99    pub fn rcwn_cache_won_count(&mut self, val: u32) -> &mut Self {
100        self.set_rcwn_cache_won_count(val);
101        self
102    }
103    #[deprecated = "Use `set_rcwn_net_won_count()` instead."]
104    pub fn rcwn_net_won_count(&mut self, val: u32) -> &mut Self {
105        self.set_rcwn_net_won_count(val);
106        self
107    }
108    #[deprecated = "Use `set_total_network_requests()` instead."]
109    pub fn total_network_requests(&mut self, val: u32) -> &mut Self {
110        self.set_total_network_requests(val);
111        self
112    }
113}
114impl Default for RcwnStatus {
115    fn default() -> Self {
116        Self::new()
117    }
118}