pub struct Invalid {
pub table: &'static str,
pub field: Option<&'static str>,
pub index: Option<u32>,
pub rule: Rule,
}Expand description
A value that breaks a rule of the schema.
table and field name where the rule is declared (field is None for a check on the
whole table). index is the position in the nearest enclosing list: the element that
failed in a list of enums, or the element of a list of tables in which the failing value
sits.
Fields§
§table: &'static str§field: Option<&'static str>§index: Option<u32>§rule: RuleTrait Implementations§
Source§impl Error for Invalid
impl Error for Invalid
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 From<Invalid> for ValidateError
impl From<Invalid> for ValidateError
impl Copy for Invalid
impl Eq for Invalid
impl StructuralPartialEq for Invalid
Auto Trait Implementations§
impl Freeze for Invalid
impl RefUnwindSafe for Invalid
impl Send for Invalid
impl Sync for Invalid
impl Unpin for Invalid
impl UnwindSafe for Invalid
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