Skip to main content

web_sys/features/
gen_GeolocationCoordinates.rs

1#![allow(unused_imports)]
2#![allow(clippy::all)]
3use super::*;
4use wasm_bindgen::prelude::*;
5#[cfg(web_sys_unstable_apis)]
6#[wasm_bindgen]
7extern "C" {
8    #[wasm_bindgen(
9        extends = "::js_sys::Object",
10        js_name = "GeolocationCoordinates",
11        typescript_type = "GeolocationCoordinates"
12    )]
13    #[derive(Debug, Clone, PartialEq, Eq)]
14    #[doc = "The `GeolocationCoordinates` class."]
15    #[doc = ""]
16    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/GeolocationCoordinates)"]
17    #[doc = ""]
18    #[doc = "*This API requires the following crate features to be activated: `GeolocationCoordinates`*"]
19    #[doc = ""]
20    #[doc = "*This API is unstable and requires `--cfg=web_sys_unstable_apis` to be activated, as"]
21    #[doc = "[described in the `wasm-bindgen` guide](https://wasm-bindgen.github.io/wasm-bindgen/web-sys/unstable-apis.html)*"]
22    pub type GeolocationCoordinates;
23    #[cfg(web_sys_unstable_apis)]
24    #[wasm_bindgen(
25        method,
26        getter,
27        js_class = "GeolocationCoordinates",
28        js_name = "accuracy"
29    )]
30    #[doc = "Getter for the `accuracy` field of this object."]
31    #[doc = ""]
32    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/GeolocationCoordinates/accuracy)"]
33    #[doc = ""]
34    #[doc = "*This API requires the following crate features to be activated: `GeolocationCoordinates`*"]
35    #[doc = ""]
36    #[doc = "*This API is unstable and requires `--cfg=web_sys_unstable_apis` to be activated, as"]
37    #[doc = "[described in the `wasm-bindgen` guide](https://wasm-bindgen.github.io/wasm-bindgen/web-sys/unstable-apis.html)*"]
38    pub fn accuracy(this: &GeolocationCoordinates) -> f64;
39    #[cfg(web_sys_unstable_apis)]
40    #[wasm_bindgen(
41        method,
42        getter,
43        js_class = "GeolocationCoordinates",
44        js_name = "latitude"
45    )]
46    #[doc = "Getter for the `latitude` field of this object."]
47    #[doc = ""]
48    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/GeolocationCoordinates/latitude)"]
49    #[doc = ""]
50    #[doc = "*This API requires the following crate features to be activated: `GeolocationCoordinates`*"]
51    #[doc = ""]
52    #[doc = "*This API is unstable and requires `--cfg=web_sys_unstable_apis` to be activated, as"]
53    #[doc = "[described in the `wasm-bindgen` guide](https://wasm-bindgen.github.io/wasm-bindgen/web-sys/unstable-apis.html)*"]
54    pub fn latitude(this: &GeolocationCoordinates) -> f64;
55    #[cfg(web_sys_unstable_apis)]
56    #[wasm_bindgen(
57        method,
58        getter,
59        js_class = "GeolocationCoordinates",
60        js_name = "longitude"
61    )]
62    #[doc = "Getter for the `longitude` field of this object."]
63    #[doc = ""]
64    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/GeolocationCoordinates/longitude)"]
65    #[doc = ""]
66    #[doc = "*This API requires the following crate features to be activated: `GeolocationCoordinates`*"]
67    #[doc = ""]
68    #[doc = "*This API is unstable and requires `--cfg=web_sys_unstable_apis` to be activated, as"]
69    #[doc = "[described in the `wasm-bindgen` guide](https://wasm-bindgen.github.io/wasm-bindgen/web-sys/unstable-apis.html)*"]
70    pub fn longitude(this: &GeolocationCoordinates) -> f64;
71    #[cfg(web_sys_unstable_apis)]
72    #[wasm_bindgen(
73        method,
74        getter,
75        js_class = "GeolocationCoordinates",
76        js_name = "altitude"
77    )]
78    #[doc = "Getter for the `altitude` field of this object."]
79    #[doc = ""]
80    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/GeolocationCoordinates/altitude)"]
81    #[doc = ""]
82    #[doc = "*This API requires the following crate features to be activated: `GeolocationCoordinates`*"]
83    #[doc = ""]
84    #[doc = "*This API is unstable and requires `--cfg=web_sys_unstable_apis` to be activated, as"]
85    #[doc = "[described in the `wasm-bindgen` guide](https://wasm-bindgen.github.io/wasm-bindgen/web-sys/unstable-apis.html)*"]
86    pub fn altitude(this: &GeolocationCoordinates) -> Option<f64>;
87    #[cfg(web_sys_unstable_apis)]
88    #[wasm_bindgen(
89        method,
90        getter,
91        js_class = "GeolocationCoordinates",
92        js_name = "altitudeAccuracy"
93    )]
94    #[doc = "Getter for the `altitudeAccuracy` field of this object."]
95    #[doc = ""]
96    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/GeolocationCoordinates/altitudeAccuracy)"]
97    #[doc = ""]
98    #[doc = "*This API requires the following crate features to be activated: `GeolocationCoordinates`*"]
99    #[doc = ""]
100    #[doc = "*This API is unstable and requires `--cfg=web_sys_unstable_apis` to be activated, as"]
101    #[doc = "[described in the `wasm-bindgen` guide](https://wasm-bindgen.github.io/wasm-bindgen/web-sys/unstable-apis.html)*"]
102    pub fn altitude_accuracy(this: &GeolocationCoordinates) -> Option<f64>;
103    #[cfg(web_sys_unstable_apis)]
104    #[wasm_bindgen(
105        method,
106        getter,
107        js_class = "GeolocationCoordinates",
108        js_name = "heading"
109    )]
110    #[doc = "Getter for the `heading` field of this object."]
111    #[doc = ""]
112    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/GeolocationCoordinates/heading)"]
113    #[doc = ""]
114    #[doc = "*This API requires the following crate features to be activated: `GeolocationCoordinates`*"]
115    #[doc = ""]
116    #[doc = "*This API is unstable and requires `--cfg=web_sys_unstable_apis` to be activated, as"]
117    #[doc = "[described in the `wasm-bindgen` guide](https://wasm-bindgen.github.io/wasm-bindgen/web-sys/unstable-apis.html)*"]
118    pub fn heading(this: &GeolocationCoordinates) -> Option<f64>;
119    #[cfg(web_sys_unstable_apis)]
120    #[wasm_bindgen(method, getter, js_class = "GeolocationCoordinates", js_name = "speed")]
121    #[doc = "Getter for the `speed` field of this object."]
122    #[doc = ""]
123    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/GeolocationCoordinates/speed)"]
124    #[doc = ""]
125    #[doc = "*This API requires the following crate features to be activated: `GeolocationCoordinates`*"]
126    #[doc = ""]
127    #[doc = "*This API is unstable and requires `--cfg=web_sys_unstable_apis` to be activated, as"]
128    #[doc = "[described in the `wasm-bindgen` guide](https://wasm-bindgen.github.io/wasm-bindgen/web-sys/unstable-apis.html)*"]
129    pub fn speed(this: &GeolocationCoordinates) -> Option<f64>;
130}