pub struct PreludeSchema { /* private fields */ }Expand description
A simple schema implementation for prelude types.
Implementations§
Trait Implementations§
Source§impl Debug for PreludeSchema
impl Debug for PreludeSchema
Source§impl Schema for PreludeSchema
impl Schema for PreludeSchema
Source§fn shape_type(&self) -> ShapeType
fn shape_type(&self) -> ShapeType
Returns the shape type.
Source§fn member_name(&self) -> Option<&str>
fn member_name(&self) -> Option<&str>
Returns the member name if this is a member schema.
Source§fn member_schema(&self, _name: &str) -> Option<&dyn Schema>
fn member_schema(&self, _name: &str) -> Option<&dyn Schema>
Returns the member schema by name (for structures and unions).
Source§fn member_schema_by_index(&self, _index: usize) -> Option<(&str, &dyn Schema)>
fn member_schema_by_index(&self, _index: usize) -> Option<(&str, &dyn Schema)>
Returns the member name and schema by position index (for structures and unions). Read more
Source§fn member(&self) -> Option<&dyn Schema>
fn member(&self) -> Option<&dyn Schema>
Returns the member schema for collections (list member or map value).
Auto Trait Implementations§
impl Freeze for PreludeSchema
impl RefUnwindSafe for PreludeSchema
impl Send for PreludeSchema
impl Sync for PreludeSchema
impl Unpin for PreludeSchema
impl UnwindSafe for PreludeSchema
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
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§impl<T> SchemaExt for T
impl<T> SchemaExt for T
Source§fn is_structure(&self) -> bool
fn is_structure(&self) -> bool
Returns true if this is a structure schema.