Trait Schema

Source
pub trait Schema:
    Debug
    + Send
    + Sync
    + 'static
    + Sized {
    type Key: KeyCodec<Self>;
    type Value: ValueCodec<Self>;

    const COLUMN_FAMILY_NAME: ColumnFamilyName;
}
Expand description

A Schema is a type-safe interface over a specific column family in a DB. It always a key type (KeyCodec) and a value type (ValueCodec).

Required Associated Constants§

Source

const COLUMN_FAMILY_NAME: ColumnFamilyName

The column family name associated with this struct. Note: all schemas within the same SchemaDB must have distinct column family names.

Required Associated Types§

Source

type Key: KeyCodec<Self>

Type of the key.

Source

type Value: ValueCodec<Self>

Type of the value.

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.

Implementors§