Skip to main content

VectorIndexSource

Trait VectorIndexSource 

Source
pub trait VectorIndexSource {
    // Required method
    fn visit(
        &self,
        visitor: &mut dyn FnMut(&str, &dyn VectorIndex) -> StorageBackendResult<()>,
    ) -> StorageBackendResult<()>;

    // Provided method
    fn retained_collection(&self) -> StorageBackendResult<Option<VectorIndexes>> { ... }
}
Expand description

Borrow physical vector registrations without requiring an owned metadata copy.

Required Methods§

Source

fn visit( &self, visitor: &mut dyn FnMut(&str, &dyn VectorIndex) -> StorageBackendResult<()>, ) -> StorageBackendResult<()>

Provided Methods§

Source

fn retained_collection(&self) -> StorageBackendResult<Option<VectorIndexes>>

An immutable collection may share its original allocation owner. Implementations must never capture or clone a live collection here.

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementations on Foreign Types§

Source§

impl VectorIndexSource for BTreeMap<FieldName, Box<dyn VectorIndex>>

Source§

fn visit( &self, visitor: &mut dyn FnMut(&str, &dyn VectorIndex) -> StorageBackendResult<()>, ) -> StorageBackendResult<()>

Implementors§