pub struct AnnIndexRegistry { /* private fields */ }Expand description
ANN 索引管理器(内存版,用于跟踪已创建的索引)
Implementations§
Source§impl AnnIndexRegistry
impl AnnIndexRegistry
Sourcepub fn register(&mut self, def: AnnIndexDef) -> Result<(), VectorError>
pub fn register(&mut self, def: AnnIndexDef) -> Result<(), VectorError>
注册一个 ANN 索引
Sourcepub fn unregister(
&mut self,
index_name: &str,
) -> Result<AnnIndexDef, VectorError>
pub fn unregister( &mut self, index_name: &str, ) -> Result<AnnIndexDef, VectorError>
注销一个 ANN 索引
Sourcepub fn list_for_collection(&self, collection: &str) -> Vec<&AnnIndexDef>
pub fn list_for_collection(&self, collection: &str) -> Vec<&AnnIndexDef>
列出某集合上的所有索引
Sourcepub fn list_all(&self) -> Vec<&AnnIndexDef>
pub fn list_all(&self) -> Vec<&AnnIndexDef>
获取所有索引
Sourcepub fn reindex_all_sql(&self) -> Vec<String>
pub fn reindex_all_sql(&self) -> Vec<String>
生成重建所有索引的 SQL 列表
Trait Implementations§
Source§impl Clone for AnnIndexRegistry
impl Clone for AnnIndexRegistry
Source§fn clone(&self) -> AnnIndexRegistry
fn clone(&self) -> AnnIndexRegistry
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 AnnIndexRegistry
impl Debug for AnnIndexRegistry
Source§impl Default for AnnIndexRegistry
impl Default for AnnIndexRegistry
Source§fn default() -> AnnIndexRegistry
fn default() -> AnnIndexRegistry
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl Freeze for AnnIndexRegistry
impl RefUnwindSafe for AnnIndexRegistry
impl Send for AnnIndexRegistry
impl Sync for AnnIndexRegistry
impl Unpin for AnnIndexRegistry
impl UnsafeUnpin for AnnIndexRegistry
impl UnwindSafe for AnnIndexRegistry
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