pub enum Direction {
SendRecv,
SendOnly,
RecvOnly,
Inactive,
}Expand description
Which way media flows, from the point of view of the description that carries it.
Variants§
SendRecv
Both ways. The default when no direction attribute is present (RFC 4566 §6).
SendOnly
This side sends only.
RecvOnly
This side receives only.
Inactive
Neither, but the stream stays negotiated.
Implementations§
Source§impl Direction
impl Direction
Sourcepub fn mirrored(self) -> Self
pub fn mirrored(self) -> Self
The direction an answer must carry to match an offer.
This is a mirror, not a copy. An offer of sendonly means “I will send, you will
receive”, so the answer says recvonly. Copying the offer’s direction instead is a
common bug and produces a call where both ends wait for audio.
Trait Implementations§
impl Copy for Direction
impl Eq for Direction
impl StructuralPartialEq for Direction
Auto Trait Implementations§
impl Freeze for Direction
impl RefUnwindSafe for Direction
impl Send for Direction
impl Sync for Direction
impl Unpin for Direction
impl UnsafeUnpin for Direction
impl UnwindSafe for Direction
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