pub struct IndexCatalog { /* private fields */ }Implementations§
Source§impl IndexCatalog
impl IndexCatalog
pub fn list(&self) -> Vec<IndexDefinition>
pub fn get(&self, name: &str) -> Option<&IndexDefinition>
pub fn contains_name(&self, name: &str) -> bool
Sourcepub fn find_equivalent(
&self,
request: &IndexRequest,
) -> Option<&IndexDefinition>
pub fn find_equivalent( &self, request: &IndexRequest, ) -> Option<&IndexDefinition>
Look up an existing entry whose (kind, entity, label, properties)
match the supplied request. The token-lookup variant collapses to
(kind, entity) because there is at most one token index per entity.
Sourcepub fn next_auto_name(&mut self, request: &IndexRequest) -> String
pub fn next_auto_name(&mut self, request: &IndexRequest) -> String
Generate a deterministic auto name when the user did not supply one. Names are stable for a given (kind, entity, label, properties) tuple within a session.
pub fn try_create( &mut self, request: IndexRequest, if_not_exists: bool, ) -> Result<CreateIndexOutcome, CreateIndexError>
pub fn try_drop( &mut self, name: &str, if_exists: bool, ) -> Result<DropIndexOutcome, DropIndexError>
Sourcepub fn set_state(&mut self, name: &str, state: StoredIndexState)
pub fn set_state(&mut self, name: &str, state: StoredIndexState)
In-place state transition for an existing entry. Used by
lazy-populate flows: an index registers as Populating at
CREATE time and flips to Online once the first query
triggers the deferred backfill. No-op if the index is gone.
Trait Implementations§
Source§impl Clone for IndexCatalog
impl Clone for IndexCatalog
Source§fn clone(&self) -> IndexCatalog
fn clone(&self) -> IndexCatalog
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · 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 IndexCatalog
impl Debug for IndexCatalog
Source§impl Default for IndexCatalog
impl Default for IndexCatalog
Source§fn default() -> IndexCatalog
fn default() -> IndexCatalog
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl Freeze for IndexCatalog
impl RefUnwindSafe for IndexCatalog
impl Send for IndexCatalog
impl Sync for IndexCatalog
impl Unpin for IndexCatalog
impl UnsafeUnpin for IndexCatalog
impl UnwindSafe for IndexCatalog
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