package types
import (
context "context"
fmt "fmt"
query "github.com/cosmos/cosmos-sdk/types/query"
_ "github.com/cosmos/gogoproto/gogoproto"
grpc1 "github.com/cosmos/gogoproto/grpc"
proto "github.com/cosmos/gogoproto/proto"
_ "google.golang.org/genproto/googleapis/api/annotations"
grpc "google.golang.org/grpc"
codes "google.golang.org/grpc/codes"
status "google.golang.org/grpc/status"
io "io"
math "math"
math_bits "math/bits"
)
var _ = proto.Marshal
var _ = fmt.Errorf
var _ = math.Inf
const _ = proto.GoGoProtoPackageIsVersion3
type QueryClockContracts struct {
Pagination *query.PageRequest `protobuf:"bytes,1,opt,name=pagination,proto3" json:"pagination,omitempty"`
}
func (m *QueryClockContracts) Reset() { *m = QueryClockContracts{} }
func (m *QueryClockContracts) String() string { return proto.CompactTextString(m) }
func (*QueryClockContracts) ProtoMessage() {}
func (*QueryClockContracts) Descriptor() ([]byte, []int) {
return fileDescriptor_05444fcb6b1de94a, []int{0}
}
func (m *QueryClockContracts) XXX_Unmarshal(b []byte) error {
return m.Unmarshal(b)
}
func (m *QueryClockContracts) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
if deterministic {
return xxx_messageInfo_QueryClockContracts.Marshal(b, m, deterministic)
} else {
b = b[:cap(b)]
n, err := m.MarshalToSizedBuffer(b)
if err != nil {
return nil, err
}
return b[:n], nil
}
}
func (m *QueryClockContracts) XXX_Merge(src proto.Message) {
xxx_messageInfo_QueryClockContracts.Merge(m, src)
}
func (m *QueryClockContracts) XXX_Size() int {
return m.Size()
}
func (m *QueryClockContracts) XXX_DiscardUnknown() {
xxx_messageInfo_QueryClockContracts.DiscardUnknown(m)
}
var xxx_messageInfo_QueryClockContracts proto.InternalMessageInfo
func (m *QueryClockContracts) GetPagination() *query.PageRequest {
if m != nil {
return m.Pagination
}
return nil
}
type QueryClockContractsResponse struct {
ClockContracts []ClockContract `protobuf:"bytes,1,rep,name=clock_contracts,json=clockContracts,proto3" json:"clock_contracts"`
Pagination *query.PageResponse `protobuf:"bytes,2,opt,name=pagination,proto3" json:"pagination,omitempty"`
}
func (m *QueryClockContractsResponse) Reset() { *m = QueryClockContractsResponse{} }
func (m *QueryClockContractsResponse) String() string { return proto.CompactTextString(m) }
func (*QueryClockContractsResponse) ProtoMessage() {}
func (*QueryClockContractsResponse) Descriptor() ([]byte, []int) {
return fileDescriptor_05444fcb6b1de94a, []int{1}
}
func (m *QueryClockContractsResponse) XXX_Unmarshal(b []byte) error {
return m.Unmarshal(b)
}
func (m *QueryClockContractsResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
if deterministic {
return xxx_messageInfo_QueryClockContractsResponse.Marshal(b, m, deterministic)
} else {
b = b[:cap(b)]
n, err := m.MarshalToSizedBuffer(b)
if err != nil {
return nil, err
}
return b[:n], nil
}
}
func (m *QueryClockContractsResponse) XXX_Merge(src proto.Message) {
xxx_messageInfo_QueryClockContractsResponse.Merge(m, src)
}
func (m *QueryClockContractsResponse) XXX_Size() int {
return m.Size()
}
func (m *QueryClockContractsResponse) XXX_DiscardUnknown() {
xxx_messageInfo_QueryClockContractsResponse.DiscardUnknown(m)
}
var xxx_messageInfo_QueryClockContractsResponse proto.InternalMessageInfo
func (m *QueryClockContractsResponse) GetClockContracts() []ClockContract {
if m != nil {
return m.ClockContracts
}
return nil
}
func (m *QueryClockContractsResponse) GetPagination() *query.PageResponse {
if m != nil {
return m.Pagination
}
return nil
}
type QueryClockContract struct {
ContractAddress string `protobuf:"bytes,1,opt,name=contract_address,json=contractAddress,proto3" json:"contract_address,omitempty"`
}
func (m *QueryClockContract) Reset() { *m = QueryClockContract{} }
func (m *QueryClockContract) String() string { return proto.CompactTextString(m) }
func (*QueryClockContract) ProtoMessage() {}
func (*QueryClockContract) Descriptor() ([]byte, []int) {
return fileDescriptor_05444fcb6b1de94a, []int{2}
}
func (m *QueryClockContract) XXX_Unmarshal(b []byte) error {
return m.Unmarshal(b)
}
func (m *QueryClockContract) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
if deterministic {
return xxx_messageInfo_QueryClockContract.Marshal(b, m, deterministic)
} else {
b = b[:cap(b)]
n, err := m.MarshalToSizedBuffer(b)
if err != nil {
return nil, err
}
return b[:n], nil
}
}
func (m *QueryClockContract) XXX_Merge(src proto.Message) {
xxx_messageInfo_QueryClockContract.Merge(m, src)
}
func (m *QueryClockContract) XXX_Size() int {
return m.Size()
}
func (m *QueryClockContract) XXX_DiscardUnknown() {
xxx_messageInfo_QueryClockContract.DiscardUnknown(m)
}
var xxx_messageInfo_QueryClockContract proto.InternalMessageInfo
func (m *QueryClockContract) GetContractAddress() string {
if m != nil {
return m.ContractAddress
}
return ""
}
type QueryClockContractResponse struct {
ClockContract ClockContract `protobuf:"bytes,1,opt,name=clock_contract,json=clockContract,proto3" json:"clock_contract"`
}
func (m *QueryClockContractResponse) Reset() { *m = QueryClockContractResponse{} }
func (m *QueryClockContractResponse) String() string { return proto.CompactTextString(m) }
func (*QueryClockContractResponse) ProtoMessage() {}
func (*QueryClockContractResponse) Descriptor() ([]byte, []int) {
return fileDescriptor_05444fcb6b1de94a, []int{3}
}
func (m *QueryClockContractResponse) XXX_Unmarshal(b []byte) error {
return m.Unmarshal(b)
}
func (m *QueryClockContractResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
if deterministic {
return xxx_messageInfo_QueryClockContractResponse.Marshal(b, m, deterministic)
} else {
b = b[:cap(b)]
n, err := m.MarshalToSizedBuffer(b)
if err != nil {
return nil, err
}
return b[:n], nil
}
}
func (m *QueryClockContractResponse) XXX_Merge(src proto.Message) {
xxx_messageInfo_QueryClockContractResponse.Merge(m, src)
}
func (m *QueryClockContractResponse) XXX_Size() int {
return m.Size()
}
func (m *QueryClockContractResponse) XXX_DiscardUnknown() {
xxx_messageInfo_QueryClockContractResponse.DiscardUnknown(m)
}
var xxx_messageInfo_QueryClockContractResponse proto.InternalMessageInfo
func (m *QueryClockContractResponse) GetClockContract() ClockContract {
if m != nil {
return m.ClockContract
}
return ClockContract{}
}
type QueryParamsRequest struct {
}
func (m *QueryParamsRequest) Reset() { *m = QueryParamsRequest{} }
func (m *QueryParamsRequest) String() string { return proto.CompactTextString(m) }
func (*QueryParamsRequest) ProtoMessage() {}
func (*QueryParamsRequest) Descriptor() ([]byte, []int) {
return fileDescriptor_05444fcb6b1de94a, []int{4}
}
func (m *QueryParamsRequest) XXX_Unmarshal(b []byte) error {
return m.Unmarshal(b)
}
func (m *QueryParamsRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
if deterministic {
return xxx_messageInfo_QueryParamsRequest.Marshal(b, m, deterministic)
} else {
b = b[:cap(b)]
n, err := m.MarshalToSizedBuffer(b)
if err != nil {
return nil, err
}
return b[:n], nil
}
}
func (m *QueryParamsRequest) XXX_Merge(src proto.Message) {
xxx_messageInfo_QueryParamsRequest.Merge(m, src)
}
func (m *QueryParamsRequest) XXX_Size() int {
return m.Size()
}
func (m *QueryParamsRequest) XXX_DiscardUnknown() {
xxx_messageInfo_QueryParamsRequest.DiscardUnknown(m)
}
var xxx_messageInfo_QueryParamsRequest proto.InternalMessageInfo
type QueryParamsResponse struct {
Params *Params `protobuf:"bytes,1,opt,name=params,proto3" json:"params" yaml:"params"`
}
func (m *QueryParamsResponse) Reset() { *m = QueryParamsResponse{} }
func (m *QueryParamsResponse) String() string { return proto.CompactTextString(m) }
func (*QueryParamsResponse) ProtoMessage() {}
func (*QueryParamsResponse) Descriptor() ([]byte, []int) {
return fileDescriptor_05444fcb6b1de94a, []int{5}
}
func (m *QueryParamsResponse) XXX_Unmarshal(b []byte) error {
return m.Unmarshal(b)
}
func (m *QueryParamsResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
if deterministic {
return xxx_messageInfo_QueryParamsResponse.Marshal(b, m, deterministic)
} else {
b = b[:cap(b)]
n, err := m.MarshalToSizedBuffer(b)
if err != nil {
return nil, err
}
return b[:n], nil
}
}
func (m *QueryParamsResponse) XXX_Merge(src proto.Message) {
xxx_messageInfo_QueryParamsResponse.Merge(m, src)
}
func (m *QueryParamsResponse) XXX_Size() int {
return m.Size()
}
func (m *QueryParamsResponse) XXX_DiscardUnknown() {
xxx_messageInfo_QueryParamsResponse.DiscardUnknown(m)
}
var xxx_messageInfo_QueryParamsResponse proto.InternalMessageInfo
func (m *QueryParamsResponse) GetParams() *Params {
if m != nil {
return m.Params
}
return nil
}
func init() {
proto.RegisterType((*QueryClockContracts)(nil), "cyber.clock.v1.QueryClockContracts")
proto.RegisterType((*QueryClockContractsResponse)(nil), "cyber.clock.v1.QueryClockContractsResponse")
proto.RegisterType((*QueryClockContract)(nil), "cyber.clock.v1.QueryClockContract")
proto.RegisterType((*QueryClockContractResponse)(nil), "cyber.clock.v1.QueryClockContractResponse")
proto.RegisterType((*QueryParamsRequest)(nil), "cyber.clock.v1.QueryParamsRequest")
proto.RegisterType((*QueryParamsResponse)(nil), "cyber.clock.v1.QueryParamsResponse")
}
func init() { proto.RegisterFile("cyber/clock/v1/query.proto", fileDescriptor_05444fcb6b1de94a) }
var fileDescriptor_05444fcb6b1de94a = []byte{
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x8c, 0x94, 0x4d, 0x6b, 0x13, 0x41,
0x18, 0xc7, 0xb3, 0xad, 0x06, 0x9c, 0x92, 0x54, 0xc6, 0x52, 0xe2, 0x46, 0x37, 0x75, 0x0b, 0x5a,
0xab, 0xce, 0x90, 0xe8, 0xc9, 0x8b, 0x98, 0x82, 0xe2, 0xcb, 0xa1, 0xee, 0x51, 0x90, 0x32, 0xbb,
0x1d, 0xa6, 0x8b, 0xc9, 0xce, 0x66, 0x67, 0x12, 0x0c, 0xe2, 0x45, 0xf0, 0x2e, 0x88, 0x17, 0x3f,
0x87, 0x1f, 0xa2, 0xc7, 0x82, 0x17, 0x4f, 0x41, 0x12, 0x4f, 0x1e, 0xfd, 0x04, 0xb2, 0x33, 0xb3,
0xd1, 0xd9, 0xb6, 0xa6, 0xb7, 0xd9, 0xe7, 0xf5, 0xf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, 0x6f, 0x8c, 0x01, 0xf1, 0x14, 0x48,
0x03, 0xae, 0x97, 0x41, 0xf4, 0x72, 0xba, 0x4f, 0x0e, 0xa7, 0x9e, 0x73, 0x34, 0xf5, 0x9c, 0x1f,
0x53, 0xcf, 0xf9, 0x38, 0xf3, 0x2a, 0x47, 0x33, 0xaf, 0xf2, 0x7d, 0xe6, 0x55, 0x5e, 0x62, 0x16,
0xcb, 0x83, 0x61, 0x88, 0x22, 0xde, 0xd7, 0xb9, 0x11, 0x4f, 0x58, 0xce, 0x89, 0x19, 0xbf, 0xa3,
0x8b, 0xbd, 0x31, 0xe5, 0xe4, 0x38, 0xa5, 0x22, 0xac, 0xaa, 0x3f, 0xc5, 0xdd, 0x3f, 0x01, 0x00,
0x00, 0xff, 0xff, 0x2a, 0x7c, 0xaf, 0x65, 0xf1, 0x04, 0x00, 0x00,
}
var _ context.Context
var _ grpc.ClientConn
const _ = grpc.SupportPackageIsVersion4
type QueryClient interface {
ClockContracts(ctx context.Context, in *QueryClockContracts, opts ...grpc.CallOption) (*QueryClockContractsResponse, error)
ClockContract(ctx context.Context, in *QueryClockContract, opts ...grpc.CallOption) (*QueryClockContractResponse, error)
Params(ctx context.Context, in *QueryParamsRequest, opts ...grpc.CallOption) (*QueryParamsResponse, error)
}
type queryClient struct {
cc grpc1.ClientConn
}
func NewQueryClient(cc grpc1.ClientConn) QueryClient {
return &queryClient{cc}
}
func (c *queryClient) ClockContracts(ctx context.Context, in *QueryClockContracts, opts ...grpc.CallOption) (*QueryClockContractsResponse, error) {
out := new(QueryClockContractsResponse)
err := c.cc.Invoke(ctx, "/cyber.clock.v1.Query/ClockContracts", in, out, opts...)
if err != nil {
return nil, err
}
return out, nil
}
func (c *queryClient) ClockContract(ctx context.Context, in *QueryClockContract, opts ...grpc.CallOption) (*QueryClockContractResponse, error) {
out := new(QueryClockContractResponse)
err := c.cc.Invoke(ctx, "/cyber.clock.v1.Query/ClockContract", in, out, opts...)
if err != nil {
return nil, err
}
return out, nil
}
func (c *queryClient) Params(ctx context.Context, in *QueryParamsRequest, opts ...grpc.CallOption) (*QueryParamsResponse, error) {
out := new(QueryParamsResponse)
err := c.cc.Invoke(ctx, "/cyber.clock.v1.Query/Params", in, out, opts...)
if err != nil {
return nil, err
}
return out, nil
}
type QueryServer interface {
ClockContracts(context.Context, *QueryClockContracts) (*QueryClockContractsResponse, error)
ClockContract(context.Context, *QueryClockContract) (*QueryClockContractResponse, error)
Params(context.Context, *QueryParamsRequest) (*QueryParamsResponse, error)
}
type UnimplementedQueryServer struct {
}
func (*UnimplementedQueryServer) ClockContracts(ctx context.Context, req *QueryClockContracts) (*QueryClockContractsResponse, error) {
return nil, status.Errorf(codes.Unimplemented, "method ClockContracts not implemented")
}
func (*UnimplementedQueryServer) ClockContract(ctx context.Context, req *QueryClockContract) (*QueryClockContractResponse, error) {
return nil, status.Errorf(codes.Unimplemented, "method ClockContract not implemented")
}
func (*UnimplementedQueryServer) Params(ctx context.Context, req *QueryParamsRequest) (*QueryParamsResponse, error) {
return nil, status.Errorf(codes.Unimplemented, "method Params not implemented")
}
func RegisterQueryServer(s grpc1.Server, srv QueryServer) {
s.RegisterService(&_Query_serviceDesc, srv)
}
func _Query_ClockContracts_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
in := new(QueryClockContracts)
if err := dec(in); err != nil {
return nil, err
}
if interceptor == nil {
return srv.(QueryServer).ClockContracts(ctx, in)
}
info := &grpc.UnaryServerInfo{
Server: srv,
FullMethod: "/cyber.clock.v1.Query/ClockContracts",
}
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
return srv.(QueryServer).ClockContracts(ctx, req.(*QueryClockContracts))
}
return interceptor(ctx, in, info, handler)
}
func _Query_ClockContract_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
in := new(QueryClockContract)
if err := dec(in); err != nil {
return nil, err
}
if interceptor == nil {
return srv.(QueryServer).ClockContract(ctx, in)
}
info := &grpc.UnaryServerInfo{
Server: srv,
FullMethod: "/cyber.clock.v1.Query/ClockContract",
}
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
return srv.(QueryServer).ClockContract(ctx, req.(*QueryClockContract))
}
return interceptor(ctx, in, info, handler)
}
func _Query_Params_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
in := new(QueryParamsRequest)
if err := dec(in); err != nil {
return nil, err
}
if interceptor == nil {
return srv.(QueryServer).Params(ctx, in)
}
info := &grpc.UnaryServerInfo{
Server: srv,
FullMethod: "/cyber.clock.v1.Query/Params",
}
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
return srv.(QueryServer).Params(ctx, req.(*QueryParamsRequest))
}
return interceptor(ctx, in, info, handler)
}
var _Query_serviceDesc = grpc.ServiceDesc{
ServiceName: "cyber.clock.v1.Query",
HandlerType: (*QueryServer)(nil),
Methods: []grpc.MethodDesc{
{
MethodName: "ClockContracts",
Handler: _Query_ClockContracts_Handler,
},
{
MethodName: "ClockContract",
Handler: _Query_ClockContract_Handler,
},
{
MethodName: "Params",
Handler: _Query_Params_Handler,
},
},
Streams: []grpc.StreamDesc{},
Metadata: "cyber/clock/v1/query.proto",
}
func (m *QueryClockContracts) Marshal() (dAtA []byte, err error) {
size := m.Size()
dAtA = make([]byte, size)
n, err := m.MarshalToSizedBuffer(dAtA[:size])
if err != nil {
return nil, err
}
return dAtA[:n], nil
}
func (m *QueryClockContracts) MarshalTo(dAtA []byte) (int, error) {
size := m.Size()
return m.MarshalToSizedBuffer(dAtA[:size])
}
func (m *QueryClockContracts) MarshalToSizedBuffer(dAtA []byte) (int, error) {
i := len(dAtA)
_ = i
var l int
_ = l
if m.Pagination != nil {
{
size, err := m.Pagination.MarshalToSizedBuffer(dAtA[:i])
if err != nil {
return 0, err
}
i -= size
i = encodeVarintQuery(dAtA, i, uint64(size))
}
i--
dAtA[i] = 0xa
}
return len(dAtA) - i, nil
}
func (m *QueryClockContractsResponse) Marshal() (dAtA []byte, err error) {
size := m.Size()
dAtA = make([]byte, size)
n, err := m.MarshalToSizedBuffer(dAtA[:size])
if err != nil {
return nil, err
}
return dAtA[:n], nil
}
func (m *QueryClockContractsResponse) MarshalTo(dAtA []byte) (int, error) {
size := m.Size()
return m.MarshalToSizedBuffer(dAtA[:size])
}
func (m *QueryClockContractsResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) {
i := len(dAtA)
_ = i
var l int
_ = l
if m.Pagination != nil {
{
size, err := m.Pagination.MarshalToSizedBuffer(dAtA[:i])
if err != nil {
return 0, err
}
i -= size
i = encodeVarintQuery(dAtA, i, uint64(size))
}
i--
dAtA[i] = 0x12
}
if len(m.ClockContracts) > 0 {
for iNdEx := len(m.ClockContracts) - 1; iNdEx >= 0; iNdEx-- {
{
size, err := m.ClockContracts[iNdEx].MarshalToSizedBuffer(dAtA[:i])
if err != nil {
return 0, err
}
i -= size
i = encodeVarintQuery(dAtA, i, uint64(size))
}
i--
dAtA[i] = 0xa
}
}
return len(dAtA) - i, nil
}
func (m *QueryClockContract) Marshal() (dAtA []byte, err error) {
size := m.Size()
dAtA = make([]byte, size)
n, err := m.MarshalToSizedBuffer(dAtA[:size])
if err != nil {
return nil, err
}
return dAtA[:n], nil
}
func (m *QueryClockContract) MarshalTo(dAtA []byte) (int, error) {
size := m.Size()
return m.MarshalToSizedBuffer(dAtA[:size])
}
func (m *QueryClockContract) MarshalToSizedBuffer(dAtA []byte) (int, error) {
i := len(dAtA)
_ = i
var l int
_ = l
if len(m.ContractAddress) > 0 {
i -= len(m.ContractAddress)
copy(dAtA[i:], m.ContractAddress)
i = encodeVarintQuery(dAtA, i, uint64(len(m.ContractAddress)))
i--
dAtA[i] = 0xa
}
return len(dAtA) - i, nil
}
func (m *QueryClockContractResponse) Marshal() (dAtA []byte, err error) {
size := m.Size()
dAtA = make([]byte, size)
n, err := m.MarshalToSizedBuffer(dAtA[:size])
if err != nil {
return nil, err
}
return dAtA[:n], nil
}
func (m *QueryClockContractResponse) MarshalTo(dAtA []byte) (int, error) {
size := m.Size()
return m.MarshalToSizedBuffer(dAtA[:size])
}
func (m *QueryClockContractResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) {
i := len(dAtA)
_ = i
var l int
_ = l
{
size, err := m.ClockContract.MarshalToSizedBuffer(dAtA[:i])
if err != nil {
return 0, err
}
i -= size
i = encodeVarintQuery(dAtA, i, uint64(size))
}
i--
dAtA[i] = 0xa
return len(dAtA) - i, nil
}
func (m *QueryParamsRequest) Marshal() (dAtA []byte, err error) {
size := m.Size()
dAtA = make([]byte, size)
n, err := m.MarshalToSizedBuffer(dAtA[:size])
if err != nil {
return nil, err
}
return dAtA[:n], nil
}
func (m *QueryParamsRequest) MarshalTo(dAtA []byte) (int, error) {
size := m.Size()
return m.MarshalToSizedBuffer(dAtA[:size])
}
func (m *QueryParamsRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) {
i := len(dAtA)
_ = i
var l int
_ = l
return len(dAtA) - i, nil
}
func (m *QueryParamsResponse) Marshal() (dAtA []byte, err error) {
size := m.Size()
dAtA = make([]byte, size)
n, err := m.MarshalToSizedBuffer(dAtA[:size])
if err != nil {
return nil, err
}
return dAtA[:n], nil
}
func (m *QueryParamsResponse) MarshalTo(dAtA []byte) (int, error) {
size := m.Size()
return m.MarshalToSizedBuffer(dAtA[:size])
}
func (m *QueryParamsResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) {
i := len(dAtA)
_ = i
var l int
_ = l
if m.Params != nil {
{
size, err := m.Params.MarshalToSizedBuffer(dAtA[:i])
if err != nil {
return 0, err
}
i -= size
i = encodeVarintQuery(dAtA, i, uint64(size))
}
i--
dAtA[i] = 0xa
}
return len(dAtA) - i, nil
}
func encodeVarintQuery(dAtA []byte, offset int, v uint64) int {
offset -= sovQuery(v)
base := offset
for v >= 1<<7 {
dAtA[offset] = uint8(v&0x7f | 0x80)
v >>= 7
offset++
}
dAtA[offset] = uint8(v)
return base
}
func (m *QueryClockContracts) Size() (n int) {
if m == nil {
return 0
}
var l int
_ = l
if m.Pagination != nil {
l = m.Pagination.Size()
n += 1 + l + sovQuery(uint64(l))
}
return n
}
func (m *QueryClockContractsResponse) Size() (n int) {
if m == nil {
return 0
}
var l int
_ = l
if len(m.ClockContracts) > 0 {
for _, e := range m.ClockContracts {
l = e.Size()
n += 1 + l + sovQuery(uint64(l))
}
}
if m.Pagination != nil {
l = m.Pagination.Size()
n += 1 + l + sovQuery(uint64(l))
}
return n
}
func (m *QueryClockContract) Size() (n int) {
if m == nil {
return 0
}
var l int
_ = l
l = len(m.ContractAddress)
if l > 0 {
n += 1 + l + sovQuery(uint64(l))
}
return n
}
func (m *QueryClockContractResponse) Size() (n int) {
if m == nil {
return 0
}
var l int
_ = l
l = m.ClockContract.Size()
n += 1 + l + sovQuery(uint64(l))
return n
}
func (m *QueryParamsRequest) Size() (n int) {
if m == nil {
return 0
}
var l int
_ = l
return n
}
func (m *QueryParamsResponse) Size() (n int) {
if m == nil {
return 0
}
var l int
_ = l
if m.Params != nil {
l = m.Params.Size()
n += 1 + l + sovQuery(uint64(l))
}
return n
}
func sovQuery(x uint64) (n int) {
return (math_bits.Len64(x|1) + 6) / 7
}
func sozQuery(x uint64) (n int) {
return sovQuery(uint64((x << 1) ^ uint64((int64(x) >> 63))))
}
func (m *QueryClockContracts) Unmarshal(dAtA []byte) error {
l := len(dAtA)
iNdEx := 0
for iNdEx < l {
preIndex := iNdEx
var wire uint64
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return ErrIntOverflowQuery
}
if iNdEx >= l {
return io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
wire |= uint64(b&0x7F) << shift
if b < 0x80 {
break
}
}
fieldNum := int32(wire >> 3)
wireType := int(wire & 0x7)
if wireType == 4 {
return fmt.Errorf("proto: QueryClockContracts: wiretype end group for non-group")
}
if fieldNum <= 0 {
return fmt.Errorf("proto: QueryClockContracts: illegal tag %d (wire type %d)", fieldNum, wire)
}
switch fieldNum {
case 1:
if wireType != 2 {
return fmt.Errorf("proto: wrong wireType = %d for field Pagination", wireType)
}
var msglen int
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return ErrIntOverflowQuery
}
if iNdEx >= l {
return io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
msglen |= int(b&0x7F) << shift
if b < 0x80 {
break
}
}
if msglen < 0 {
return ErrInvalidLengthQuery
}
postIndex := iNdEx + msglen
if postIndex < 0 {
return ErrInvalidLengthQuery
}
if postIndex > l {
return io.ErrUnexpectedEOF
}
if m.Pagination == nil {
m.Pagination = &query.PageRequest{}
}
if err := m.Pagination.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
return err
}
iNdEx = postIndex
default:
iNdEx = preIndex
skippy, err := skipQuery(dAtA[iNdEx:])
if err != nil {
return err
}
if (skippy < 0) || (iNdEx+skippy) < 0 {
return ErrInvalidLengthQuery
}
if (iNdEx + skippy) > l {
return io.ErrUnexpectedEOF
}
iNdEx += skippy
}
}
if iNdEx > l {
return io.ErrUnexpectedEOF
}
return nil
}
func (m *QueryClockContractsResponse) Unmarshal(dAtA []byte) error {
l := len(dAtA)
iNdEx := 0
for iNdEx < l {
preIndex := iNdEx
var wire uint64
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return ErrIntOverflowQuery
}
if iNdEx >= l {
return io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
wire |= uint64(b&0x7F) << shift
if b < 0x80 {
break
}
}
fieldNum := int32(wire >> 3)
wireType := int(wire & 0x7)
if wireType == 4 {
return fmt.Errorf("proto: QueryClockContractsResponse: wiretype end group for non-group")
}
if fieldNum <= 0 {
return fmt.Errorf("proto: QueryClockContractsResponse: illegal tag %d (wire type %d)", fieldNum, wire)
}
switch fieldNum {
case 1:
if wireType != 2 {
return fmt.Errorf("proto: wrong wireType = %d for field ClockContracts", wireType)
}
var msglen int
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return ErrIntOverflowQuery
}
if iNdEx >= l {
return io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
msglen |= int(b&0x7F) << shift
if b < 0x80 {
break
}
}
if msglen < 0 {
return ErrInvalidLengthQuery
}
postIndex := iNdEx + msglen
if postIndex < 0 {
return ErrInvalidLengthQuery
}
if postIndex > l {
return io.ErrUnexpectedEOF
}
m.ClockContracts = append(m.ClockContracts, ClockContract{})
if err := m.ClockContracts[len(m.ClockContracts)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
return err
}
iNdEx = postIndex
case 2:
if wireType != 2 {
return fmt.Errorf("proto: wrong wireType = %d for field Pagination", wireType)
}
var msglen int
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return ErrIntOverflowQuery
}
if iNdEx >= l {
return io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
msglen |= int(b&0x7F) << shift
if b < 0x80 {
break
}
}
if msglen < 0 {
return ErrInvalidLengthQuery
}
postIndex := iNdEx + msglen
if postIndex < 0 {
return ErrInvalidLengthQuery
}
if postIndex > l {
return io.ErrUnexpectedEOF
}
if m.Pagination == nil {
m.Pagination = &query.PageResponse{}
}
if err := m.Pagination.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
return err
}
iNdEx = postIndex
default:
iNdEx = preIndex
skippy, err := skipQuery(dAtA[iNdEx:])
if err != nil {
return err
}
if (skippy < 0) || (iNdEx+skippy) < 0 {
return ErrInvalidLengthQuery
}
if (iNdEx + skippy) > l {
return io.ErrUnexpectedEOF
}
iNdEx += skippy
}
}
if iNdEx > l {
return io.ErrUnexpectedEOF
}
return nil
}
func (m *QueryClockContract) Unmarshal(dAtA []byte) error {
l := len(dAtA)
iNdEx := 0
for iNdEx < l {
preIndex := iNdEx
var wire uint64
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return ErrIntOverflowQuery
}
if iNdEx >= l {
return io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
wire |= uint64(b&0x7F) << shift
if b < 0x80 {
break
}
}
fieldNum := int32(wire >> 3)
wireType := int(wire & 0x7)
if wireType == 4 {
return fmt.Errorf("proto: QueryClockContract: wiretype end group for non-group")
}
if fieldNum <= 0 {
return fmt.Errorf("proto: QueryClockContract: illegal tag %d (wire type %d)", fieldNum, wire)
}
switch fieldNum {
case 1:
if wireType != 2 {
return fmt.Errorf("proto: wrong wireType = %d for field ContractAddress", wireType)
}
var stringLen uint64
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return ErrIntOverflowQuery
}
if iNdEx >= l {
return io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
stringLen |= uint64(b&0x7F) << shift
if b < 0x80 {
break
}
}
intStringLen := int(stringLen)
if intStringLen < 0 {
return ErrInvalidLengthQuery
}
postIndex := iNdEx + intStringLen
if postIndex < 0 {
return ErrInvalidLengthQuery
}
if postIndex > l {
return io.ErrUnexpectedEOF
}
m.ContractAddress = string(dAtA[iNdEx:postIndex])
iNdEx = postIndex
default:
iNdEx = preIndex
skippy, err := skipQuery(dAtA[iNdEx:])
if err != nil {
return err
}
if (skippy < 0) || (iNdEx+skippy) < 0 {
return ErrInvalidLengthQuery
}
if (iNdEx + skippy) > l {
return io.ErrUnexpectedEOF
}
iNdEx += skippy
}
}
if iNdEx > l {
return io.ErrUnexpectedEOF
}
return nil
}
func (m *QueryClockContractResponse) Unmarshal(dAtA []byte) error {
l := len(dAtA)
iNdEx := 0
for iNdEx < l {
preIndex := iNdEx
var wire uint64
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return ErrIntOverflowQuery
}
if iNdEx >= l {
return io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
wire |= uint64(b&0x7F) << shift
if b < 0x80 {
break
}
}
fieldNum := int32(wire >> 3)
wireType := int(wire & 0x7)
if wireType == 4 {
return fmt.Errorf("proto: QueryClockContractResponse: wiretype end group for non-group")
}
if fieldNum <= 0 {
return fmt.Errorf("proto: QueryClockContractResponse: illegal tag %d (wire type %d)", fieldNum, wire)
}
switch fieldNum {
case 1:
if wireType != 2 {
return fmt.Errorf("proto: wrong wireType = %d for field ClockContract", wireType)
}
var msglen int
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return ErrIntOverflowQuery
}
if iNdEx >= l {
return io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
msglen |= int(b&0x7F) << shift
if b < 0x80 {
break
}
}
if msglen < 0 {
return ErrInvalidLengthQuery
}
postIndex := iNdEx + msglen
if postIndex < 0 {
return ErrInvalidLengthQuery
}
if postIndex > l {
return io.ErrUnexpectedEOF
}
if err := m.ClockContract.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
return err
}
iNdEx = postIndex
default:
iNdEx = preIndex
skippy, err := skipQuery(dAtA[iNdEx:])
if err != nil {
return err
}
if (skippy < 0) || (iNdEx+skippy) < 0 {
return ErrInvalidLengthQuery
}
if (iNdEx + skippy) > l {
return io.ErrUnexpectedEOF
}
iNdEx += skippy
}
}
if iNdEx > l {
return io.ErrUnexpectedEOF
}
return nil
}
func (m *QueryParamsRequest) Unmarshal(dAtA []byte) error {
l := len(dAtA)
iNdEx := 0
for iNdEx < l {
preIndex := iNdEx
var wire uint64
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return ErrIntOverflowQuery
}
if iNdEx >= l {
return io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
wire |= uint64(b&0x7F) << shift
if b < 0x80 {
break
}
}
fieldNum := int32(wire >> 3)
wireType := int(wire & 0x7)
if wireType == 4 {
return fmt.Errorf("proto: QueryParamsRequest: wiretype end group for non-group")
}
if fieldNum <= 0 {
return fmt.Errorf("proto: QueryParamsRequest: illegal tag %d (wire type %d)", fieldNum, wire)
}
switch fieldNum {
default:
iNdEx = preIndex
skippy, err := skipQuery(dAtA[iNdEx:])
if err != nil {
return err
}
if (skippy < 0) || (iNdEx+skippy) < 0 {
return ErrInvalidLengthQuery
}
if (iNdEx + skippy) > l {
return io.ErrUnexpectedEOF
}
iNdEx += skippy
}
}
if iNdEx > l {
return io.ErrUnexpectedEOF
}
return nil
}
func (m *QueryParamsResponse) Unmarshal(dAtA []byte) error {
l := len(dAtA)
iNdEx := 0
for iNdEx < l {
preIndex := iNdEx
var wire uint64
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return ErrIntOverflowQuery
}
if iNdEx >= l {
return io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
wire |= uint64(b&0x7F) << shift
if b < 0x80 {
break
}
}
fieldNum := int32(wire >> 3)
wireType := int(wire & 0x7)
if wireType == 4 {
return fmt.Errorf("proto: QueryParamsResponse: wiretype end group for non-group")
}
if fieldNum <= 0 {
return fmt.Errorf("proto: QueryParamsResponse: illegal tag %d (wire type %d)", fieldNum, wire)
}
switch fieldNum {
case 1:
if wireType != 2 {
return fmt.Errorf("proto: wrong wireType = %d for field Params", wireType)
}
var msglen int
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return ErrIntOverflowQuery
}
if iNdEx >= l {
return io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
msglen |= int(b&0x7F) << shift
if b < 0x80 {
break
}
}
if msglen < 0 {
return ErrInvalidLengthQuery
}
postIndex := iNdEx + msglen
if postIndex < 0 {
return ErrInvalidLengthQuery
}
if postIndex > l {
return io.ErrUnexpectedEOF
}
if m.Params == nil {
m.Params = &Params{}
}
if err := m.Params.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
return err
}
iNdEx = postIndex
default:
iNdEx = preIndex
skippy, err := skipQuery(dAtA[iNdEx:])
if err != nil {
return err
}
if (skippy < 0) || (iNdEx+skippy) < 0 {
return ErrInvalidLengthQuery
}
if (iNdEx + skippy) > l {
return io.ErrUnexpectedEOF
}
iNdEx += skippy
}
}
if iNdEx > l {
return io.ErrUnexpectedEOF
}
return nil
}
func skipQuery(dAtA []byte) (n int, err error) {
l := len(dAtA)
iNdEx := 0
depth := 0
for iNdEx < l {
var wire uint64
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return 0, ErrIntOverflowQuery
}
if iNdEx >= l {
return 0, io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
wire |= (uint64(b) & 0x7F) << shift
if b < 0x80 {
break
}
}
wireType := int(wire & 0x7)
switch wireType {
case 0:
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return 0, ErrIntOverflowQuery
}
if iNdEx >= l {
return 0, io.ErrUnexpectedEOF
}
iNdEx++
if dAtA[iNdEx-1] < 0x80 {
break
}
}
case 1:
iNdEx += 8
case 2:
var length int
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return 0, ErrIntOverflowQuery
}
if iNdEx >= l {
return 0, io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
length |= (int(b) & 0x7F) << shift
if b < 0x80 {
break
}
}
if length < 0 {
return 0, ErrInvalidLengthQuery
}
iNdEx += length
case 3:
depth++
case 4:
if depth == 0 {
return 0, ErrUnexpectedEndOfGroupQuery
}
depth--
case 5:
iNdEx += 4
default:
return 0, fmt.Errorf("proto: illegal wireType %d", wireType)
}
if iNdEx < 0 {
return 0, ErrInvalidLengthQuery
}
if depth == 0 {
return iNdEx, nil
}
}
return 0, io.ErrUnexpectedEOF
}
var (
ErrInvalidLengthQuery = fmt.Errorf("proto: negative length found during unmarshaling")
ErrIntOverflowQuery = fmt.Errorf("proto: integer overflow")
ErrUnexpectedEndOfGroupQuery = fmt.Errorf("proto: unexpected end of group")
)