pub struct IndexField {
pub field: FieldId,
pub op: IndexOp,
pub scope: IndexScope,
}Expand description
A single field entry within an Index.
Describes which field is indexed, the comparison operation used for lookups, and whether this field is a partition key or a local (sort) key.
§Examples
use toasty_core::schema::app::{IndexField, ModelId};
use toasty_core::schema::db::{IndexOp, IndexScope};
let field = IndexField {
field: ModelId(0).field(1),
op: IndexOp::Eq,
scope: IndexScope::Local,
};Fields§
§field: FieldIdThe field being indexed.
op: IndexOpThe comparison operation used when querying this index field.
scope: IndexScopeWhether this field is a partition key or a local (sort) key.
Trait Implementations§
Source§impl Clone for IndexField
impl Clone for IndexField
Source§fn clone(&self) -> IndexField
fn clone(&self) -> IndexField
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for IndexField
impl Debug for IndexField
impl Copy for IndexField
Auto Trait Implementations§
impl Freeze for IndexField
impl RefUnwindSafe for IndexField
impl Send for IndexField
impl Sync for IndexField
impl Unpin for IndexField
impl UnwindSafe for IndexField
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more