pub struct Segments<'d> { /* private fields */ }Expand description
Retained payload ownership preserving transport segmentation.
Implementations§
Source§impl<'d> Segments<'d>
impl<'d> Segments<'d>
pub const fn new() -> Self
pub fn try_push( self, segment: Segment<'d>, ) -> Result<Self, Rejected<(Self, Segment<'d>), Error>>
pub fn try_extend( self, source: Self, ) -> Result<Self, Rejected<(Self, Self), Error>>
pub fn charge(&self) -> Charge
pub fn segment(&self, index: usize) -> Option<&[u8]>
pub fn into_shape(self) -> Shape<Shared<'d>>
pub fn take(self) -> Option<Nonempty<Shared<'d>>>
pub fn try_clone(&self) -> Result<Self, Error>
Trait Implementations§
Source§impl<'d> IntoIterator for Segments<'d>
impl<'d> IntoIterator for Segments<'d>
Auto Trait Implementations§
impl<'d> !RefUnwindSafe for Segments<'d>
impl<'d> !Send for Segments<'d>
impl<'d> !Sync for Segments<'d>
impl<'d> !UnwindSafe for Segments<'d>
impl<'d> Freeze for Segments<'d>
impl<'d> Unpin for Segments<'d>
impl<'d> UnsafeUnpin for Segments<'d>
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