1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
use js_sys::JsString;
use wasm_bindgen::prelude::*;

#[wasm_bindgen]
extern {
    #[derive(Clone, Debug, PartialEq)]
    pub type Cookie;

    #[wasm_bindgen(method, getter)]
    pub fn domain(this: &Cookie) -> Option<JsString>;

    #[wasm_bindgen(method, setter)]
    pub fn set_domain(this: &Cookie, value: Option<JsString>);

    #[wasm_bindgen(method, getter, js_name = "expirationDate")]
    pub fn expiration_date(this: &Cookie) -> Option<JsString>;

    #[wasm_bindgen(method, setter, js_name = "expirationDate")]
    pub fn set_expiration_date(this: &Cookie, value: Option<JsString>);

    #[wasm_bindgen(method, getter, js_name = "hostOnly")]
    pub fn host_only(this: &Cookie) -> Option<JsString>;

    #[wasm_bindgen(method, setter, js_name = "hostOnly")]
    pub fn set_host_only(this: &Cookie, value: Option<JsString>);

    #[wasm_bindgen(method, getter, js_name = "httpOnly")]
    pub fn http_only(this: &Cookie) -> Option<JsString>;

    #[wasm_bindgen(method, setter, js_name = "httpOnly")]
    pub fn set_http_only(this: &Cookie, value: Option<JsString>);

    #[wasm_bindgen(method, getter)]
    pub fn name(this: &Cookie) -> JsString;

    #[wasm_bindgen(method, setter)]
    pub fn set_name(this: &Cookie, value: JsString);

    #[wasm_bindgen(method, getter)]
    pub fn path(this: &Cookie) -> Option<JsString>;

    #[wasm_bindgen(method, setter)]
    pub fn set_path(this: &Cookie, value: Option<JsString>);

    #[wasm_bindgen(method, getter)]
    pub fn secure(this: &Cookie) -> Option<JsString>;

    #[wasm_bindgen(method, setter)]
    pub fn set_secure(this: &Cookie, value: Option<JsString>);

    #[wasm_bindgen(method, getter)]
    pub fn session(this: &Cookie) -> Option<JsString>;

    #[wasm_bindgen(method, setter)]
    pub fn set_session(this: &Cookie, value: Option<JsString>);

    #[wasm_bindgen(method, getter)]
    pub fn value(this: &Cookie) -> JsString;

    #[wasm_bindgen(method, setter)]
    pub fn set_value(this: &Cookie, value: JsString);
}