Struct amq_protocol::frame::WriteContext [−][src]
pub struct WriteContext<W> {
pub write: W,
pub position: u64,
}
Expand description
Context around a Write
impl that is passed through serializing functions
Currently this only keeps track of the current write position since the start of serialization.
Fields
write: W
position: u64
Implementations
Returns the contained Write
and the current position
Trait Implementations
pub fn from(write: W) -> WriteContext<W>ⓘNotable traits for WriteContext<W>impl<W> Write for WriteContext<W> where
W: Write,
pub fn from(write: W) -> WriteContext<W>ⓘNotable traits for WriteContext<W>impl<W> Write for WriteContext<W> where
W: Write,
impl<W> Write for WriteContext<W> where
W: Write,
Performs the conversion.
Write a buffer into this writer, returning how many bytes were written. Read more
Flush this output stream, ensuring that all intermediately buffered contents reach their destination. Read more
can_vector
)Determines if this Write
r has an efficient write_vectored
implementation. Read more
Attempts to write an entire buffer into this writer. Read more
write_all_vectored
)Attempts to write multiple buffers into this writer. Read more
Writes a formatted string into this writer, returning any error encountered. Read more
Auto Trait Implementations
impl<W> RefUnwindSafe for WriteContext<W> where
W: RefUnwindSafe,
impl<W> Send for WriteContext<W> where
W: Send,
impl<W> Sync for WriteContext<W> where
W: Sync,
impl<W> Unpin for WriteContext<W> where
W: Unpin,
impl<W> UnwindSafe for WriteContext<W> where
W: UnwindSafe,
Blanket Implementations
Mutably borrows from an owned value. Read more
Attaches the provided Subscriber
to this type, returning a
WithDispatch
wrapper. Read more
Attaches the current default Subscriber
to this type, returning a
WithDispatch
wrapper. Read more