poem_openapi::types

Trait Type

Source
pub trait Type: Send + Sync {
    type RawValueType;
    type RawElementValueType;

    const IS_REQUIRED: bool;

    // Required methods
    fn name() -> Cow<'static, str>;
    fn schema_ref() -> MetaSchemaRef;
    fn as_raw_value(&self) -> Option<&Self::RawValueType>;
    fn raw_element_iter<'a>(
        &'a self,
    ) -> Box<dyn Iterator<Item = &'a Self::RawElementValueType> + 'a>;

    // Provided methods
    fn register(registry: &mut Registry) { ... }
    fn is_empty(&self) -> bool { ... }
    fn is_none(&self) -> bool { ... }
}
Expand description

Represents a OpenAPI type.

Required Associated Constants§

Source

const IS_REQUIRED: bool

If it is true, it means that this type is required.

Required Associated Types§

Source

type RawValueType

The raw type used for validator.

Usually it is Self, but the wrapper type is its internal type.

For example:

i32::RawValueType is i32 Option<i32>::RawValueType is i32.

Source

type RawElementValueType

The raw element type used for validator.

Required Methods§

Source

fn name() -> Cow<'static, str>

Returns the name of this type

Source

fn schema_ref() -> MetaSchemaRef

Get schema reference of this type.

Source

fn as_raw_value(&self) -> Option<&Self::RawValueType>

Returns a reference to the raw value.

Source

fn raw_element_iter<'a>( &'a self, ) -> Box<dyn Iterator<Item = &'a Self::RawElementValueType> + 'a>

Returns an iterator for traversing the elements.

Provided Methods§

Source

fn register(registry: &mut Registry)

Register this type to types registry.

Source

fn is_empty(&self) -> bool

Returns true if this value is empty.

If the object’s field has the skip_serializing_if_is_empty attribute, call this method to test that the value is empty.

Source

fn is_none(&self) -> bool

Returns true if this value is none.

If the object’s field has the skip_serializing_if_is_none attribute, call this method to test that the value is none.

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementations on Foreign Types§

Source§

impl Type for IpAddr

Source§

const IS_REQUIRED: bool = true

Source§

type RawValueType = IpAddr

Source§

type RawElementValueType = IpAddr

Source§

fn name() -> Cow<'static, str>

Source§

fn schema_ref() -> MetaSchemaRef

Source§

fn as_raw_value(&self) -> Option<&Self::RawValueType>

Source§

fn raw_element_iter<'a>( &'a self, ) -> Box<dyn Iterator<Item = &'a Self::RawElementValueType> + 'a>

Source§

impl Type for IpNet

Source§

const IS_REQUIRED: bool = true

Source§

type RawValueType = IpNet

Source§

type RawElementValueType = IpNet

Source§

fn name() -> Cow<'static, str>

Source§

fn schema_ref() -> MetaSchemaRef

Source§

fn as_raw_value(&self) -> Option<&Self::RawValueType>

Source§

fn raw_element_iter<'a>( &'a self, ) -> Box<dyn Iterator<Item = &'a Self::RawElementValueType> + 'a>

Source§

impl Type for Value

Source§

const IS_REQUIRED: bool = true

Source§

type RawValueType = Value

Source§

type RawElementValueType = Value

Source§

fn name() -> Cow<'static, str>

Source§

fn schema_ref() -> MetaSchemaRef

Source§

fn as_raw_value(&self) -> Option<&Self::RawValueType>

Source§

fn raw_element_iter<'a>( &'a self, ) -> Box<dyn Iterator<Item = &'a Self::RawElementValueType> + 'a>

Source§

impl Type for bool

Source§

const IS_REQUIRED: bool = true

Source§

type RawValueType = bool

Source§

type RawElementValueType = bool

Source§

fn name() -> Cow<'static, str>

Source§

fn schema_ref() -> MetaSchemaRef

Source§

fn as_raw_value(&self) -> Option<&Self::RawValueType>

Source§

fn raw_element_iter<'a>( &'a self, ) -> Box<dyn Iterator<Item = &'a Self::RawElementValueType> + 'a>

Source§

impl Type for char

Source§

const IS_REQUIRED: bool = true

Source§

type RawValueType = char

Source§

type RawElementValueType = char

