Skip to main content

VectorQuery

Struct VectorQuery 

Source
pub struct VectorQuery { /* private fields */ }

Implementations§

Source§

impl VectorQuery

Source

pub fn builder() -> VectorQueryBuilder

Start building a vector query.

Source§

impl VectorQuery

Source

pub fn new() -> Result<Self>

Source

pub fn topk(&self) -> i32

Source

pub fn set_topk(&mut self, topk: i32) -> Result<()>

Source

pub fn field_name(&self) -> Option<String>

Source

pub fn set_field_name(&mut self, name: &str) -> Result<()>

Source

pub fn set_query_vector_raw(&mut self, bytes: &[u8]) -> Result<()>

Source

pub fn set_query_vector_fp32(&mut self, vec: &[f32]) -> Result<()>

Source

pub fn set_query_vector_fp64(&mut self, vec: &[f64]) -> Result<()>

Source

pub fn set_query_vector_fp16(&mut self, vec: &[f16]) -> Result<()>

Available on crate feature half only.

Set a half-precision query vector directly from &[half::f16].

Available with the half cargo feature.

Source

pub fn filter(&self) -> Option<String>

Source

pub fn set_filter(&mut self, filter: &str) -> Result<()>

Source

pub fn include_vector(&self) -> bool

Source

pub fn set_include_vector(&mut self, b: bool) -> Result<()>

Source

pub fn include_doc_id(&self) -> bool

Source

pub fn set_include_doc_id(&mut self, b: bool) -> Result<()>

Source

pub fn set_output_fields(&mut self, fields: &[&str]) -> Result<()>

Source

pub fn output_fields(&self) -> Result<Vec<String>>

Source

pub fn set_hnsw_params(&mut self, params: HnswQueryParams) -> Result<()>

Source

pub fn set_ivf_params(&mut self, params: IvfQueryParams) -> Result<()>

Source

pub fn set_flat_params(&mut self, params: FlatQueryParams) -> Result<()>

Trait Implementations§

Source§

impl Drop for VectorQuery

Source§

fn drop(&mut self)

Executes the destructor for this type. Read more
Source§

impl Send for VectorQuery

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.