pub struct PageRequest { /* private fields */ }Expand description
WASM binding version for the Cosmos SDK query.PageRequest,
embedded in request messages for efficient pagination.
Implementations§
Source§impl PageRequest
impl PageRequest
pub fn new() -> Self
Sourcepub fn key(self, key: impl Into<String>) -> Self
pub fn key(self, key: impl Into<String>) -> Self
The key is a value returned in PageResponse.next_key to begin querying the next page
most efficiently. Only one of offset or key should be set.
Sourcepub fn offset(self, offset: u64) -> Self
pub fn offset(self, offset: u64) -> Self
A numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set.
Sourcepub fn limit(self, limit: u64) -> Self
pub fn limit(self, limit: u64) -> Self
Total number of results to be returned in the result page. If left empty, it will default to a value to be set by each app.
Sourcepub fn count_total(self) -> Self
pub fn count_total(self) -> Self
When set to true, indicates that the result set should include a count of the total number
of items available for pagination. count_total is only respected when offset is used.
It is ignored when key is set.
Trait Implementations§
Source§impl Clone for PageRequest
impl Clone for PageRequest
Source§fn clone(&self) -> PageRequest
fn clone(&self) -> PageRequest
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 PageRequest
impl Debug for PageRequest
Source§impl Default for PageRequest
impl Default for PageRequest
Source§fn default() -> PageRequest
fn default() -> PageRequest
Returns the “default value” for a type. Read more
Source§impl<'de> Deserialize<'de> for PageRequest
impl<'de> Deserialize<'de> for PageRequest
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 JsonSchema for PageRequest
impl JsonSchema for PageRequest
Source§fn schema_name() -> String
fn schema_name() -> String
The name of the generated JSON Schema. Read more
Source§fn schema_id() -> Cow<'static, str>
fn schema_id() -> Cow<'static, str>
Returns a string that uniquely identifies the schema produced by this type. Read more
Source§fn json_schema(generator: &mut SchemaGenerator) -> Schema
fn json_schema(generator: &mut SchemaGenerator) -> Schema
Generates a JSON Schema for this type. Read more
Source§fn is_referenceable() -> bool
fn is_referenceable() -> bool
Whether JSON Schemas generated for this type should be re-used where possible using the
$ref keyword. Read moreSource§impl PartialEq for PageRequest
impl PartialEq for PageRequest
Source§impl Serialize for PageRequest
impl Serialize for PageRequest
impl StructuralPartialEq for PageRequest
Auto Trait Implementations§
impl Freeze for PageRequest
impl RefUnwindSafe for PageRequest
impl Send for PageRequest
impl Sync for PageRequest
impl Unpin for PageRequest
impl UnwindSafe for PageRequest
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