Source§

fn name() -> Cow<'static, str>

Source§

fn schema_ref() -> MetaSchemaRef

Source§

fn as_raw_value(&self) -> Option<&Self::RawValueType>

Source§

fn raw_element_iter<'a>( &'a self, ) -> Box<dyn Iterator<Item = &'a Self::RawElementValueType> + 'a>

Source§

impl Type for f32

Source§

const IS_REQUIRED: bool = true

Source§

type RawValueType = f32

Source§

type RawElementValueType = f32

Source§

fn name() -> Cow<'static, str>

Source§

fn schema_ref() -> MetaSchemaRef

Source§

fn as_raw_value(&self) -> Option<&Self::RawValueType>

Source§

fn raw_element_iter<'a>( &'a self, ) -> Box<dyn Iterator<Item = &'a Self::RawElementValueType> + 'a>

Source§

impl Type for f64

Source§

const IS_REQUIRED: bool = true

Source§

type RawValueType = f64

Source§

type RawElementValueType = f64

Source§

fn name() -> Cow<'static, str>

Source§

fn schema_ref() -> MetaSchemaRef

Source§

fn as_raw_value(&self) -> Option<&Self::RawValueType>

Source§

fn raw_element_iter<'a>( &'a self, ) -> Box<dyn Iterator<Item = &'a Self::RawElementValueType> + 'a>

Source§

impl Type for i8

Source§

const IS_REQUIRED: bool = true

Source§

type RawValueType = i8

Source§

type RawElementValueType = i8

Source§

fn name() -> Cow<'static, str>

Source§

fn schema_ref() -> MetaSchemaRef

Source§

fn as_raw_value(&self) -> Option<&Self::RawValueType>

Source§

fn raw_element_iter<'a>( &'a self, ) -> Box<dyn Iterator<Item = &'a Self::RawElementValueType> + 'a>

Source§

impl Type for i16

Source§

const IS_REQUIRED: bool = true

Source§

type RawValueType = i16

Source§

type RawElementValueType = i16

Source§

fn name() -> Cow<'static, str>

Source§

fn schema_ref() -> MetaSchemaRef

Source§

fn as_raw_value(&self) -> Option<&Self::RawValueType>

Source§

fn raw_element_iter<'a>( &'a self, ) -> Box<dyn Iterator<Item = &'a Self::RawElementValueType> + 'a>

Source§

impl Type for i32

Source§

const IS_REQUIRED: bool = true

Source§

type RawValueType = i32

Source§

type RawElementValueType = i32

Source§

fn name() -> Cow<'static, str>

Source§

fn schema_ref() -> MetaSchemaRef

Source§

fn as_raw_value(&self) -> Option<&Self::RawValueType>

Source§

fn raw_element_iter<'a>( &'a self, ) -> Box<dyn Iterator<Item = &'a Self::RawElementValueType> + 'a>

Source§

impl Type for i64

Source§

const IS_REQUIRED: bool = true

Source§

type RawValueType = i64

Source§

type RawElementValueType = i64

Source§

fn name() -> Cow<'static, str>

Source§

fn schema_ref() -> MetaSchemaRef

Source§

fn as_raw_value(&self) -> Option<&Self::RawValueType>

Source§

fn raw_element_iter<'a>( &'a self, ) -> Box<dyn Iterator<Item = &'a Self::RawElementValueType> + 'a>

Source§

impl Type for u8

Source§

const IS_REQUIRED: bool = true

Source§

type RawValueType = u8

Source§

type RawElementValueType = u8

Source§

fn name() -> Cow<'static, str>

Source§

fn schema_ref() -> MetaSchemaRef

Source§

fn as_raw_value(&self) -> Option<&Self::RawValueType>

Source§

fn raw_element_iter<'a>( &'a self, ) -> Box<dyn Iterator<Item = &'a Self::RawElementValueType> + 'a>

Source§

impl Type for u16

Source§

const IS_REQUIRED: bool = true

Source§

type RawValueType = u16

Source§

type RawElementValueType = u16

Source§

fn name() -> Cow<'static, str>

Source§

fn schema_ref() -> MetaSchemaRef

Source§

fn as_raw_value(&self) -> Option<&Self::RawValueType>

Source§

