pub trait SQLIndex<'a, Value: SQLParam + 'a>: ToSQL<'a, Value> {
type Table: SQLTable<'a, Value>;
// Required method
fn name(&self) -> &'static str;
// Provided method
fn is_unique(&self) -> bool { ... }
}Expand description
Trait for types that represent database indexes.
Implemented by tuple structs like struct UserEmailIdx(User::email);