Struct utf8_chars::ReadCharError [−][src]
A structure, containing read bytes, and an io::Error
.
The io::Error
is an actual I/O error if some occurred,
or a synthetic error with either the UnexpectedEof
kind if a multi-byte char was unexpectedly terminated,
either the InvalidData
kind if no actual I/O error occurred, but read byte sequence was not recognised as a valid UTF-8.
Implementations
impl ReadCharError
[src]
pub fn as_bytes(&self) -> &[u8]
[src]
A byte sequence, representing an invalid or incomplete UTF-8-encoded char.
pub fn as_io_error(&self) -> &Error
[src]
Returns a reference to the I/O error.
pub fn into_io_error(self) -> Error
[src]
Consumes the ReadCharError
, returning the I/O error.
Trait Implementations
impl Debug for ReadCharError
[src]
impl Display for ReadCharError
[src]
impl Error for ReadCharError
[src]
Auto Trait Implementations
impl !RefUnwindSafe for ReadCharError
impl Send for ReadCharError
impl Sync for ReadCharError
impl Unpin for ReadCharError
impl !UnwindSafe for ReadCharError
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> ToString for T where
T: Display + ?Sized,
[src]
T: Display + ?Sized,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,