fn raw_element_iter<'a>( &'a self, ) -> Box<dyn Iterator<Item = &'a Self::RawElementValueType> + 'a>

Source§

impl Type for u32

Source§

const IS_REQUIRED: bool = true

Source§

type RawValueType = u32

Source§

type RawElementValueType = u32

Source§

fn name() -> Cow<'static, str>

Source§

fn schema_ref() -> MetaSchemaRef

Source§

fn as_raw_value(&self) -> Option<&Self::RawValueType>

Source§

fn raw_element_iter<'a>( &'a self, ) -> Box<dyn Iterator<Item = &'a Self::RawElementValueType> + 'a>

Source§

impl Type for u64

Source§

const IS_REQUIRED: bool = true

Source§

type RawValueType = u64

Source§

type RawElementValueType = u64

Source§

fn name() -> Cow<'static, str>

Source§

fn schema_ref() -> MetaSchemaRef

Source§

fn as_raw_value(&self) -> Option<&Self::RawValueType>

Source§

fn raw_element_iter<'a>( &'a self, ) -> Box<dyn Iterator<Item = &'a Self::RawElementValueType> + 'a>

Source§

impl Type for usize

Source§

const IS_REQUIRED: bool = true

Source§

type RawValueType = usize

Source§

type RawElementValueType = usize

Source§

fn name() -> Cow<'static, str>

Source§

fn schema_ref() -> MetaSchemaRef

Source§

fn as_raw_value(&self) -> Option<&Self::RawValueType>

Source§

fn raw_element_iter<'a>( &'a self, ) -> Box<dyn Iterator<Item = &'a Self::RawElementValueType> + 'a>

Source§

impl Type for String

Source§

const IS_REQUIRED: bool = true

Source§

type RawValueType = String

Source§

type RawElementValueType = String

Source§

fn name() -> Cow<'static, str>

Source§

fn schema_ref() -> MetaSchemaRef

Source§

fn as_raw_value(&self) -> Option<&Self::RawValueType>

Source§

fn raw_element_iter<'a>( &'a self, ) -> Box<dyn Iterator<Item = &'a Self::RawElementValueType> + 'a>

Source§

fn is_empty(&self) -> bool

Source§

impl Type for Ipv4Addr

Source§

const IS_REQUIRED: bool = true

Source§

type RawValueType = Ipv4Addr

Source§

type RawElementValueType = Ipv4Addr

Source§

fn name() -> Cow<'static, str>

Source§

fn schema_ref() -> MetaSchemaRef

Source§

fn as_raw_value(&self) -> Option<&Self::RawValueType>

Source§

fn raw_element_iter<'a>( &'a self, ) -> Box<dyn Iterator<Item = &'a Self::RawElementValueType> + 'a>

Source§

impl Type for Ipv6Addr

Source§

const IS_REQUIRED: bool = true

Source§

type RawValueType = Ipv6Addr

Source§

type RawElementValueType = Ipv6Addr

Source§

fn name() -> Cow<'static, str>

Source§

fn schema_ref() -> MetaSchemaRef

Source§

fn as_raw_value(&self) -> Option<&Self::RawValueType>

Source§

fn raw_element_iter<'a>( &'a self, ) -> Box<dyn Iterator<Item = &'a Self::RawElementValueType> + 'a>

Source§

impl Type for Duration

Source§

const IS_REQUIRED: bool = true

Source§

type RawValueType = Duration

Source§

type RawElementValueType = Duration

Source§

fn name() -> Cow<'static, str>

Source§

fn schema_ref() -> MetaSchemaRef

Source§

fn as_raw_value(&self) -> Option<&Self::RawValueType>

Source§

fn raw_element_iter<'a>( &'a self, ) -> Box<dyn Iterator<Item = &'a Self::RawElementValueType> + 'a>

Source§

impl Type for ObjectId

Source§

const IS_REQUIRED: bool = true

Source§

type RawValueType = ObjectId

Source§

type RawElementValueType = ObjectId

Source§

fn name() -> Cow<'static, str>

Source§

fn schema_ref() -> MetaSchemaRef

Source§

fn as_raw_value(&self) -> Option<&Self::RawValueType>

Source§

fn raw_element_iter<'a>( &'a self, ) -> Box<dyn Iterator<Item = &'a Self::RawElementValueType> + 'a>

