pub struct PeerConnectionBuilder<P: Platform> { /* private fields */ }
Expand description
Builder for WebRTC Peer Connections
Implementations§
Source§impl PeerConnectionBuilder<Native>
impl PeerConnectionBuilder<Native>
Sourcepub async fn build(&self) -> Result<PeerConnection, Error>
pub async fn build(&self) -> Result<PeerConnection, Error>
Build new Native JustWebRTC Peer Connection
Source§impl<P: Platform> PeerConnectionBuilder<P>
impl<P: Platform> PeerConnectionBuilder<P>
Sourcepub fn new() -> Self
pub fn new() -> Self
Create new PeerConnectionBuilder (equivalent to PeerConnectionBuilder::default())
Sourcepub fn set_config(self, set: PeerConfiguration) -> Self
pub fn set_config(self, set: PeerConfiguration) -> Self
Specify internal WebRTC peer configuration settings
Sourcepub fn set_outgoing_buffer(self, set: usize) -> Self
pub fn set_outgoing_buffer(self, set: usize) -> Self
Specify outgoing data channel buffer size
Sourcepub fn with_remote_offer(
self,
set: Option<SessionDescription>,
) -> Result<Self, PeerConnectionBuilderError>
pub fn with_remote_offer( self, set: Option<SessionDescription>, ) -> Result<Self, PeerConnectionBuilderError>
Provide an Offer as created by a remote peer
This option is mutually exclusive with the with_channel_
settings.
Sourcepub fn with_channel_options(
self,
set: Vec<(String, DataChannelOptions)>,
) -> Result<Self, PeerConnectionBuilderError>
pub fn with_channel_options( self, set: Vec<(String, DataChannelOptions)>, ) -> Result<Self, PeerConnectionBuilderError>
Provide options for initial data channel creation (as an offerer)
This option is mutually exclusive with with_remote_offer
.
Trait Implementations§
Auto Trait Implementations§
impl<P> Freeze for PeerConnectionBuilder<P>
impl<P> RefUnwindSafe for PeerConnectionBuilder<P>where
P: RefUnwindSafe,
impl<P> Send for PeerConnectionBuilder<P>where
P: Send,
impl<P> Sync for PeerConnectionBuilder<P>where
P: Sync,
impl<P> Unpin for PeerConnectionBuilder<P>where
P: Unpin,
impl<P> UnwindSafe for PeerConnectionBuilder<P>where
P: UnwindSafe,
Blanket Implementations§
Source§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
Source§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
Source§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
Source§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
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