Struct schemars::schema::StringValidation [−][src]
pub struct StringValidation {
pub max_length: Option<u32>,
pub min_length: Option<u32>,
pub pattern: Option<String>,
}
Expand description
Properties of a SchemaObject
which define validation assertions for strings.
Fields
max_length: Option<u32>
The maxLength
keyword.
min_length: Option<u32>
The minLength
keyword.
pattern: Option<String>
The pattern
keyword.
Trait Implementations
Returns the “default value” for a type. Read more
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
This method tests for self
and other
values to be equal, and is used
by ==
. Read more
This method tests for !=
.
Auto Trait Implementations
impl RefUnwindSafe for StringValidation
impl Send for StringValidation
impl Sync for StringValidation
impl Unpin for StringValidation
impl UnwindSafe for StringValidation
Blanket Implementations
Mutably borrows from an owned value. Read more