pub struct UnencodableCharacterError { /* private fields */ }
Expand description
The error returned by the encoding functions if they encounter a character they can not encode. Contains a string that references which type of character and which line caused the error.
Implementations
sourceimpl UnencodableCharacterError
impl UnencodableCharacterError
sourcepub fn line_number(&self) -> usize
pub fn line_number(&self) -> usize
Returns the number of the line on which the unencodable character occured.
sourcepub fn unencodable_character_value(&self) -> u8
pub fn unencodable_character_value(&self) -> u8
Returns the byte value of the unencodable character. Note that this might not be the complete representation of the character in unicode, just the first byte of it.
Trait Implementations
sourceimpl Debug for UnencodableCharacterError
impl Debug for UnencodableCharacterError
sourceimpl Display for UnencodableCharacterError
impl Display for UnencodableCharacterError
sourceimpl Error for UnencodableCharacterError
impl Error for UnencodableCharacterError
sourcefn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
The lower-level source of this error, if any. Read more
1.0.0 · sourcefn description(&self) -> &str
fn description(&self) -> &str
👎Deprecated since 1.42.0: use the Display impl or to_string()
Auto Trait Implementations
impl RefUnwindSafe for UnencodableCharacterError
impl Send for UnencodableCharacterError
impl Sync for UnencodableCharacterError
impl Unpin for UnencodableCharacterError
impl UnwindSafe for UnencodableCharacterError
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more