pub enum ReferenceError {
MissingRef,
InvalidUid,
NotFound,
Recursive,
Ambiguous,
}Expand description
A failure to either parse or resolve a <Reference> XML element
Enum variants are listed in order of precedence, e.g. if the parser encounters the node
<Reference uid="invalid uid" ref="invalid uid" /> (a recursive reference and an invalid uid)
attempting to resolve the reference will return InvalidUid instead of Recursive
Variants§
MissingRef
The ref attribute is missing, so there isn’t anything to search for
InvalidUid
The ref attribute contains an invalid uid
Valid uids satisfy the regex [_a-zA-Z][_a-zA-Z0-9]*
NotFound
No elements found with the requested uid
Recursive
Reference to a reference
Ambiguous
More than one element was found with the requested uid
Trait Implementations§
Source§impl Clone for ReferenceError
impl Clone for ReferenceError
Source§fn clone(&self) -> ReferenceError
fn clone(&self) -> ReferenceError
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for ReferenceError
impl Debug for ReferenceError
Source§impl Display for ReferenceError
impl Display for ReferenceError
Source§impl Error for ReferenceError
impl Error for ReferenceError
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()
Source§impl PartialEq for ReferenceError
impl PartialEq for ReferenceError
impl Copy for ReferenceError
impl StructuralPartialEq for ReferenceError
Auto Trait Implementations§
impl Freeze for ReferenceError
impl RefUnwindSafe for ReferenceError
impl Send for ReferenceError
impl Sync for ReferenceError
impl Unpin for ReferenceError
impl UnwindSafe for ReferenceError
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