pub struct SearchHighlight {
pub field: Option<String>,
pub snippet: Option<String>,
pub snippets: Option<Vec<String>>,
pub value: Option<String>,
pub values: Option<Vec<String>>,
pub indices: Option<Vec<i32>>,
pub matched_tokens: Option<Vec<Value>>,
}Fields§
§field: Option<String>§snippet: Option<String>Present only for (non-array) string fields
snippets: Option<Vec<String>>Present only for (array) string[] fields
value: Option<String>Full field value with highlighting, present only for (non-array) string fields
values: Option<Vec<String>>Full field value with highlighting, present only for (array) string[] fields
indices: Option<Vec<i32>>The indices property will be present only for string[] fields and will contain the corresponding indices of the snippets in the search field
matched_tokens: Option<Vec<Value>>Implementations§
Source§impl SearchHighlight
impl SearchHighlight
pub fn new() -> SearchHighlight
Trait Implementations§
Source§impl Clone for SearchHighlight
impl Clone for SearchHighlight
Source§fn clone(&self) -> SearchHighlight
fn clone(&self) -> SearchHighlight
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 SearchHighlight
impl Debug for SearchHighlight
Source§impl Default for SearchHighlight
impl Default for SearchHighlight
Source§fn default() -> SearchHighlight
fn default() -> SearchHighlight
Returns the “default value” for a type. Read more
Source§impl<'de> Deserialize<'de> for SearchHighlight
impl<'de> Deserialize<'de> for SearchHighlight
Source§fn deserialize<__D>(
__deserializer: __D,
) -> Result<SearchHighlight, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(
__deserializer: __D,
) -> Result<SearchHighlight, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl PartialEq for SearchHighlight
impl PartialEq for SearchHighlight
Source§fn eq(&self, other: &SearchHighlight) -> bool
fn eq(&self, other: &SearchHighlight) -> bool
Tests for
self and other values to be equal, and is used by ==.Source§impl Serialize for SearchHighlight
impl Serialize for SearchHighlight
Source§fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
Serialize this value into the given Serde serializer. Read more
impl StructuralPartialEq for SearchHighlight
Auto Trait Implementations§
impl Freeze for SearchHighlight
impl RefUnwindSafe for SearchHighlight
impl Send for SearchHighlight
impl Sync for SearchHighlight
impl Unpin for SearchHighlight
impl UnsafeUnpin for SearchHighlight
impl UnwindSafe for SearchHighlight
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