Struct ruarango::cursor::output::CursorMeta
source · pub struct CursorMeta<T> { /* private fields */ }
Expand description
Cursor metadata output
Implementations§
source§impl<T> CursorMeta<T>
impl<T> CursorMeta<T>
sourcepub fn result(&self) -> &Option<Vec<T>>
pub fn result(&self) -> &Option<Vec<T>>
An array of result documents (might be empty if query has no results)
sourcepub fn extra(&self) -> &Option<Extra>
pub fn extra(&self) -> &Option<Extra>
Extra information about the query result contained in its
stats sub-attribute. For data-modification queries, the extra.stats
sub-attribute will contain the number of modified documents and
the number of documents that could not be modified due to an error if
ignore_errors
query option is specified
sourcepub fn count(&self) -> &Option<usize>
pub fn count(&self) -> &Option<usize>
The total number of result documents available (only available if the query was executed with the count attribute set)
sourcepub fn cached(&self) -> &bool
pub fn cached(&self) -> &bool
A boolean flag indicating whether the query result was served from the query cache or not. If the query result is served from the query cache, the extra return attribute will not contain any stats sub-attribute and no profile sub-attribute.
Trait Implementations§
source§impl<T: Clone> Clone for CursorMeta<T>
impl<T: Clone> Clone for CursorMeta<T>
source§fn clone(&self) -> CursorMeta<T>
fn clone(&self) -> CursorMeta<T>
Returns a copy 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<T: Debug> Debug for CursorMeta<T>
impl<T: Debug> Debug for CursorMeta<T>
source§impl<'de, T> Deserialize<'de> for CursorMeta<T>where
T: Deserialize<'de>,
impl<'de, T> Deserialize<'de> for CursorMeta<T>where
T: Deserialize<'de>,
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