pub enum ScalarSchema {
Text(String),
Number(f64),
Bool(bool),
}Expand description
A text, a number or a boolean, read as text (environment values, sysctl values).
Variants§
Text(String)
A text.
Number(f64)
A number, read as its text.
Bool(bool)
A boolean, read as true or false.
Trait Implementations§
Source§impl JsonSchema for ScalarSchema
impl JsonSchema for ScalarSchema
Source§fn schema_id() -> Cow<'static, str>
fn schema_id() -> Cow<'static, str>
Returns a string that uniquely identifies the schema produced by this type. Read more
Source§fn json_schema(generator: &mut SchemaGenerator) -> Schema
fn json_schema(generator: &mut SchemaGenerator) -> Schema
Generates a JSON Schema for this type. Read more
Source§fn inline_schema() -> bool
fn inline_schema() -> bool
Whether JSON Schemas generated for this type should be included directly in parent schemas,
rather than being re-used where possible using the
$ref keyword. Read moreAuto Trait Implementations§
impl Freeze for ScalarSchema
impl RefUnwindSafe for ScalarSchema
impl Send for ScalarSchema
impl Sync for ScalarSchema
impl Unpin for ScalarSchema
impl UnsafeUnpin for ScalarSchema
impl UnwindSafe for ScalarSchema
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