pub struct CollectionIndexes { /* private fields */ }Expand description
Container holding all index instances for a single collection.
Implementations§
Source§impl CollectionIndexes
impl CollectionIndexes
Sourcepub fn get_or_create_hash(&mut self, field_id: FieldId) -> &mut HashIndex
pub fn get_or_create_hash(&mut self, field_id: FieldId) -> &mut HashIndex
Return a mutable reference to the hash index for a field, creating one if absent.
Sourcepub fn get_or_create_sorted(&mut self, field_id: FieldId) -> &mut SortedIndex
pub fn get_or_create_sorted(&mut self, field_id: FieldId) -> &mut SortedIndex
Return a mutable reference to the sorted index for a field, creating one if absent.
Sourcepub fn get_or_create_array(&mut self, field_id: FieldId) -> &mut HashIndex
pub fn get_or_create_array(&mut self, field_id: FieldId) -> &mut HashIndex
Return a mutable reference to the array index for a field, creating one if absent.
Sourcepub fn get_or_create_unique(&mut self, field_id: FieldId) -> &mut UniqueIndex
pub fn get_or_create_unique(&mut self, field_id: FieldId) -> &mut UniqueIndex
Return a mutable reference to the unique index for a field, creating one if absent.
Sourcepub fn hash(&self, field_id: FieldId) -> Option<&HashIndex>
pub fn hash(&self, field_id: FieldId) -> Option<&HashIndex>
Return an immutable reference to the hash index for a field.
Sourcepub fn sorted(&self, field_id: FieldId) -> Option<&SortedIndex>
pub fn sorted(&self, field_id: FieldId) -> Option<&SortedIndex>
Return an immutable reference to the sorted index for a field.
Sourcepub fn array(&self, field_id: FieldId) -> Option<&HashIndex>
pub fn array(&self, field_id: FieldId) -> Option<&HashIndex>
Return an immutable reference to the array index for a field.
Sourcepub fn unique(&self, field_id: FieldId) -> Option<&UniqueIndex>
pub fn unique(&self, field_id: FieldId) -> Option<&UniqueIndex>
Return an immutable reference to the unique index for a field.
Sourcepub fn remove_field(&mut self, field_id: FieldId)
pub fn remove_field(&mut self, field_id: FieldId)
Remove all indexes for a field across all index types.
Trait Implementations§
Source§impl Debug for CollectionIndexes
impl Debug for CollectionIndexes
Source§impl Default for CollectionIndexes
impl Default for CollectionIndexes
Source§fn default() -> CollectionIndexes
fn default() -> CollectionIndexes
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl Freeze for CollectionIndexes
impl RefUnwindSafe for CollectionIndexes
impl Send for CollectionIndexes
impl Sync for CollectionIndexes
impl Unpin for CollectionIndexes
impl UnsafeUnpin for CollectionIndexes
impl UnwindSafe for CollectionIndexes
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