Source§

impl Type for DateTime<FixedOffset>

Source§

impl Type for DateTime<Local>

Source§

const IS_REQUIRED: bool = true

Source§

type RawValueType = DateTime<Local>

Source§

type RawElementValueType = DateTime<Local>

Source§

fn name() -> Cow<'static, str>

Source§

fn schema_ref() -> MetaSchemaRef

Source§

fn as_raw_value(&self) -> Option<&Self::RawValueType>

Source§

fn raw_element_iter<'a>( &'a self, ) -> Box<dyn Iterator<Item = &'a Self::RawElementValueType> + 'a>

Source§

impl Type for DateTime<Utc>

Source§

const IS_REQUIRED: bool = true

Source§

type RawValueType = DateTime<Utc>

Source§

type RawElementValueType = DateTime<Utc>

Source§

fn name() -> Cow<'static, str>

Source§

fn schema_ref() -> MetaSchemaRef

Source§

fn as_raw_value(&self) -> Option<&Self::RawValueType>

Source§

fn raw_element_iter<'a>( &'a self, ) -> Box<dyn Iterator<Item = &'a Self::RawElementValueType> + 'a>

Source§

impl Type for NaiveDate

Source§

const IS_REQUIRED: bool = true

Source§

type RawValueType = NaiveDate

Source§

type RawElementValueType = NaiveDate

Source§

fn name() -> Cow<'static, str>

Source§

fn schema_ref() -> MetaSchemaRef

Source§

fn as_raw_value(&self) -> Option<&Self::RawValueType>

Source§

fn raw_element_iter<'a>( &'a self, ) -> Box<dyn Iterator<Item = &'a Self::RawElementValueType> + 'a>

Source§

impl Type for NaiveDateTime

Source§

const IS_REQUIRED: bool = true

Source§

type RawValueType = NaiveDateTime

Source§

type RawElementValueType = NaiveDateTime

Source§

fn name() -> Cow<'static, str>

Source§

fn schema_ref() -> MetaSchemaRef

Source§

fn as_raw_value(&self) -> Option<&Self::RawValueType>

Source§

fn raw_element_iter<'a>( &'a self, ) -> Box<dyn Iterator<Item = &'a Self::RawElementValueType> + 'a>

Source§

impl Type for NaiveTime

Source§

const IS_REQUIRED: bool = true

Source§

type RawValueType = NaiveTime

Source§

type RawElementValueType = NaiveTime

Source§

fn name() -> Cow<'static, str>

Source§

fn schema_ref() -> MetaSchemaRef

Source§

fn as_raw_value(&self) -> Option<&Self::RawValueType>

Source§

fn raw_element_iter<'a>( &'a self, ) -> Box<dyn Iterator<Item = &'a Self::RawElementValueType> + 'a>

Source§

impl Type for LineString

Source§

const IS_REQUIRED: bool = true

Source§

type RawValueType = LineString

Source§

type RawElementValueType = LineString

Source§

fn name() -> Cow<'static, str>

Source§

fn schema_ref() -> MetaSchemaRef

Source§

fn register(registry: &mut Registry)

Source§

fn as_raw_value(&self) -> Option<&Self::RawValueType>

Source§

fn raw_element_iter<'a>( &'a self, ) -> Box<dyn Iterator<Item = &'a Self::RawElementValueType> + 'a>

Source§

impl Type for MultiLineString

Source§

const IS_REQUIRED: bool = true

Source§

type RawValueType = MultiLineString

Source§

type RawElementValueType = MultiLineString

Source§

fn name() -> Cow<'static, str>

Source§

fn schema_ref() -> MetaSchemaRef

Source§

fn register(registry: &mut Registry)

Source§

fn as_raw_value(&self) -> Option<&Self::RawValueType>

Source§

fn raw_element_iter<'a>( &'a self, ) -> Box<dyn Iterator<Item = &'a Self::RawElementValueType> + 'a>

Source§

impl Type for MultiPoint

Source§

const IS_REQUIRED: bool = true

Source§

type RawValueType = MultiPoint

Source§

type RawElementValueType = MultiPoint

Source§

fn name() -> Cow<'static, str>

Source§

fn schema_ref() -> MetaSchemaRef

