Skip to main content

Model

Trait Model 

Source
pub trait Model: Sealed {
    type Schema: Schema;

    const TYPE_ID_JSON: &'static str;
}
Expand description

A sealed generated schema model associated with its schema marker S.

Required Associated Constants§

Source

const TYPE_ID_JSON: &'static str

Canonical JSON identity for the projected schema type.

Required Associated Types§

Source

type Schema: Schema

The generated schema that owns this model.

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§

Source§

impl<L: Model<Schema = S>, R: Model<Schema = S>, S: Schema> Model for Either<L, R>

Source§

const TYPE_ID_JSON: &'static str = "either"

Source§

type Schema = S