pub struct PayloadType(u8);Expand description
7-bit RTP payload type value usable in RTP/RTCP muxed sessions
Tuple Fields§
§0: u8Implementations§
Source§impl PayloadType
impl PayloadType
pub const fn try_new(value: u8) -> Option<PayloadType>
Sourcepub const fn new(value: u8) -> PayloadType
pub const fn new(value: u8) -> PayloadType
builds a payload type for the muxed RTP sessions used by o-sfu
§Panics
panics when value does not fit the RTP payload type field or is in the
RTP/RTCP mux forbidden range from RFC 5761 section 4
pub const fn value(self) -> u8
Trait Implementations§
Source§impl Clone for PayloadType
impl Clone for PayloadType
Source§fn clone(&self) -> PayloadType
fn clone(&self) -> PayloadType
Returns a duplicate 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 moreSource§impl Debug for PayloadType
impl Debug for PayloadType
Source§impl Hash for PayloadType
impl Hash for PayloadType
Source§impl Ord for PayloadType
impl Ord for PayloadType
Source§fn cmp(&self, other: &PayloadType) -> Ordering
fn cmp(&self, other: &PayloadType) -> Ordering
1.21.0 · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
Source§impl PartialEq for PayloadType
impl PartialEq for PayloadType
Source§impl PartialOrd for PayloadType
impl PartialOrd for PayloadType
Source§impl TryFrom<u8> for PayloadType
impl TryFrom<u8> for PayloadType
Source§type Error = InvalidPayloadType
type Error = InvalidPayloadType
The type returned in the event of a conversion error.
Source§fn try_from(
value: u8,
) -> Result<PayloadType, <PayloadType as TryFrom<u8>>::Error>
fn try_from( value: u8, ) -> Result<PayloadType, <PayloadType as TryFrom<u8>>::Error>
Performs the conversion.
impl Copy for PayloadType
impl Eq for PayloadType
impl StructuralPartialEq for PayloadType
Auto Trait Implementations§
impl Freeze for PayloadType
impl RefUnwindSafe for PayloadType
impl Send for PayloadType
impl Sync for PayloadType
impl Unpin for PayloadType
impl UnsafeUnpin for PayloadType
impl UnwindSafe for PayloadType
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