Source§

fn register(registry: &mut Registry)

Source§

fn as_raw_value(&self) -> Option<&Self::RawValueType>

Source§

fn raw_element_iter<'a>( &'a self, ) -> Box<dyn Iterator<Item = &'a Self::RawElementValueType> + 'a>

Source§

impl Type for MultiPolygon

Source§

const IS_REQUIRED: bool = true

Source§

type RawValueType = MultiPolygon

Source§

type RawElementValueType = MultiPolygon

Source§

fn name() -> Cow<'static, str>

Source§

fn schema_ref() -> MetaSchemaRef

Source§

fn register(registry: &mut Registry)

Source§

fn as_raw_value(&self) -> Option<&Self::RawValueType>

Source§

fn raw_element_iter<'a>( &'a self, ) -> Box<dyn Iterator<Item = &'a Self::RawElementValueType> + 'a>

Source§

impl Type for Point

Source§

const IS_REQUIRED: bool = true

Source§

type RawValueType = Point

Source§

type RawElementValueType = Point

Source§

fn name() -> Cow<'static, str>

Source§

fn schema_ref() -> MetaSchemaRef

Source§

fn register(registry: &mut Registry)

Source§

fn as_raw_value(&self) -> Option<&Self::RawValueType>

Source§

fn raw_element_iter<'a>( &'a self, ) -> Box<dyn Iterator<Item = &'a Self::RawElementValueType> + 'a>

Source§

impl Type for Polygon

Source§

const IS_REQUIRED: bool = true

Source§

type RawValueType = Polygon

Source§

type RawElementValueType = Polygon

Source§

fn name() -> Cow<'static, str>

Source§

fn schema_ref() -> MetaSchemaRef

Source§

fn register(registry: &mut Registry)

Source§

fn as_raw_value(&self) -> Option<&Self::RawValueType>

Source§

fn raw_element_iter<'a>( &'a self, ) -> Box<dyn Iterator<Item = &'a Self::RawElementValueType> + 'a>

Source§

impl Type for Uri

Source§

const IS_REQUIRED: bool = true

Source§

type RawValueType = Uri

Source§

type RawElementValueType = Uri

Source§

fn name() -> Cow<'static, str>

Source§

fn schema_ref() -> MetaSchemaRef

Source§

fn as_raw_value(&self) -> Option<&Self::RawValueType>

Source§

fn raw_element_iter<'a>( &'a self, ) -> Box<dyn Iterator<Item = &'a Self::RawElementValueType> + 'a>

Source§

impl Type for Duration

Source§

const IS_REQUIRED: bool = true

Source§

type RawValueType = Duration

Source§

type RawElementValueType = Duration

Source§

fn name() -> Cow<'static, str>

Source§

fn schema_ref() -> MetaSchemaRef

Source§

fn as_raw_value(&self) -> Option<&Self::RawValueType>

Source§

fn raw_element_iter<'a>( &'a self, ) -> Box<dyn Iterator<Item = &'a Self::RawElementValueType> + 'a>

Source§

impl Type for Ipv4Net

Source§

const IS_REQUIRED: bool = true

Source§

type RawValueType = Ipv4Net

Source§

type RawElementValueType = Ipv4Net

Source§

fn name() -> Cow<'static, str>

Source§

fn schema_ref() -> MetaSchemaRef

Source§

fn as_raw_value(&self) -> Option<&Self::RawValueType>

Source§

fn raw_element_iter<'a>( &'a self, ) -> Box<dyn Iterator<Item = &'a Self::RawElementValueType> + 'a>

Source§

impl Type for Ipv6Net

Source§

const IS_REQUIRED: bool = true

Source§

type RawValueType = Ipv6Net

Source§

type RawElementValueType = Ipv6Net

Source§

fn name() -> Cow<'static, str>

Source§

fn schema_ref() -> MetaSchemaRef

Source§

fn as_raw_value(&self) -> Option<&Self::RawValueType>

Source§

fn raw_element_iter<'a>( &'a self, ) -> Box<dyn Iterator<Item = &'a Self::RawElementValueType> + 'a>

Source§

impl Type for Struct

Source§

const IS_REQUIRED: bool = true

Source§

type RawValueType = Struct

Source§

type RawElementValueType = <Value as Type>::RawValueType

