pub(crate) struct BytesOwned {
    length: Length,
    inner: Box<[u8]>,
}Expand description
Byte slice newtype which respects the Length::max() limit.
Fields§
§length: LengthPrecomputed Length (avoids possible panicking conversions)
inner: Box<[u8]>Inner value
Implementations§
Source§impl BytesOwned
 
impl BytesOwned
Trait Implementations§
Source§impl AsRef<[u8]> for BytesOwned
 
impl AsRef<[u8]> for BytesOwned
Source§impl Clone for BytesOwned
 
impl Clone for BytesOwned
Source§fn clone(&self) -> BytesOwned
 
fn clone(&self) -> BytesOwned
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 BytesOwned
 
impl Debug for BytesOwned
Source§impl<'a> DecodeValue<'a> for BytesOwned
 
impl<'a> DecodeValue<'a> for BytesOwned
Source§impl Default for BytesOwned
 
impl Default for BytesOwned
Source§impl DerOrd for BytesOwned
 
impl DerOrd for BytesOwned
Source§impl EncodeValue for BytesOwned
 
impl EncodeValue for BytesOwned
Source§impl From<BytesRef<'_>> for BytesOwned
 
impl From<BytesRef<'_>> for BytesOwned
Source§fn from(s: BytesRef<'_>) -> BytesOwned
 
fn from(s: BytesRef<'_>) -> BytesOwned
Converts to this type from the input type.
Source§impl From<StrRef<'_>> for BytesOwned
 
impl From<StrRef<'_>> for BytesOwned
Source§fn from(s: StrRef<'_>) -> BytesOwned
 
fn from(s: StrRef<'_>) -> BytesOwned
Converts to this type from the input type.
Source§impl Ord for BytesOwned
 
impl Ord for BytesOwned
Source§fn cmp(&self, other: &BytesOwned) -> Ordering
 
fn cmp(&self, other: &BytesOwned) -> 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 OwnedToRef for BytesOwned
 
impl OwnedToRef for BytesOwned
Source§impl PartialEq for BytesOwned
 
impl PartialEq for BytesOwned
Source§impl PartialOrd for BytesOwned
 
impl PartialOrd for BytesOwned
Source§impl TryFrom<&[u8]> for BytesOwned
 
impl TryFrom<&[u8]> for BytesOwned
impl Eq for BytesOwned
impl StructuralPartialEq for BytesOwned
Auto Trait Implementations§
impl Freeze for BytesOwned
impl RefUnwindSafe for BytesOwned
impl Send for BytesOwned
impl Sync for BytesOwned
impl Unpin for BytesOwned
impl UnwindSafe for BytesOwned
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