Struct webrtc_sctp::util::serial::Serial [−][src]
pub struct Serial<T: SerialNumber>(pub T);
Implement RFC 1982 "Serial Number Arithmetic"
Methods
impl<T: SerialNumber> Serial<T>[src]
impl<T: SerialNumber> Serial<T>pub fn new(n: T) -> Self[src]
pub fn new(n: T) -> Selfpub fn incr(&mut self)[src]
pub fn incr(&mut self)pub fn decr(&mut self)[src]
pub fn decr(&mut self)pub fn next(&self) -> Serial<T>[src]
pub fn next(&self) -> Serial<T>pub fn previous(&self) -> Serial<T>[src]
pub fn previous(&self) -> Serial<T>Trait Implementations
impl<T: Clone + SerialNumber> Clone for Serial<T>[src]
impl<T: Clone + SerialNumber> Clone for Serial<T>fn clone(&self) -> Serial<T>[src]
fn clone(&self) -> Serial<T>Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)1.0.0[src]
fn clone_from(&mut self, source: &Self)Performs copy-assignment from source. Read more
impl<T: Copy + SerialNumber> Copy for Serial<T>[src]
impl<T: Copy + SerialNumber> Copy for Serial<T>impl From<u32> for Serial<u32>[src]
impl From<u32> for Serial<u32>impl From<Serial<u32>> for u32[src]
impl From<Serial<u32>> for u32impl From<u16> for Serial<u16>[src]
impl From<u16> for Serial<u16>impl From<Serial<u16>> for u16[src]
impl From<Serial<u16>> for u16impl<T: SerialNumber> Ord for Serial<T>[src]
impl<T: SerialNumber> Ord for Serial<T>fn cmp(&self, other: &Self) -> Ordering[src]
fn cmp(&self, other: &Self) -> OrderingThis method returns an Ordering between self and other. Read more
fn max(self, other: Self) -> Self1.21.0[src]
fn max(self, other: Self) -> SelfCompares and returns the maximum of two values. Read more
fn min(self, other: Self) -> Self1.21.0[src]
fn min(self, other: Self) -> SelfCompares and returns the minimum of two values. Read more
impl<T: SerialNumber> PartialOrd for Serial<T>[src]
impl<T: SerialNumber> PartialOrd for Serial<T>fn partial_cmp(&self, other: &Self) -> Option<Ordering>[src]
fn partial_cmp(&self, other: &Self) -> Option<Ordering>This method returns an ordering between self and other values if one exists. Read more
fn lt(&self, other: &Rhs) -> bool1.0.0[src]
fn lt(&self, other: &Rhs) -> boolThis method tests less than (for self and other) and is used by the < operator. Read more
fn le(&self, other: &Rhs) -> bool1.0.0[src]
fn le(&self, other: &Rhs) -> boolThis method tests less than or equal to (for self and other) and is used by the <= operator. Read more
fn gt(&self, other: &Rhs) -> bool1.0.0[src]
fn gt(&self, other: &Rhs) -> boolThis method tests greater than (for self and other) and is used by the > operator. Read more
fn ge(&self, other: &Rhs) -> bool1.0.0[src]
fn ge(&self, other: &Rhs) -> boolThis method tests greater than or equal to (for self and other) and is used by the >= operator. Read more
impl<T: SerialNumber> PartialEq for Serial<T>[src]
impl<T: SerialNumber> PartialEq for Serial<T>fn eq(&self, other: &Self) -> bool[src]
fn eq(&self, other: &Self) -> boolThis method tests for self and other values to be equal, and is used by ==. Read more
fn ne(&self, other: &Rhs) -> bool1.0.0[src]
fn ne(&self, other: &Rhs) -> boolThis method tests for !=.
impl<T: SerialNumber> Eq for Serial<T>[src]
impl<T: SerialNumber> Eq for Serial<T>impl<T: SerialNumber> Hash for Serial<T>[src]
impl<T: SerialNumber> Hash for Serial<T>fn hash<H: Hasher>(&self, state: &mut H)[src]
fn hash<H: Hasher>(&self, state: &mut H)Feeds this value into the given [Hasher]. Read more
fn hash_slice<H>(data: &[Self], state: &mut H) where
H: Hasher, 1.3.0[src]
fn hash_slice<H>(data: &[Self], state: &mut H) where
H: Hasher, Feeds a slice of this type into the given [Hasher]. Read more
impl<T: SerialNumber> Add for Serial<T>[src]
impl<T: SerialNumber> Add for Serial<T>type Output = Serial<T>
The resulting type after applying the + operator.
fn add(self, other: Serial<T>) -> Serial<T>[src]
fn add(self, other: Serial<T>) -> Serial<T>Performs the + operation.
impl<T: SerialNumber> Add<T> for Serial<T>[src]
impl<T: SerialNumber> Add<T> for Serial<T>type Output = Serial<T>
The resulting type after applying the + operator.
fn add(self, other: T) -> Serial<T>[src]
fn add(self, other: T) -> Serial<T>Performs the + operation.
impl<T: SerialNumber> Sub for Serial<T>[src]
impl<T: SerialNumber> Sub for Serial<T>type Output = Serial<T>
The resulting type after applying the - operator.
fn sub(self, other: Serial<T>) -> Serial<T>[src]
fn sub(self, other: Serial<T>) -> Serial<T>Performs the - operation.
impl<T: SerialNumber> Sub<T> for Serial<T>[src]
impl<T: SerialNumber> Sub<T> for Serial<T>type Output = Serial<T>
The resulting type after applying the - operator.
fn sub(self, other: T) -> Serial<T>[src]
fn sub(self, other: T) -> Serial<T>Performs the - operation.
impl<T: SerialNumber> AddAssign<T> for Serial<T>[src]
impl<T: SerialNumber> AddAssign<T> for Serial<T>fn add_assign(&mut self, other: T)[src]
fn add_assign(&mut self, other: T)Performs the += operation.
impl<T: SerialNumber> SubAssign<T> for Serial<T>[src]
impl<T: SerialNumber> SubAssign<T> for Serial<T>fn sub_assign(&mut self, other: T)[src]
fn sub_assign(&mut self, other: T)Performs the -= operation.
impl<T: SerialNumber> Display for Serial<T>[src]
impl<T: SerialNumber> Display for Serial<T>fn fmt(&self, f: &mut Formatter) -> Result[src]
fn fmt(&self, f: &mut Formatter) -> ResultFormats the value using the given formatter. Read more
impl<T: SerialNumber> Debug for Serial<T>[src]
impl<T: SerialNumber> Debug for Serial<T>fn fmt(&self, f: &mut Formatter) -> Result[src]
fn fmt(&self, f: &mut Formatter) -> ResultFormats the value using the given formatter. Read more
impl<T: SerialNumber> LowerHex for Serial<T>[src]
impl<T: SerialNumber> LowerHex for Serial<T>impl<T: SerialNumber> UpperHex for Serial<T>[src]
impl<T: SerialNumber> UpperHex for Serial<T>