Struct servo_media_webrtc::thread::WebRtcController
source · pub struct WebRtcController {
sender: Sender<RtcThreadEvent>,
}
Expand description
Entry point for all client webrtc interactions.
Fields§
§sender: Sender<RtcThreadEvent>
Implementations§
source§impl WebRtcController
impl WebRtcController
pub fn new<T: WebRtcBackend>(signaller: Box<dyn WebRtcSignaller>) -> Self
pub fn configure(&self, stun_server: String, policy: BundlePolicy)
pub fn set_remote_description( &self, desc: SessionDescription, cb: Box<dyn FnOnce() + Send + 'static>, )
pub fn set_local_description( &self, desc: SessionDescription, cb: Box<dyn FnOnce() + Send + 'static>, )
pub fn add_ice_candidate(&self, candidate: IceCandidate)
pub fn create_offer( &self, cb: Box<dyn FnOnce(SessionDescription) + Send + 'static>, )
pub fn create_answer( &self, cb: Box<dyn FnOnce(SessionDescription) + Send + 'static>, )
pub fn add_stream(&self, stream: &MediaStreamId)
pub fn create_data_channel( &self, init: DataChannelInit, ) -> Option<DataChannelId>
pub fn send_data_channel_message( &self, id: &DataChannelId, message: DataChannelMessage, )
pub fn close_data_channel(&self, id: &DataChannelId)
sourcepub fn internal_event(&self, event: InternalEvent)
pub fn internal_event(&self, event: InternalEvent)
This should not be invoked by clients
pub fn quit(&self)
Trait Implementations§
source§impl Clone for WebRtcController
impl Clone for WebRtcController
source§fn clone(&self) -> WebRtcController
fn clone(&self) -> WebRtcController
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreAuto Trait Implementations§
impl Freeze for WebRtcController
impl RefUnwindSafe for WebRtcController
impl Send for WebRtcController
impl Sync for WebRtcController
impl Unpin for WebRtcController
impl UnwindSafe for WebRtcController
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
source§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)