pub enum Utf8Error {
Truncated,
UnexpectedContinuation,
InvalidLeadByte,
SurrogateCodepoint,
OverlongEncoding,
CodepointOutOfRange,
InvalidContinuation,
}Expand description
UTF-8-Validation-Errors.
Variants§
Truncated
Truncated multi-byte sequence (Continuation-Byte am Ende fehlt).
UnexpectedContinuation
Continuation-Byte ohne Lead-Byte (10xxxxxx isoliert).
InvalidLeadByte
Lead-Byte ist invalid (z.B. 0xC0, 0xC1, 0xF5-0xFF).
SurrogateCodepoint
Surrogate-Codepoint U+D800..=U+DFFF.
OverlongEncoding
Overlong-Encoding (z.B. 0xC0 0x80 fuer NUL).
CodepointOutOfRange
Codepoint > U+10FFFF.
InvalidContinuation
Continuation-Byte ist nicht 10xxxxxx.
Trait Implementations§
Source§impl Error for Utf8Error
Available on crate feature std only.
impl Error for Utf8Error
Available on crate feature
std only.1.30.0 · Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
Returns the lower-level source of this error, if any. Read more
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
👎Deprecated since 1.42.0:
use the Display impl or to_string()
impl Copy for Utf8Error
impl Eq for Utf8Error
impl StructuralPartialEq for Utf8Error
Auto Trait Implementations§
impl Freeze for Utf8Error
impl RefUnwindSafe for Utf8Error
impl Send for Utf8Error
impl Sync for Utf8Error
impl Unpin for Utf8Error
impl UnsafeUnpin for Utf8Error
impl UnwindSafe for Utf8Error
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