pub struct MessageBuf {
pub bytes: Vec<u8>,
pub handles: Vec<HandleInfo>,
}
Expand description
A message which has been read from a channel.
Fields§
§bytes: Vec<u8>
§handles: Vec<HandleInfo>
Implementations§
Source§impl MessageBuf
impl MessageBuf
Sourcepub fn new() -> Self
pub fn new() -> Self
Create a new MessageBuf
Sourcepub fn ensure_capacity_bytes(&mut self, bytes: usize)
pub fn ensure_capacity_bytes(&mut self, bytes: usize)
Make sure this buffer has room for a certain number of bytes.
Trait Implementations§
Source§impl Debug for MessageBuf
impl Debug for MessageBuf
Source§impl MessageBufFor<FDomainResourceDialect> for MessageBuf
impl MessageBufFor<FDomainResourceDialect> for MessageBuf
Source§fn new() -> MessageBuf
fn new() -> MessageBuf
Create a new message buffer.
Source§fn split_mut(&mut self) -> (&mut Vec<u8>, &mut Vec<HandleInfo>)
fn split_mut(&mut self) -> (&mut Vec<u8>, &mut Vec<HandleInfo>)
Access the contents of this buffer as two vectors.
§fn shrink_bytes_to_fit(&mut self)
fn shrink_bytes_to_fit(&mut self)
Discard any allocated-but-unused space in the byte portion of this buffer.
Auto Trait Implementations§
impl Freeze for MessageBuf
impl RefUnwindSafe for MessageBuf
impl Send for MessageBuf
impl Sync for MessageBuf
impl Unpin for MessageBuf
impl UnwindSafe for MessageBuf
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