pub trait CqlType {
type ValueType;
const VALUE_SIZE: usize;
}Expand description
The base CQL Value Type
All read/writable types to a CQL Database should derive from this.
§Examples
This declares a CQL Type to read/write Strings of a maximum length of 255 bytes from the database:
pub struct TinyText;
impl CqlType for TinyText {
type ValueType = String;
const VALUE_SIZE: usize = 255;
}Required Associated Constants§
Sourceconst VALUE_SIZE: usize
const VALUE_SIZE: usize
The (maximum) size of the value to read/write from the database.
Required Associated Types§
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.