pub struct Schema {
pub ref_path: Option<String>,
pub description: Option<String>,
pub schema_type: Option<String>,
pub format: Option<String>,
pub enum_values: Option<Vec<String>>,
pub required: Option<Vec<String>>,
pub items: Option<Box<Schema>>,
pub properties: Option<BTreeMap<String, Schema>>,
}
Expand description
A JSON schema definition describing the shape and properties of an object.
This may also contain a $ref
to another definition
Fields§
§ref_path: Option<String>
a JSON reference path to another defintion
description: Option<String>
§schema_type: Option<String>
§format: Option<String>
§enum_values: Option<Vec<String>>
§required: Option<Vec<String>>
§items: Option<Box<Schema>>
§properties: Option<BTreeMap<String, Schema>>
Trait Implementations§
Source§impl<'de> Deserialize<'de> for Schema
impl<'de> Deserialize<'de> for Schema
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
impl StructuralPartialEq for Schema
Auto Trait Implementations§
impl Freeze for Schema
impl RefUnwindSafe for Schema
impl Send for Schema
impl Sync for Schema
impl Unpin for Schema
impl UnwindSafe for Schema
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