Struct mediasoup::prelude::WeakPlainTransport
source · [−]pub struct WeakPlainTransport { /* private fields */ }
Expand description
WeakPlainTransport
doesn’t own pipe transport instance on mediasoup-worker and will not
prevent one from being destroyed once last instance of regular PlainTransport
is dropped.
WeakPlainTransport
vs PlainTransport
is similar to Weak
vs Arc
.
Implementations
sourceimpl WeakPlainTransport
impl WeakPlainTransport
sourcepub fn upgrade(&self) -> Option<PlainTransport>
pub fn upgrade(&self) -> Option<PlainTransport>
Attempts to upgrade WeakPlainTransport
to PlainTransport
if last instance of one
wasn’t dropped yet.
Trait Implementations
sourceimpl Clone for WeakPlainTransport
impl Clone for WeakPlainTransport
sourcefn clone(&self) -> WeakPlainTransport
fn clone(&self) -> WeakPlainTransport
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source
. Read more
Auto Trait Implementations
impl !RefUnwindSafe for WeakPlainTransport
impl Send for WeakPlainTransport
impl Sync for WeakPlainTransport
impl Unpin for WeakPlainTransport
impl !UnwindSafe for WeakPlainTransport
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<T> ToOwned for T where
T: Clone,
impl<T> ToOwned for T where
T: Clone,
type Owned = T
type Owned = T
The resulting type after obtaining ownership.
sourcefn clone_into(&self, target: &mut T)
fn clone_into(&self, target: &mut T)
🔬 This is a nightly-only experimental API. (
toowned_clone_into
)Uses borrowed data to replace owned data, usually by cloning. Read more