Struct cosmos_sdk_proto::cosmos::base::query::v1beta1::PageRequest
source · pub struct PageRequest {
pub key: Vec<u8>,
pub offset: u64,
pub limit: u64,
pub count_total: bool,
pub reverse: bool,
}Expand description
PageRequest is to be embedded in gRPC request messages for efficient pagination. Ex:
message SomeRequest { Foo some_parameter = 1; PageRequest pagination = 2; }
Fields§
§key: Vec<u8>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.
offset: u64offset is 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.
limit: u64limit is the 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.
count_total: boolcount_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set.
reverse: boolreverse is set to true if results are to be returned in the descending order.
Since: cosmos-sdk 0.43
Trait Implementations§
source§impl Clone for PageRequest
impl Clone for PageRequest
source§fn clone(&self) -> PageRequest
fn clone(&self) -> PageRequest
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moresource§impl Debug for PageRequest
impl Debug for PageRequest
source§impl Default for PageRequest
impl Default for PageRequest
source§impl Message for PageRequest
impl Message for PageRequest
source§fn encoded_len(&self) -> usize
fn encoded_len(&self) -> usize
source§fn encode<B>(&self, buf: &mut B) -> Result<(), EncodeError>where
B: BufMut,
Self: Sized,
fn encode<B>(&self, buf: &mut B) -> Result<(), EncodeError>where B: BufMut, Self: Sized,
source§fn encode_to_vec(&self) -> Vec<u8, Global>where
Self: Sized,
fn encode_to_vec(&self) -> Vec<u8, Global>where Self: Sized,
source§fn encode_length_delimited<B>(&self, buf: &mut B) -> Result<(), EncodeError>where
B: BufMut,
Self: Sized,
fn encode_length_delimited<B>(&self, buf: &mut B) -> Result<(), EncodeError>where B: BufMut, Self: Sized,
source§fn encode_length_delimited_to_vec(&self) -> Vec<u8, Global>where
Self: Sized,
fn encode_length_delimited_to_vec(&self) -> Vec<u8, Global>where Self: Sized,
source§fn decode<B>(buf: B) -> Result<Self, DecodeError>where
B: Buf,
Self: Default,
fn decode<B>(buf: B) -> Result<Self, DecodeError>where B: Buf, Self: Default,
source§fn decode_length_delimited<B>(buf: B) -> Result<Self, DecodeError>where
B: Buf,
Self: Default,
fn decode_length_delimited<B>(buf: B) -> Result<Self, DecodeError>where B: Buf, Self: Default,
source§fn merge<B>(&mut self, buf: B) -> Result<(), DecodeError>where
B: Buf,
Self: Sized,
fn merge<B>(&mut self, buf: B) -> Result<(), DecodeError>where B: Buf, Self: Sized,
self. Read moresource§fn merge_length_delimited<B>(&mut self, buf: B) -> Result<(), DecodeError>where
B: Buf,
Self: Sized,
fn merge_length_delimited<B>(&mut self, buf: B) -> Result<(), DecodeError>where B: Buf, Self: Sized,
self.source§impl PartialEq<PageRequest> for PageRequest
impl PartialEq<PageRequest> for PageRequest
source§fn eq(&self, other: &PageRequest) -> bool
fn eq(&self, other: &PageRequest) -> bool
self and other values to be equal, and is used
by ==.impl StructuralPartialEq for PageRequest
Auto Trait Implementations§
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
source§impl<T> Instrument for T
impl<T> Instrument for T
source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
source§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
T in a tonic::Request