pub trait View:
Sized
+ Send
+ Sync {
const VIEW_NAME: &'static str;
const DB_VIEW_NAME: &'static str;
const COLUMNS: &'static [&'static str];
const IS_MATERIALIZED: bool;
}Expand description
A database view that can be queried (read-only).
Views are similar to models but only support read operations. They cannot be inserted into, updated, or deleted from directly.
Required Associated Constants§
Sourceconst DB_VIEW_NAME: &'static str
const DB_VIEW_NAME: &'static str
The name of the database view.
Sourceconst IS_MATERIALIZED: bool
const IS_MATERIALIZED: bool
Whether this is a materialized view.
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.