Struct StreamWriter
pub struct StreamWriter<W: Write> { /* private fields */ }
Wrapper around a [Write] implementation that implements the [Seek] trait, but where seeking returns an error unless it's a no-op.
Implementations
impl<W: Write> StreamWriter<W>
fn new(inner: W) -> StreamWriter<W>Creates an instance wrapping the provided inner writer.
fn get_ref(&self) -> &WGets a reference to the underlying writer.
fn get_mut(&mut self) -> &mut WGets a mutable reference to the underlying writer.
fn into_inner(self) -> WConsumes this wrapper, returning the underlying writer.
Trait Implementations
impl<W: Write> Seek for StreamWriter<W>
fn seek(&mut self, pos: SeekFrom) -> Result<u64>
impl<W: Write> Write for StreamWriter<W>
fn write(&mut self, buf: &[u8]) -> Result<usize>fn flush(&mut self) -> Result<()>
Auto Trait Implementations
impl<W> Freeze for StreamWriter<W>
where
W: Freeze,
impl<W> RefUnwindSafe for StreamWriter<W>
where
W: RefUnwindSafe,
impl<W> Send for StreamWriter<W>
where
W: Send,
impl<W> Sync for StreamWriter<W>
where
W: Sync,
impl<W> Unpin for StreamWriter<W>
where
W: Unpin,
impl<W> UnsafeUnpin for StreamWriter<W>
where
W: UnsafeUnpin,
impl<W> UnwindSafe for StreamWriter<W>
where
W: UnwindSafe,
Blanket Implementations
impl<T> Any for StreamWriter<W>
where
T: 'static + ?Sized,
fn type_id(&self) -> TypeId
impl<T> Borrow<T> for StreamWriter<W>
where
T: ?Sized,
fn borrow(&self) -> &T
impl<T> BorrowMut<T> for StreamWriter<W>
where
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
impl<T> From<T> for StreamWriter<W>
fn from(t: T) -> TReturns the argument unchanged.
impl<T> Same for StreamWriter<W>
type Output = T;
impl<T, U> Into<U> for StreamWriter<W>
where
U: From<T>,
fn into(self) -> UCalls
U::from(self).That is, this conversion is whatever the implementation of
[From]<T> for Uchooses to do.
impl<T, U> TryFrom<U> for StreamWriter<W>
where
U: Into<T>,
type Error = never;fn try_from(value: U) -> Result<T, never>
impl<T, U> TryInto<U> for StreamWriter<W>
where
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error;fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>