#[non_exhaustive]pub enum Rule {
}Expand description
A validation keyword of the schema, with the limit it sets. A number limit is an f64, so an integer limit
beyond 2^53 shows rounded (the check itself compares integers exactly).
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
MinLength(u64)
minLength: the least number of characters.
MaxLength(u64)
maxLength: the greatest number of characters.
Pattern(&'static str)
pattern: a regular expression the string must contain a match of.
Minimum(f64)
minimum
ExclusiveMinimum(f64)
exclusiveMinimum
Maximum(f64)
maximum
ExclusiveMaximum(f64)
exclusiveMaximum
MultipleOf(f64)
multipleOf
MinItems(u64)
minItems
MaxItems(u64)
maxItems
UniqueItems
uniqueItems: no two items are equal.
MinProperties(u64)
minProperties of a map.
MaxProperties(u64)
maxProperties of a map.
Trait Implementations§
impl StructuralPartialEq for Rule
Auto Trait Implementations§
impl Forget for Rule
impl Freeze for Rule
impl Move for Rule
impl RefUnwindSafe for Rule
impl Send for Rule
impl Sync for Rule
impl Unpin for Rule
impl UnsafeUnpin for Rule
impl UnwindSafe for Rule
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