Source§

fn name() -> Cow<'static, str>

Source§

fn schema_ref() -> MetaSchemaRef

Source§

fn as_raw_value(&self) -> Option<&Self::RawValueType>

Source§

fn raw_element_iter<'a>( &'a self, ) -> Box<dyn Iterator<Item = &'a Self::RawElementValueType> + 'a>

Source§

fn is_empty(&self) -> bool

Source§

impl Type for Value

Source§

const IS_REQUIRED: bool = true

Source§

type RawValueType = Value

Source§

type RawElementValueType = Value

Source§

fn name() -> Cow<'static, str>

Source§

fn schema_ref() -> MetaSchemaRef

Source§

fn as_raw_value(&self) -> Option<&Self::RawValueType>

Source§

fn raw_element_iter<'a>( &'a self, ) -> Box<dyn Iterator<Item = &'a Self::RawElementValueType> + 'a>

Source§

fn is_empty(&self) -> bool

Source§

impl Type for Regex

Source§

const IS_REQUIRED: bool = true

Source§

type RawValueType = Regex

Source§

type RawElementValueType = Regex

Source§

fn name() -> Cow<'static, str>

Source§

fn schema_ref() -> MetaSchemaRef

Source§

fn as_raw_value(&self) -> Option<&Self::RawValueType>

Source§

fn raw_element_iter<'a>( &'a self, ) -> Box<dyn Iterator<Item = &'a Self::RawElementValueType> + 'a>

Source§

impl Type for Decimal

Source§

const IS_REQUIRED: bool = true

Source§

type RawValueType = Decimal

Source§

type RawElementValueType = Decimal

Source§

fn name() -> Cow<'static, str>

Source§

fn schema_ref() -> MetaSchemaRef

Source§

fn as_raw_value(&self) -> Option<&Self::RawValueType>

Source§

fn raw_element_iter<'a>( &'a self, ) -> Box<dyn Iterator<Item = &'a Self::RawElementValueType> + 'a>

Source§

impl Type for Date

Source§

const IS_REQUIRED: bool = true

Source§

type RawValueType = Date

Source§

type RawElementValueType = Date

Source§

fn name() -> Cow<'static, str>

Source§

fn schema_ref() -> MetaSchemaRef

Source§

fn as_raw_value(&self) -> Option<&Self::RawValueType>

Source§

fn raw_element_iter<'a>( &'a self, ) -> Box<dyn Iterator<Item = &'a Self::RawElementValueType> + 'a>

Source§

impl Type for OffsetDateTime

Source§

impl Type for PrimitiveDateTime

Source§

impl Type for Time

Source§

const IS_REQUIRED: bool = true

Source§

type RawValueType = Time

Source§

type RawElementValueType = Time

Source§

fn name() -> Cow<'static, str>

Source§

fn schema_ref() -> MetaSchemaRef

Source§

fn as_raw_value(&self) -> Option<&Self::RawValueType>

Source§

fn raw_element_iter<'a>( &'a self, ) -> Box<dyn Iterator<Item = &'a Self::RawElementValueType> + 'a>

Source§

impl Type for Url

Source§

const IS_REQUIRED: bool = true

Source§

type RawValueType = Url

Source§

type RawElementValueType = Url

Source§

fn name() -> Cow<'static, str>

Source§

fn schema_ref() -> MetaSchemaRef

Source§

fn as_raw_value(&self) -> Option<&Self::RawValueType>

Source§

fn raw_element_iter<'a>( &'a self, ) -> Box<dyn Iterator<Item = &'a Self::RawElementValueType> + 'a>

Source§

impl Type for Uuid

Source§

const IS_REQUIRED: bool = true

Source§

type RawValueType = Uuid

Source§

type RawElementValueType = Uuid

Source§

fn name() -> Cow<'static, str>

Source§

fn schema_ref() -> MetaSchemaRef

Source§

fn as_raw_value(&self) -> Option<&Self::RawValueType>

Source§

fn raw_element_iter<'a>( &'a self, ) -> Box<dyn Iterator<Item = &'a Self::RawElementValueType> + 'a>

Source§

impl<'a> Type for &'a str

Source§

const IS_REQUIRED: bool = true

Source§

type RawValueType = &'a str

