pub trait ReadModel:
Serialize
+ DeserializeOwned
+ Clone
+ Send
+ Sync {
const COLLECTION: &'static str;
// Required method
fn id(&self) -> &str;
}Expand description
Trait implemented by the derive macro for read-model identity metadata.
Required Associated Constants§
Sourceconst COLLECTION: &'static str
const COLLECTION: &'static str
The declared storage name for this read model type.
Required Methods§
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".