pub enum ViolationKind {
MalformedArguments,
ArgumentsNotObject,
UnknownFunction,
MissingRequired,
WrongType {
expected: String,
actual: String,
},
NotInEnum,
UnexpectedProperty,
}Expand description
The constraint a Violation broke.
Variants§
MalformedArguments
arguments was not parseable JSON.
ArgumentsNotObject
arguments parsed but was not a JSON object.
UnknownFunction
The call named a function absent from the advertised tools.
MissingRequired
A required property was absent.
WrongType
A value’s JSON type did not match the schema’s type.
Fields
NotInEnum
A value was not a member of the schema’s enum.
UnexpectedProperty
A property was present that the schema does not declare, under
additionalProperties: false.
Trait Implementations§
Source§impl Clone for ViolationKind
impl Clone for ViolationKind
Source§fn clone(&self) -> ViolationKind
fn clone(&self) -> ViolationKind
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · 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 ViolationKind
impl Debug for ViolationKind
Source§impl<'de> Deserialize<'de> for ViolationKind
impl<'de> Deserialize<'de> for ViolationKind
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl PartialEq for ViolationKind
impl PartialEq for ViolationKind
Source§fn eq(&self, other: &ViolationKind) -> bool
fn eq(&self, other: &ViolationKind) -> bool
Tests for
self and other values to be equal, and is used by ==.Source§impl Serialize for ViolationKind
impl Serialize for ViolationKind
impl Eq for ViolationKind
impl StructuralPartialEq for ViolationKind
Auto Trait Implementations§
impl Freeze for ViolationKind
impl RefUnwindSafe for ViolationKind
impl Send for ViolationKind
impl Sync for ViolationKind
impl Unpin for ViolationKind
impl UnsafeUnpin for ViolationKind
impl UnwindSafe for ViolationKind
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