Source§

type RawElementValueType = &'a str

Source§

fn name() -> Cow<'static, str>

Source§

fn schema_ref() -> MetaSchemaRef

Source§

fn as_raw_value(&self) -> Option<&Self::RawValueType>

Source§

fn raw_element_iter<'b>( &'b self, ) -> Box<dyn Iterator<Item = &'b Self::RawElementValueType> + 'b>

Source§

impl<K, V> Type for BTreeMap<K, V>
where K: ToString + FromStr + Ord + Sync + Send, V: Type,

Source§

const IS_REQUIRED: bool = true

Source§

type RawValueType = BTreeMap<K, V>

Source§

type RawElementValueType = <V as Type>::RawValueType

Source§

fn name() -> Cow<'static, str>

Source§

fn schema_ref() -> MetaSchemaRef

Source§

fn register(registry: &mut Registry)

Source§

fn as_raw_value(&self) -> Option<&Self::RawValueType>

Source§

fn raw_element_iter<'a>( &'a self, ) -> Box<dyn Iterator<Item = &'a Self::RawElementValueType> + 'a>

Source§

fn is_empty(&self) -> bool

Source§

impl<K, V, R> Type for HashMap<K, V, R>
where K: ToString + FromStr + Eq + Hash + Sync + Send, V: Type, R: Sync + Send,

Source§

const IS_REQUIRED: bool = true

Source§

type RawValueType = HashMap<K, V, R>

Source§

type RawElementValueType = <V as Type>::RawValueType

Source§

fn name() -> Cow<'static, str>

Source§

fn schema_ref() -> MetaSchemaRef

Source§

fn register(registry: &mut Registry)

Source§

fn as_raw_value(&self) -> Option<&Self::RawValueType>

Source§

fn raw_element_iter<'a>( &'a self, ) -> Box<dyn Iterator<Item = &'a Self::RawElementValueType> + 'a>

Source§

fn is_empty(&self) -> bool

Source§

impl<T: Type> Type for &[T]

Source§

const IS_REQUIRED: bool = true

Source§

type RawValueType = &[T]

Source§

type RawElementValueType = <T as Type>::RawValueType

Source§

fn name() -> Cow<'static, str>

Source§

fn schema_ref() -> MetaSchemaRef

Source§

fn register(registry: &mut Registry)

Source§

fn as_raw_value(&self) -> Option<&Self::RawValueType>

Source§

fn raw_element_iter<'a>( &'a self, ) -> Box<dyn Iterator<Item = &'a Self::RawElementValueType> + 'a>

Source§

fn is_empty(&self) -> bool

Source§

impl<T: Type> Type for Option<T>

Source§

const IS_REQUIRED: bool = false

Source§

type RawValueType = <T as Type>::RawValueType

Source§

type RawElementValueType = <T as Type>::RawElementValueType

Source§

fn name() -> Cow<'static, str>

Source§

fn schema_ref() -> MetaSchemaRef

Source§

fn register(registry: &mut Registry)

Source§

fn as_raw_value(&self) -> Option<&Self::RawValueType>

Source§

fn raw_element_iter<'a>( &'a self, ) -> Box<dyn Iterator<Item = &'a Self::RawElementValueType> + 'a>

Source§

fn is_none(&self) -> bool

Source§

impl<T: Type> Type for &T

Source§

const IS_REQUIRED: bool = T::IS_REQUIRED

Source§

type RawValueType = <T as Type>::RawValueType

Source§

type RawElementValueType = <T as Type>::RawElementValueType

Source§

fn name() -> Cow<'static, str>

Source§

fn schema_ref() -> MetaSchemaRef

Source§

fn register(registry: &mut Registry)

Source§

fn as_raw_value(&self) -> Option<&Self::RawValueType>

Source§

fn raw_element_iter<'a>( &'a self, ) -> Box<dyn Iterator<Item = &'a Self::RawElementValueType> + 'a>

Source§

impl<T: Type> Type for Box<T>

Source§

const IS_REQUIRED: bool = T::IS_REQUIRED

Source§

type RawValueType = <T as Type>::RawValueType

Source§

type RawElementValueType = <T as Type>::RawElementValueType

Source§

fn name() -> Cow<'static, str>

Source§

