web_sys/features/
gen_RtcRtpTransceiver.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 = RTCRtpTransceiver , typescript_type = "RTCRtpTransceiver")]
8    #[derive(Debug, Clone, PartialEq, Eq)]
9    #[doc = "The `RtcRtpTransceiver` class."]
10    #[doc = ""]
11    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/RTCRtpTransceiver)"]
12    #[doc = ""]
13    #[doc = "*This API requires the following crate features to be activated: `RtcRtpTransceiver`*"]
14    pub type RtcRtpTransceiver;
15    # [wasm_bindgen (structural , method , getter , js_class = "RTCRtpTransceiver" , js_name = mid)]
16    #[doc = "Getter for the `mid` field of this object."]
17    #[doc = ""]
18    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/RTCRtpTransceiver/mid)"]
19    #[doc = ""]
20    #[doc = "*This API requires the following crate features to be activated: `RtcRtpTransceiver`*"]
21    pub fn mid(this: &RtcRtpTransceiver) -> Option<::alloc::string::String>;
22    #[cfg(feature = "RtcRtpSender")]
23    # [wasm_bindgen (structural , method , getter , js_class = "RTCRtpTransceiver" , js_name = sender)]
24    #[doc = "Getter for the `sender` field of this object."]
25    #[doc = ""]
26    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/RTCRtpTransceiver/sender)"]
27    #[doc = ""]
28    #[doc = "*This API requires the following crate features to be activated: `RtcRtpSender`, `RtcRtpTransceiver`*"]
29    pub fn sender(this: &RtcRtpTransceiver) -> RtcRtpSender;
30    #[cfg(feature = "RtcRtpReceiver")]
31    # [wasm_bindgen (structural , method , getter , js_class = "RTCRtpTransceiver" , js_name = receiver)]
32    #[doc = "Getter for the `receiver` field of this object."]
33    #[doc = ""]
34    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/RTCRtpTransceiver/receiver)"]
35    #[doc = ""]
36    #[doc = "*This API requires the following crate features to be activated: `RtcRtpReceiver`, `RtcRtpTransceiver`*"]
37    pub fn receiver(this: &RtcRtpTransceiver) -> RtcRtpReceiver;
38    # [wasm_bindgen (structural , method , getter , js_class = "RTCRtpTransceiver" , js_name = stopped)]
39    #[doc = "Getter for the `stopped` field of this object."]
40    #[doc = ""]
41    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/RTCRtpTransceiver/stopped)"]
42    #[doc = ""]
43    #[doc = "*This API requires the following crate features to be activated: `RtcRtpTransceiver`*"]
44    pub fn stopped(this: &RtcRtpTransceiver) -> bool;
45    #[cfg(feature = "RtcRtpTransceiverDirection")]
46    # [wasm_bindgen (structural , method , getter , js_class = "RTCRtpTransceiver" , js_name = direction)]
47    #[doc = "Getter for the `direction` field of this object."]
48    #[doc = ""]
49    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/RTCRtpTransceiver/direction)"]
50    #[doc = ""]
51    #[doc = "*This API requires the following crate features to be activated: `RtcRtpTransceiver`, `RtcRtpTransceiverDirection`*"]
52    pub fn direction(this: &RtcRtpTransceiver) -> RtcRtpTransceiverDirection;
53    #[cfg(feature = "RtcRtpTransceiverDirection")]
54    # [wasm_bindgen (structural , method , setter , js_class = "RTCRtpTransceiver" , js_name = direction)]
55    #[doc = "Setter for the `direction` field of this object."]
56    #[doc = ""]
57    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/RTCRtpTransceiver/direction)"]
58    #[doc = ""]
59    #[doc = "*This API requires the following crate features to be activated: `RtcRtpTransceiver`, `RtcRtpTransceiverDirection`*"]
60    pub fn set_direction(this: &RtcRtpTransceiver, value: RtcRtpTransceiverDirection);
61    #[cfg(feature = "RtcRtpTransceiverDirection")]
62    # [wasm_bindgen (structural , method , getter , js_class = "RTCRtpTransceiver" , js_name = currentDirection)]
63    #[doc = "Getter for the `currentDirection` field of this object."]
64    #[doc = ""]
65    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/RTCRtpTransceiver/currentDirection)"]
66    #[doc = ""]
67    #[doc = "*This API requires the following crate features to be activated: `RtcRtpTransceiver`, `RtcRtpTransceiverDirection`*"]
68    pub fn current_direction(this: &RtcRtpTransceiver) -> Option<RtcRtpTransceiverDirection>;
69    # [wasm_bindgen (method , structural , js_class = "RTCRtpTransceiver" , js_name = getRemoteTrackId)]
70    #[doc = "The `getRemoteTrackId()` method."]
71    #[doc = ""]
72    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/RTCRtpTransceiver/getRemoteTrackId)"]
73    #[doc = ""]
74    #[doc = "*This API requires the following crate features to be activated: `RtcRtpTransceiver`*"]
75    pub fn get_remote_track_id(this: &RtcRtpTransceiver) -> ::alloc::string::String;
76    # [wasm_bindgen (method , structural , js_class = "RTCRtpTransceiver" , js_name = setCodecPreferences)]
77    #[doc = "The `setCodecPreferences()` method."]
78    #[doc = ""]
79    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/RTCRtpTransceiver/setCodecPreferences)"]
80    #[doc = ""]
81    #[doc = "*This API requires the following crate features to be activated: `RtcRtpTransceiver`*"]
82    pub fn set_codec_preferences(this: &RtcRtpTransceiver, codecs: &::wasm_bindgen::JsValue);
83    # [wasm_bindgen (method , structural , js_class = "RTCRtpTransceiver" , js_name = stop)]
84    #[doc = "The `stop()` method."]
85    #[doc = ""]
86    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/RTCRtpTransceiver/stop)"]
87    #[doc = ""]
88    #[doc = "*This API requires the following crate features to be activated: `RtcRtpTransceiver`*"]
89    pub fn stop(this: &RtcRtpTransceiver);
90}