#[non_exhaustive]pub struct SearchOptions {Show 24 fields
pub collections: Option<Vec<String>>,
pub control: Option<Control>,
pub explain: Option<bool>,
pub facets: Option<HashMap<String, Facet>>,
pub fields: Option<Vec<String>>,
pub from: Option<u32>,
pub highlight: Option<Highlight>,
pub include_locations: Option<bool>,
pub query: Option<Query>,
pub score: Option<String>,
pub search_after: Option<Vec<String>>,
pub search_before: Option<Vec<String>>,
pub show_request: Option<bool>,
pub size: Option<u32>,
pub sort: Option<Vec<Sort>>,
pub knn: Option<Vec<KnnQuery>>,
pub knn_operator: Option<KnnOperator>,
pub raw: Option<HashMap<String, Value>>,
pub index_name: String,
pub scope_name: Option<String>,
pub bucket_name: Option<String>,
pub on_behalf_of: Option<OnBehalfOfInfo>,
pub endpoint: Option<String>,
pub retry_strategy: Arc<dyn RetryStrategy>,
}Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Non-exhaustive structs could have additional fields added in future. Therefore, non-exhaustive structs cannot be constructed in external crates using the traditional
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.collections: Option<Vec<String>>§control: Option<Control>§explain: Option<bool>§facets: Option<HashMap<String, Facet>>§fields: Option<Vec<String>>§from: Option<u32>§highlight: Option<Highlight>§include_locations: Option<bool>§query: Option<Query>§score: Option<String>§search_after: Option<Vec<String>>§search_before: Option<Vec<String>>§show_request: Option<bool>§size: Option<u32>§sort: Option<Vec<Sort>>§knn: Option<Vec<KnnQuery>>§knn_operator: Option<KnnOperator>§raw: Option<HashMap<String, Value>>§index_name: String§scope_name: Option<String>§bucket_name: Option<String>§on_behalf_of: Option<OnBehalfOfInfo>§endpoint: Option<String>§retry_strategy: Arc<dyn RetryStrategy>Implementations§
Source§impl SearchOptions
impl SearchOptions
pub fn new(index_name: impl Into<String>) -> Self
pub fn collections(self, collections: impl Into<Option<Vec<String>>>) -> Self
pub fn control(self, control: impl Into<Option<Control>>) -> Self
pub fn explain(self, explain: impl Into<Option<bool>>) -> Self
pub fn facets(self, facets: impl Into<Option<HashMap<String, Facet>>>) -> Self
pub fn fields(self, fields: impl Into<Option<Vec<String>>>) -> Self
pub fn from(self, from: impl Into<Option<u32>>) -> Self
pub fn highlight(self, highlight: impl Into<Option<Highlight>>) -> Self
pub fn include_locations( self, include_locations: impl Into<Option<bool>>, ) -> Self
pub fn query(self, query: impl Into<Option<Query>>) -> Self
pub fn score(self, score: impl Into<Option<String>>) -> Self
pub fn search_after(self, search_after: impl Into<Option<Vec<String>>>) -> Self
pub fn search_before( self, search_before: impl Into<Option<Vec<String>>>, ) -> Self
pub fn show_request(self, show_request: impl Into<Option<bool>>) -> Self
pub fn size(self, size: impl Into<Option<u32>>) -> Self
pub fn sort(self, sort: impl Into<Option<Vec<Sort>>>) -> Self
pub fn knn(self, knn: impl Into<Option<Vec<KnnQuery>>>) -> Self
pub fn knn_operator(self, knn_operator: impl Into<Option<KnnOperator>>) -> Self
pub fn raw(self, raw: impl Into<Option<HashMap<String, Value>>>) -> Self
pub fn scope_name(self, scope_name: impl Into<Option<String>>) -> Self
pub fn bucket_name(self, bucket_name: impl Into<Option<String>>) -> Self
pub fn on_behalf_of( self, on_behalf_of: impl Into<Option<OnBehalfOfInfo>>, ) -> Self
pub fn retry_strategy(self, retry_strategy: Arc<dyn RetryStrategy>) -> Self
pub fn endpoint(self, endpoint: impl Into<Option<String>>) -> Self
Trait Implementations§
Source§impl Clone for SearchOptions
impl Clone for SearchOptions
Source§fn clone(&self) -> SearchOptions
fn clone(&self) -> SearchOptions
Returns a duplicate of the value. Read more
1.0.0 · 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 SearchOptions
impl Debug for SearchOptions
Source§impl From<SearchOptions> for QueryOptions
impl From<SearchOptions> for QueryOptions
Source§fn from(opts: SearchOptions) -> Self
fn from(opts: SearchOptions) -> Self
Converts to this type from the input type.
Auto Trait Implementations§
impl Freeze for SearchOptions
impl !RefUnwindSafe for SearchOptions
impl Send for SearchOptions
impl Sync for SearchOptions
impl Unpin for SearchOptions
impl UnsafeUnpin for SearchOptions
impl !UnwindSafe for SearchOptions
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