Struct il2_iltags::io::array::VecReader [−][src]
pub struct VecReader { /* fields omitted */ }
Expand description
VecReader
implements a Writer
that uses a Vec
It differs from ByteArrayReader
by the fact that it copies the data
into a vector owned by it instead of borrowing the data from a byte array
slice.
Implementations
Creates a new VecReader
with the data copied
from the specified slice.
Returns the current reading position.
Returns:
- The current offset. It is guaranteed to be at most the total size of the data.
Sets the current reading position.
Arguments:
offset
: The new position. It if is larger than the total length, it will assume the total length;
Verifies if the specified number of bytes can be read from this struct.
Returns:
Result(())
: If it is possible to read the specified number of bytes;Result(ErrorKind::UnableToReadData)
: If it is not possible to read the specified number of bytes;
Trait Implementations
Auto Trait Implementations
impl RefUnwindSafe for VecReader
impl UnwindSafe for VecReader