Struct couch_rs::types::query::QueryParams
source · pub struct QueryParams<K: Serialize + PartialEq + Debug + Clone> {Show 22 fields
pub conflicts: Option<bool>,
pub descending: Option<bool>,
pub end_key: Option<K>,
pub end_key_doc_id: Option<String>,
pub group: Option<bool>,
pub group_level: Option<u32>,
pub include_docs: Option<bool>,
pub attachments: Option<bool>,
pub att_encoding_info: Option<bool>,
pub inclusive_end: Option<bool>,
pub key: Option<K>,
pub keys: Vec<K>,
pub limit: Option<u64>,
pub reduce: Option<bool>,
pub skip: Option<u64>,
pub sorted: Option<bool>,
pub stable: Option<bool>,
pub stale: Option<String>,
pub start_key: Option<K>,
pub start_key_doc_id: Option<String>,
pub update: Option<UpdateView>,
pub update_seq: Option<bool>,
}
Expand description
Query parameters. You can use the builder paradigm to construct these parameters easily: views.html
use couch_rs::types::query::QueryParams;
let _qp = QueryParams::default().group(true).conflicts(false).start_key("1".to_string());
Fields§
§conflicts: Option<bool>
§descending: Option<bool>
§end_key: Option<K>
§end_key_doc_id: Option<String>
§group: Option<bool>
§group_level: Option<u32>
§include_docs: Option<bool>
§attachments: Option<bool>
§att_encoding_info: Option<bool>
§inclusive_end: Option<bool>
§key: Option<K>
§keys: Vec<K>
§limit: Option<u64>
§reduce: Option<bool>
§skip: Option<u64>
§sorted: Option<bool>
§stable: Option<bool>
§stale: Option<String>
§start_key: Option<K>
§start_key_doc_id: Option<String>
§update: Option<UpdateView>
§update_seq: Option<bool>
Implementations§
source§impl<K: Serialize + DeserializeOwned + PartialEq + Debug + Clone> QueryParams<K>
impl<K: Serialize + DeserializeOwned + PartialEq + Debug + Clone> QueryParams<K>
pub fn from_keys(keys: Vec<K>) -> Self
pub fn conflicts(self, conflicts: bool) -> Self
pub fn descending(self, descending: bool) -> Self
pub fn end_key(self, end_key: K) -> Self
pub fn group(self, group: bool) -> Self
pub fn group_level(self, group_level: u32) -> Self
pub fn include_docs(self, include_docs: bool) -> Self
pub fn attachments(self, attachments: bool) -> Self
pub fn att_encoding_info(self, att_encoding_info: bool) -> Self
pub fn inclusive_end(self, inclusive_end: bool) -> Self
pub fn key(self, key: K) -> Self
pub fn keys(self, keys: Vec<K>) -> Self
pub fn limit(self, limit: u64) -> Self
pub fn reduce(self, reduce: bool) -> Self
pub fn skip(self, skip: u64) -> Self
pub fn sorted(self, sorted: bool) -> Self
pub fn stable(self, stable: bool) -> Self
pub fn start_key(self, start_key: K) -> Self
pub fn start_key_doc_id(self, start_key_doc_id: &str) -> Self
pub fn update(self, update: UpdateView) -> Self
pub fn update_seq(self, update_seq: bool) -> Self
Trait Implementations§
source§impl<K: Clone + Serialize + PartialEq + Debug + Clone> Clone for QueryParams<K>
impl<K: Clone + Serialize + PartialEq + Debug + Clone> Clone for QueryParams<K>
source§fn clone(&self) -> QueryParams<K>
fn clone(&self) -> QueryParams<K>
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<K: Serialize + DeserializeOwned + PartialEq + Debug + Clone> Default for QueryParams<K>
impl<K: Serialize + DeserializeOwned + PartialEq + Debug + Clone> Default for QueryParams<K>
source§impl<'de, K> Deserialize<'de> for QueryParams<K>
impl<'de, K> Deserialize<'de> for QueryParams<K>
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
source§impl<K: PartialEq + Serialize + PartialEq + Debug + Clone> PartialEq for QueryParams<K>
impl<K: PartialEq + Serialize + PartialEq + Debug + Clone> PartialEq for QueryParams<K>
source§fn eq(&self, other: &QueryParams<K>) -> bool
fn eq(&self, other: &QueryParams<K>) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.source§impl<K> Serialize for QueryParams<K>
impl<K> Serialize for QueryParams<K>
impl<K: Eq + Serialize + PartialEq + Debug + Clone> Eq for QueryParams<K>
impl<K: Serialize + PartialEq + Debug + Clone> StructuralPartialEq for QueryParams<K>
Auto Trait Implementations§
impl<K> Freeze for QueryParams<K>where
K: Freeze,
impl<K> RefUnwindSafe for QueryParams<K>where
K: RefUnwindSafe,
impl<K> Send for QueryParams<K>where
K: Send,
impl<K> Sync for QueryParams<K>where
K: Sync,
impl<K> Unpin for QueryParams<K>where
K: Unpin,
impl<K> UnwindSafe for QueryParams<K>where
K: UnwindSafe,
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