Versions in this module Expand all Collapse all v1 v1.0.1 Sep 1, 2023 Changes in this version + const DefaultLimit + const DefaultPage + const MaxLimit + var ErrIntOverflowPagination = fmt.Errorf("proto: integer overflow") + var ErrInvalidLengthPagination = fmt.Errorf("proto: negative length found during unmarshaling") + var ErrUnexpectedEndOfGroupPagination = fmt.Errorf("proto: unexpected end of group") + func ParsePagination(pageReq *PageRequest) (page, limit int, err error) + type PageRequest struct + CountTotal bool + Key []byte + Limit uint64 + Offset uint64 + Reverse bool + func (*PageRequest) Descriptor() ([]byte, []int) + func (*PageRequest) ProtoMessage() + func (m *PageRequest) GetCountTotal() bool + func (m *PageRequest) GetKey() []byte + func (m *PageRequest) GetLimit() uint64 + func (m *PageRequest) GetOffset() uint64 + func (m *PageRequest) GetReverse() bool + func (m *PageRequest) Marshal() (dAtA []byte, err error) + func (m *PageRequest) MarshalTo(dAtA []byte) (int, error) + func (m *PageRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) + func (m *PageRequest) Reset() + func (m *PageRequest) Size() (n int) + func (m *PageRequest) String() string + func (m *PageRequest) Unmarshal(dAtA []byte) error + func (m *PageRequest) XXX_DiscardUnknown() + func (m *PageRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) + func (m *PageRequest) XXX_Merge(src proto.Message) + func (m *PageRequest) XXX_Size() int + func (m *PageRequest) XXX_Unmarshal(b []byte) error + type PageResponse struct + NextKey []byte + Total uint64 + func FilteredPaginate(prefixStore types.KVStore, pageRequest *PageRequest, ...) (*PageResponse, error) + func GenericFilteredPaginate(cdc codec.BinaryCodec, prefixStore types.KVStore, pageRequest *PageRequest, ...) ([]F, *PageResponse, error) + func Paginate(prefixStore types.KVStore, pageRequest *PageRequest, ...) (*PageResponse, error) + func (*PageResponse) Descriptor() ([]byte, []int) + func (*PageResponse) ProtoMessage() + func (m *PageResponse) GetNextKey() []byte + func (m *PageResponse) GetTotal() uint64 + func (m *PageResponse) Marshal() (dAtA []byte, err error) + func (m *PageResponse) MarshalTo(dAtA []byte) (int, error) + func (m *PageResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) + func (m *PageResponse) Reset() + func (m *PageResponse) Size() (n int) + func (m *PageResponse) String() string + func (m *PageResponse) Unmarshal(dAtA []byte) error + func (m *PageResponse) XXX_DiscardUnknown() + func (m *PageResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) + func (m *PageResponse) XXX_Merge(src proto.Message) + func (m *PageResponse) XXX_Size() int + func (m *PageResponse) XXX_Unmarshal(b []byte) error