Struct boon::ValidationError
source · pub struct ValidationError<'s, 'v> {
pub schema_url: &'s str,
pub instance_location: InstanceLocation<'v>,
pub kind: ErrorKind<'s, 'v>,
pub causes: Vec<ValidationError<'s, 'v>>,
}
Expand description
Error type for validation failures.
Fields§
§schema_url: &'s str
The absolute, dereferenced schema location.
instance_location: InstanceLocation<'v>
The location of the JSON value within the instance being validated
kind: ErrorKind<'s, 'v>
kind of error
causes: Vec<ValidationError<'s, 'v>>
Holds nested errors
Implementations§
source§impl<'s, 'v> ValidationError<'s, 'v>
impl<'s, 'v> ValidationError<'s, 'v>
sourcepub fn flag_output(&self) -> FlagOutput
pub fn flag_output(&self) -> FlagOutput
The Flag
output format, merely the boolean result.
sourcepub fn basic_output(&self) -> OutputUnit<'_, '_, '_>
pub fn basic_output(&self) -> OutputUnit<'_, '_, '_>
The Basic
structure, a flat list of output units.
sourcepub fn detailed_output(&self) -> OutputUnit<'_, '_, '_>
pub fn detailed_output(&self) -> OutputUnit<'_, '_, '_>
The Detailed
structure, based on the schema.
Trait Implementations§
source§impl<'s, 'v> Debug for ValidationError<'s, 'v>
impl<'s, 'v> Debug for ValidationError<'s, 'v>
source§impl<'s, 'v> Display for ValidationError<'s, 'v>
impl<'s, 'v> Display for ValidationError<'s, 'v>
source§impl<'s, 'v> Error for ValidationError<'s, 'v>
impl<'s, 'v> Error for ValidationError<'s, 'v>
1.30.0 · source§fn 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 · source§fn description(&self) -> &str
fn description(&self) -> &str
👎Deprecated since 1.42.0: use the Display impl or to_string()