pub enum ParseError {
ShortInput,
Form(FormError),
}
Expand description
An error happened while parsing data.
Variants
ShortInput
An attempt was made to go beyond the end of the parser.
Form(FormError)
A formatting error occurred.
Implementations
sourceimpl ParseError
impl ParseError
sourcepub fn form_error(msg: &'static str) -> Self
pub fn form_error(msg: &'static str) -> Self
Creates a new parse error as a form error with the given message.
Trait Implementations
sourceimpl Clone for ParseError
impl Clone for ParseError
sourcefn clone(&self) -> ParseError
fn clone(&self) -> ParseError
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresourceimpl Debug for ParseError
impl Debug for ParseError
sourceimpl Display for ParseError
impl Display for ParseError
sourceimpl Error for ParseError
impl Error for ParseError
1.30.0 · 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()
sourceimpl From<DnameError> for ParseError
impl From<DnameError> for ParseError
sourcefn from(err: DnameError) -> ParseError
fn from(err: DnameError) -> ParseError
Converts to this type from the input type.
sourceimpl From<FormError> for ParseError
impl From<FormError> for ParseError
sourceimpl From<ParseError> for CopyRecordsError
impl From<ParseError> for CopyRecordsError
sourcefn from(err: ParseError) -> Self
fn from(err: ParseError) -> Self
Converts to this type from the input type.
sourceimpl From<ParseError> for SrvError
Available on crate feature resolv
only.
impl From<ParseError> for SrvError
Available on crate feature
resolv
only.sourcefn from(_: ParseError) -> SrvError
fn from(_: ParseError) -> SrvError
Converts to this type from the input type.
sourceimpl From<ParseError> for ValidationError
Available on crate feature tsig
only.
impl From<ParseError> for ValidationError
Available on crate feature
tsig
only.sourcefn from(_: ParseError) -> Self
fn from(_: ParseError) -> Self
Converts to this type from the input type.
sourceimpl From<RtypeBitmapError> for ParseError
impl From<RtypeBitmapError> for ParseError
sourcefn from(err: RtypeBitmapError) -> ParseError
fn from(err: RtypeBitmapError) -> ParseError
Converts to this type from the input type.
sourceimpl From<SplitLabelError> for ParseError
impl From<SplitLabelError> for ParseError
sourcefn from(err: SplitLabelError) -> ParseError
fn from(err: SplitLabelError) -> ParseError
Converts to this type from the input type.
sourceimpl PartialEq<ParseError> for ParseError
impl PartialEq<ParseError> for ParseError
sourcefn eq(&self, other: &ParseError) -> bool
fn eq(&self, other: &ParseError) -> bool
impl Copy for ParseError
impl Eq for ParseError
impl StructuralEq for ParseError
impl StructuralPartialEq for ParseError
Auto Trait Implementations
impl RefUnwindSafe for ParseError
impl Send for ParseError
impl Sync for ParseError
impl Unpin for ParseError
impl UnwindSafe for ParseError
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
sourceimpl<Source, Target> OctetsInto<Target> for Sourcewhere
Target: OctetsFrom<Source>,
impl<Source, Target> OctetsInto<Target> for Sourcewhere
Target: OctetsFrom<Source>,
sourcefn octets_into(self) -> Result<Target, ShortBuf>
fn octets_into(self) -> Result<Target, ShortBuf>
Performs the conversion.