pub struct ExactFlatVectorIndex { /* private fields */ }Implementations§
Source§impl ExactFlatVectorIndex
impl ExactFlatVectorIndex
pub fn new(dimensions: usize) -> Result<Self>
pub fn add(&mut self, record: VectorRecord) -> Result<()>
pub fn remove(&mut self, id: VectorId) -> Option<VectorRecord>
pub fn search( &self, query: &[f32], options: VectorSearchOptions, ) -> Result<Vec<VectorHit>>
pub fn save(&self, path: &Path) -> Result<()>
pub fn load(path: &Path) -> Result<Self>
pub fn stats(&self) -> VectorIndexStats
Trait Implementations§
Source§impl Clone for ExactFlatVectorIndex
impl Clone for ExactFlatVectorIndex
Source§fn clone(&self) -> ExactFlatVectorIndex
fn clone(&self) -> ExactFlatVectorIndex
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 ExactFlatVectorIndex
impl Debug for ExactFlatVectorIndex
Source§impl<'de> Deserialize<'de> for ExactFlatVectorIndex
impl<'de> Deserialize<'de> for ExactFlatVectorIndex
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for ExactFlatVectorIndex
impl RefUnwindSafe for ExactFlatVectorIndex
impl Send for ExactFlatVectorIndex
impl Sync for ExactFlatVectorIndex
impl Unpin for ExactFlatVectorIndex
impl UnsafeUnpin for ExactFlatVectorIndex
impl UnwindSafe for ExactFlatVectorIndex
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