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
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
#![allow(unused_imports)]
#![allow(clippy::all)]
use super::*;
use wasm_bindgen::prelude::*;
#[wasm_bindgen]
extern "C" {
    # [wasm_bindgen (extends = EventTarget , extends = :: js_sys :: Object , js_name = MediaStream , typescript_type = "MediaStream")]
    #[derive(Debug, Clone, PartialEq, Eq)]
    #[doc = "The `MediaStream` class."]
    #[doc = ""]
    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/MediaStream)"]
    #[doc = ""]
    #[doc = "*This API requires the following crate features to be activated: `MediaStream`*"]
    pub type MediaStream;
    # [wasm_bindgen (structural , method , getter , js_class = "MediaStream" , js_name = id)]
    #[doc = "Getter for the `id` field of this object."]
    #[doc = ""]
    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/MediaStream/id)"]
    #[doc = ""]
    #[doc = "*This API requires the following crate features to be activated: `MediaStream`*"]
    pub fn id(this: &MediaStream) -> String;
    # [wasm_bindgen (structural , method , getter , js_class = "MediaStream" , js_name = active)]
    #[doc = "Getter for the `active` field of this object."]
    #[doc = ""]
    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/MediaStream/active)"]
    #[doc = ""]
    #[doc = "*This API requires the following crate features to be activated: `MediaStream`*"]
    pub fn active(this: &MediaStream) -> bool;
    # [wasm_bindgen (structural , method , getter , js_class = "MediaStream" , js_name = onaddtrack)]
    #[doc = "Getter for the `onaddtrack` field of this object."]
    #[doc = ""]
    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/MediaStream/onaddtrack)"]
    #[doc = ""]
    #[doc = "*This API requires the following crate features to be activated: `MediaStream`*"]
    pub fn onaddtrack(this: &MediaStream) -> Option<::js_sys::Function>;
    # [wasm_bindgen (structural , method , setter , js_class = "MediaStream" , js_name = onaddtrack)]
    #[doc = "Setter for the `onaddtrack` field of this object."]
    #[doc = ""]
    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/MediaStream/onaddtrack)"]
    #[doc = ""]
    #[doc = "*This API requires the following crate features to be activated: `MediaStream`*"]
    pub fn set_onaddtrack(this: &MediaStream, value: Option<&::js_sys::Function>);
    # [wasm_bindgen (structural , method , getter , js_class = "MediaStream" , js_name = onremovetrack)]
    #[doc = "Getter for the `onremovetrack` field of this object."]
    #[doc = ""]
    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/MediaStream/onremovetrack)"]
    #[doc = ""]
    #[doc = "*This API requires the following crate features to be activated: `MediaStream`*"]
    pub fn onremovetrack(this: &MediaStream) -> Option<::js_sys::Function>;
    # [wasm_bindgen (structural , method , setter , js_class = "MediaStream" , js_name = onremovetrack)]
    #[doc = "Setter for the `onremovetrack` field of this object."]
    #[doc = ""]
    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/MediaStream/onremovetrack)"]
    #[doc = ""]
    #[doc = "*This API requires the following crate features to be activated: `MediaStream`*"]
    pub fn set_onremovetrack(this: &MediaStream, value: Option<&::js_sys::Function>);
    # [wasm_bindgen (structural , method , getter , js_class = "MediaStream" , js_name = currentTime)]
    #[doc = "Getter for the `currentTime` field of this object."]
    #[doc = ""]
    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/MediaStream/currentTime)"]
    #[doc = ""]
    #[doc = "*This API requires the following crate features to be activated: `MediaStream`*"]
    pub fn current_time(this: &MediaStream) -> f64;
    #[wasm_bindgen(catch, constructor, js_class = "MediaStream")]
    #[doc = "The `new MediaStream(..)` constructor, creating a new instance of `MediaStream`."]
    #[doc = ""]
    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/MediaStream/MediaStream)"]
    #[doc = ""]
    #[doc = "*This API requires the following crate features to be activated: `MediaStream`*"]
    pub fn new() -> Result<MediaStream, JsValue>;
    #[wasm_bindgen(catch, constructor, js_class = "MediaStream")]
    #[doc = "The `new MediaStream(..)` constructor, creating a new instance of `MediaStream`."]
    #[doc = ""]
    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/MediaStream/MediaStream)"]
    #[doc = ""]
    #[doc = "*This API requires the following crate features to be activated: `MediaStream`*"]
    pub fn new_with_stream(stream: &MediaStream) -> Result<MediaStream, JsValue>;
    #[wasm_bindgen(catch, constructor, js_class = "MediaStream")]
    #[doc = "The `new MediaStream(..)` constructor, creating a new instance of `MediaStream`."]
    #[doc = ""]
    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/MediaStream/MediaStream)"]
    #[doc = ""]
    #[doc = "*This API requires the following crate features to be activated: `MediaStream`*"]
    pub fn new_with_tracks(tracks: &::wasm_bindgen::JsValue) -> Result<MediaStream, JsValue>;
    #[cfg(feature = "MediaStreamTrack")]
    # [wasm_bindgen (method , structural , js_class = "MediaStream" , js_name = addTrack)]
    #[doc = "The `addTrack()` method."]
    #[doc = ""]
    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/MediaStream/addTrack)"]
    #[doc = ""]
    #[doc = "*This API requires the following crate features to be activated: `MediaStream`, `MediaStreamTrack`*"]
    pub fn add_track(this: &MediaStream, track: &MediaStreamTrack);
    # [wasm_bindgen (method , structural , js_class = "MediaStream" , js_name = clone)]
    #[doc = "The `clone()` method."]
    #[doc = ""]
    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/MediaStream/clone)"]
    #[doc = ""]
    #[doc = "*This API requires the following crate features to be activated: `MediaStream`*"]
    pub fn clone(this: &MediaStream) -> MediaStream;
    # [wasm_bindgen (method , structural , js_class = "MediaStream" , js_name = getAudioTracks)]
    #[doc = "The `getAudioTracks()` method."]
    #[doc = ""]
    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/MediaStream/getAudioTracks)"]
    #[doc = ""]
    #[doc = "*This API requires the following crate features to be activated: `MediaStream`*"]
    pub fn get_audio_tracks(this: &MediaStream) -> ::js_sys::Array;
    #[cfg(feature = "MediaStreamTrack")]
    # [wasm_bindgen (method , structural , js_class = "MediaStream" , js_name = getTrackById)]
    #[doc = "The `getTrackById()` method."]
    #[doc = ""]
    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/MediaStream/getTrackById)"]
    #[doc = ""]
    #[doc = "*This API requires the following crate features to be activated: `MediaStream`, `MediaStreamTrack`*"]
    pub fn get_track_by_id(this: &MediaStream, track_id: &str) -> Option<MediaStreamTrack>;
    # [wasm_bindgen (method , structural , js_class = "MediaStream" , js_name = getTracks)]
    #[doc = "The `getTracks()` method."]
    #[doc = ""]
    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/MediaStream/getTracks)"]
    #[doc = ""]
    #[doc = "*This API requires the following crate features to be activated: `MediaStream`*"]
    pub fn get_tracks(this: &MediaStream) -> ::js_sys::Array;
    # [wasm_bindgen (method , structural , js_class = "MediaStream" , js_name = getVideoTracks)]
    #[doc = "The `getVideoTracks()` method."]
    #[doc = ""]
    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/MediaStream/getVideoTracks)"]
    #[doc = ""]
    #[doc = "*This API requires the following crate features to be activated: `MediaStream`*"]
    pub fn get_video_tracks(this: &MediaStream) -> ::js_sys::Array;
    #[cfg(feature = "MediaStreamTrack")]
    # [wasm_bindgen (method , structural , js_class = "MediaStream" , js_name = removeTrack)]
    #[doc = "The `removeTrack()` method."]
    #[doc = ""]
    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/MediaStream/removeTrack)"]
    #[doc = ""]
    #[doc = "*This API requires the following crate features to be activated: `MediaStream`, `MediaStreamTrack`*"]
    pub fn remove_track(this: &MediaStream, track: &MediaStreamTrack);
}