Struct dsi_bitstream::impls::WordAdapter
source · pub struct WordAdapter<W: UnsignedInt, B> { /* private fields */ }
Expand description
An adapter from Read
, Write
, and Seek
,
to WordRead
, WordWrite
, and WordSeek
, respectively.
Instances of this struct can be created using WordAdapter::new
. They
turn every standard (possibly seekable) source or destination of
bytes (such as std::fs::File
, std::io::BufReader
, sockets, etc.)
into a source or destination of words.
Implementations§
source§impl<W: UnsignedInt, B> WordAdapter<W, B>
impl<W: UnsignedInt, B> WordAdapter<W, B>
Trait Implementations§
source§impl<W: Clone + UnsignedInt, B: Clone> Clone for WordAdapter<W, B>
impl<W: Clone + UnsignedInt, B: Clone> Clone for WordAdapter<W, B>
source§fn clone(&self) -> WordAdapter<W, B>
fn clone(&self) -> WordAdapter<W, B>
Returns a copy 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<W: UnsignedInt, B: Read> WordRead for WordAdapter<W, B>
impl<W: UnsignedInt, B: Read> WordRead for WordAdapter<W, B>
source§impl<W: UnsignedInt, B: Seek> WordSeek for WordAdapter<W, B>
impl<W: UnsignedInt, B: Seek> WordSeek for WordAdapter<W, B>
source§impl<W: UnsignedInt, B: Write> WordWrite for WordAdapter<W, B>
impl<W: UnsignedInt, B: Write> WordWrite for WordAdapter<W, B>
Auto Trait Implementations§
impl<W, B> RefUnwindSafe for WordAdapter<W, B>where
B: RefUnwindSafe,
W: RefUnwindSafe,
impl<W, B> Send for WordAdapter<W, B>where
B: Send,
impl<W, B> Sync for WordAdapter<W, B>where
B: Sync,
impl<W, B> Unpin for WordAdapter<W, B>
impl<W, B> UnwindSafe for WordAdapter<W, B>where
B: UnwindSafe,
W: UnwindSafe,
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
source§impl<T, U> CastableInto<U> for Twhere
U: CastableFrom<T>,
impl<T, U> CastableInto<U> for Twhere
U: CastableFrom<T>,
source§impl<T> DowncastableFrom<T> for T
impl<T> DowncastableFrom<T> for T
source§fn downcast_from(value: T) -> T
fn downcast_from(value: T) -> T
Truncate the current UnsignedInt to a possibly smaller size
source§impl<T, U> DowncastableInto<U> for Twhere
U: DowncastableFrom<T>,
impl<T, U> DowncastableInto<U> for Twhere
U: DowncastableFrom<T>,
source§impl<T> UpcastableFrom<T> for T
impl<T> UpcastableFrom<T> for T
source§fn upcast_from(value: T) -> T
fn upcast_from(value: T) -> T
Extend the current UnsignedInt to a possibly bigger size.