fn schema_ref() -> MetaSchemaRef

Source§

fn register(registry: &mut Registry)

Source§

fn as_raw_value(&self) -> Option<&Self::RawValueType>

Source§

fn raw_element_iter<'a>( &'a self, ) -> Box<dyn Iterator<Item = &'a Self::RawElementValueType> + 'a>

Source§

impl<T: Type> Type for BTreeSet<T>

Source§

const IS_REQUIRED: bool = true

Source§

type RawValueType = BTreeSet<T>

Source§

type RawElementValueType = <T as Type>::RawValueType

Source§

fn name() -> Cow<'static, str>

Source§

fn schema_ref() -> MetaSchemaRef

Source§

fn register(registry: &mut Registry)

Source§

fn as_raw_value(&self) -> Option<&Self::RawValueType>

Source§

fn raw_element_iter<'a>( &'a self, ) -> Box<dyn Iterator<Item = &'a Self::RawElementValueType> + 'a>

Source§

fn is_empty(&self) -> bool

Source§

impl<T: Type> Type for Arc<T>

Source§

const IS_REQUIRED: bool = T::IS_REQUIRED

Source§

type RawValueType = <T as Type>::RawValueType

Source§

type RawElementValueType = <T as Type>::RawElementValueType

Source§

fn name() -> Cow<'static, str>

Source§

fn schema_ref() -> MetaSchemaRef

Source§

fn register(registry: &mut Registry)

Source§

fn as_raw_value(&self) -> Option<&Self::RawValueType>

Source§

fn raw_element_iter<'a>( &'a self, ) -> Box<dyn Iterator<Item = &'a Self::RawElementValueType> + 'a>

Source§

impl<T: Type> Type for Vec<T>

Source§

const IS_REQUIRED: bool = true

Source§

type RawValueType = Vec<T>

Source§

type RawElementValueType = <T as Type>::RawValueType

Source§

fn name() -> Cow<'static, str>

Source§

fn schema_ref() -> MetaSchemaRef

Source§

fn register(registry: &mut Registry)

Source§

fn as_raw_value(&self) -> Option<&Self::RawValueType>

Source§

fn raw_element_iter<'a>( &'a self, ) -> Box<dyn Iterator<Item = &'a Self::RawElementValueType> + 'a>

Source§

fn is_empty(&self) -> bool

Source§

impl<T: Type> Type for Json<T>

Source§

const IS_REQUIRED: bool = <Self::RawValueType>::IS_REQUIRED

Source§

type RawValueType = T

Source§

type RawElementValueType = <T as Type>::RawElementValueType

Source§

fn name() -> Cow<'static, str>

Source§

fn schema_ref() -> MetaSchemaRef

Source§

fn as_raw_value(&self) -> Option<&Self::RawValueType>

Source§

fn raw_element_iter<'a>( &'a self, ) -> Box<dyn Iterator<Item = &'a Self::RawElementValueType> + 'a>

Source§

impl<T: Type, R: Send + Sync> Type for HashSet<T, R>

Source§

const IS_REQUIRED: bool = true

Source§

type RawValueType = HashSet<T, R>

Source§

type RawElementValueType = <T as Type>::RawValueType

Source§

fn name() -> Cow<'static, str>

Source§

fn schema_ref() -> MetaSchemaRef

Source§

fn register(registry: &mut Registry)

Source§

fn as_raw_value(&self) -> Option<&Self::RawValueType>

Source§

fn raw_element_iter<'a>( &'a self, ) -> Box<dyn Iterator<Item = &'a Self::RawElementValueType> + 'a>

Source§

fn is_empty(&self) -> bool

Source§

impl<T: Type, const LEN: usize> Type for [T; LEN]

Source§

const IS_REQUIRED: bool = true

Source§

type RawValueType = [T; LEN]

Source§

type RawElementValueType = <T as Type>::RawValueType

Source§

fn name() -> Cow<'static, str>

Source§

fn schema_ref() -> MetaSchemaRef

Source§

fn register(registry: &mut Registry)

Source§

fn as_raw_value(&self) -> Option<&Self::RawValueType>

Source§

fn raw_element_iter<'a>( &'a self, ) -> Box<dyn Iterator<Item = &'a Self::RawElementValueType> + 'a>

Implementors§