pub enum MatchError {
FieldNotFound {
field: String,
type_name: String,
},
TypeMismatch {
field: String,
expected: String,
actual: String,
},
UnsupportedOperator {
operator: String,
context: String,
},
LengthNotSupported {
type_name: String,
},
EmptyFieldPath,
NestedFieldNotFound {
path: Vec<String>,
failed_at: String,
},
}Expand description
Errors that can occur during condition matching
Variants§
FieldNotFound
The specified field was not found on the type
TypeMismatch
Type mismatch between expected and actual values
UnsupportedOperator
The operator is not supported for this type/context
LengthNotSupported
Length check is not supported for this type
EmptyFieldPath
The field path is empty
NestedFieldNotFound
Nested field not found
Trait Implementations§
Source§impl Clone for MatchError
impl Clone for MatchError
Source§fn clone(&self) -> MatchError
fn clone(&self) -> MatchError
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 MatchError
impl Debug for MatchError
Source§impl Display for MatchError
impl Display for MatchError
Source§impl Error for MatchError
impl Error for MatchError
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 MatchError
impl PartialEq for MatchError
impl StructuralPartialEq for MatchError
Auto Trait Implementations§
impl Freeze for MatchError
impl RefUnwindSafe for MatchError
impl Send for MatchError
impl Sync for MatchError
impl Unpin for MatchError
impl UnwindSafe for MatchError
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