Struct os_str_bytes::EncodingError [−][src]
pub struct EncodingError(_);
Expand description
The error that occurs when a byte sequence is not representable in the platform encoding.
Result::unwrap
should almost always be called on results containing
this error. It should be known whether or not byte sequences are properly
encoded for the platform, since the module-level documentation
discourages using encoded bytes in interchange. Results are returned
primarily to make panicking behavior explicit.
On Unix, this error is never returned, but OsStrExt
or OsStringExt
should be used instead if that needs to be guaranteed.
Trait Implementations
impl Debug for EncodingError
[src]
impl Debug for EncodingError
[src]impl Display for EncodingError
[src]
impl Display for EncodingError
[src]impl Error for EncodingError
[src]
impl Error for EncodingError
[src]fn source(&self) -> Option<&(dyn Error + 'static)>
1.30.0[src]
fn source(&self) -> Option<&(dyn Error + 'static)>
1.30.0[src]The lower-level source of this error, if any. Read more
fn backtrace(&self) -> Option<&Backtrace>
[src]
fn backtrace(&self) -> Option<&Backtrace>
[src]backtrace
)Returns a stack backtrace, if available, of where this error occurred. Read more
fn description(&self) -> &str
1.0.0[src]
fn description(&self) -> &str
1.0.0[src]use the Display impl or to_string()
impl PartialEq<EncodingError> for EncodingError
[src]
impl PartialEq<EncodingError> for EncodingError
[src]fn eq(&self, other: &EncodingError) -> bool
[src]
fn eq(&self, other: &EncodingError) -> bool
[src]This method tests for self
and other
values to be equal, and is used
by ==
. Read more
fn ne(&self, other: &EncodingError) -> bool
[src]
fn ne(&self, other: &EncodingError) -> bool
[src]This method tests for !=
.
impl Eq for EncodingError
[src]
impl StructuralEq for EncodingError
[src]
impl StructuralPartialEq for EncodingError
[src]
Auto Trait Implementations
impl RefUnwindSafe for EncodingError
impl Send for EncodingError
impl Sync for EncodingError
impl Unpin for EncodingError
impl UnwindSafe for EncodingError
Blanket Implementations
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]pub fn borrow_mut(&mut self) -> &mut T
[src]
pub fn borrow_mut(&mut self) -> &mut T
[src]Mutably borrows from an owned value. Read more