// Code generated by protoc-gen-gogo. DO NOT EDIT.
// source: settlus/settlement/v1alpha1/query.proto

package types

import (
	context "context"
	fmt "fmt"
	types "github.com/cosmos/cosmos-sdk/types"
	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"
)

// Reference imports to suppress errors if they are not otherwise used.
var _ = proto.Marshal
var _ = fmt.Errorf
var _ = math.Inf

// This is a compile-time assertion to ensure that this generated file
// is compatible with the proto package it is being compiled against.
// A compilation error at this line likely means your copy of the
// proto package needs to be updated.
const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package

// QueryParamsRequest is request type for the Query/Params RPC method.
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_c9a196576cc7b35c, []int{0}
}
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

// QueryParamsResponse is response type for the Query/Params RPC method.
type QueryParamsResponse struct {
	// params holds all the parameters of this module.
	Params Params `protobuf:"bytes,1,opt,name=params,proto3" json:"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_c9a196576cc7b35c, []int{1}
}
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 Params{}
}

// QueryGetUTXRRequest is request type for the Query/UTXR RPC method.
type QueryUTXRRRequest struct {
	TenantId  uint64 `protobuf:"varint,1,opt,name=tenant_id,json=tenantId,proto3" json:"tenant_id,omitempty"`
	RequestId string `protobuf:"bytes,2,opt,name=request_id,json=requestId,proto3" json:"request_id,omitempty"`
}

func (m *QueryUTXRRRequest) Reset()         { *m = QueryUTXRRRequest{} }
func (m *QueryUTXRRRequest) String() string { return proto.CompactTextString(m) }
func (*QueryUTXRRRequest) ProtoMessage()    {}
func (*QueryUTXRRRequest) Descriptor() ([]byte, []int) {
	return fileDescriptor_c9a196576cc7b35c, []int{2}
}
func (m *QueryUTXRRRequest) XXX_Unmarshal(b []byte) error {
	return m.Unmarshal(b)
}
func (m *QueryUTXRRRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
	if deterministic {
		return xxx_messageInfo_QueryUTXRRRequest.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 *QueryUTXRRRequest) XXX_Merge(src proto.Message) {
	xxx_messageInfo_QueryUTXRRRequest.Merge(m, src)
}
func (m *QueryUTXRRRequest) XXX_Size() int {
	return m.Size()
}
func (m *QueryUTXRRRequest) XXX_DiscardUnknown() {
	xxx_messageInfo_QueryUTXRRRequest.DiscardUnknown(m)
}

var xxx_messageInfo_QueryUTXRRRequest proto.InternalMessageInfo

func (m *QueryUTXRRRequest) GetTenantId() uint64 {
	if m != nil {
		return m.TenantId
	}
	return 0
}

func (m *QueryUTXRRRequest) GetRequestId() string {
	if m != nil {
		return m.RequestId
	}
	return ""
}

// QueryGetUTXRResponse is response type for the Query/UTXR RPC method.
type QueryUTXRResponse struct {
	Utxr UTXR `protobuf:"bytes,1,opt,name=utxr,proto3" json:"utxr"`
}

func (m *QueryUTXRResponse) Reset()         { *m = QueryUTXRResponse{} }
func (m *QueryUTXRResponse) String() string { return proto.CompactTextString(m) }
func (*QueryUTXRResponse) ProtoMessage()    {}
func (*QueryUTXRResponse) Descriptor() ([]byte, []int) {
	return fileDescriptor_c9a196576cc7b35c, []int{3}
}
func (m *QueryUTXRResponse) XXX_Unmarshal(b []byte) error {
	return m.Unmarshal(b)
}
func (m *QueryUTXRResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
	if deterministic {
		return xxx_messageInfo_QueryUTXRResponse.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 *QueryUTXRResponse) XXX_Merge(src proto.Message) {
	xxx_messageInfo_QueryUTXRResponse.Merge(m, src)
}
func (m *QueryUTXRResponse) XXX_Size() int {
	return m.Size()
}
func (m *QueryUTXRResponse) XXX_DiscardUnknown() {
	xxx_messageInfo_QueryUTXRResponse.DiscardUnknown(m)
}

var xxx_messageInfo_QueryUTXRResponse proto.InternalMessageInfo

func (m *QueryUTXRResponse) GetUtxr() UTXR {
	if m != nil {
		return m.Utxr
	}
	return UTXR{}
}

// QueryAllUTXRRequest is request type for the Query/AllUTXR RPC method.
type QueryUTXRsRequest struct {
	TenantId   uint64             `protobuf:"varint,1,opt,name=tenant_id,json=tenantId,proto3" json:"tenant_id,omitempty"`
	Pagination *query.PageRequest `protobuf:"bytes,2,opt,name=pagination,proto3" json:"pagination,omitempty"`
}

func (m *QueryUTXRsRequest) Reset()         { *m = QueryUTXRsRequest{} }
func (m *QueryUTXRsRequest) String() string { return proto.CompactTextString(m) }
func (*QueryUTXRsRequest) ProtoMessage()    {}
func (*QueryUTXRsRequest) Descriptor() ([]byte, []int) {
	return fileDescriptor_c9a196576cc7b35c, []int{4}
}
func (m *QueryUTXRsRequest) XXX_Unmarshal(b []byte) error {
	return m.Unmarshal(b)
}
func (m *QueryUTXRsRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
	if deterministic {
		return xxx_messageInfo_QueryUTXRsRequest.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 *QueryUTXRsRequest) XXX_Merge(src proto.Message) {
	xxx_messageInfo_QueryUTXRsRequest.Merge(m, src)
}
func (m *QueryUTXRsRequest) XXX_Size() int {
	return m.Size()
}
func (m *QueryUTXRsRequest) XXX_DiscardUnknown() {
	xxx_messageInfo_QueryUTXRsRequest.DiscardUnknown(m)
}

var xxx_messageInfo_QueryUTXRsRequest proto.InternalMessageInfo

func (m *QueryUTXRsRequest) GetTenantId() uint64 {
	if m != nil {
		return m.TenantId
	}
	return 0
}

func (m *QueryUTXRsRequest) GetPagination() *query.PageRequest {
	if m != nil {
		return m.Pagination
	}
	return nil
}

// QueryAllUTXRResponse is response type for the Query/UTXRAll RPC method.
type QueryUTXRsResponse struct {
	Utxrs      []UTXR              `protobuf:"bytes,1,rep,name=utxrs,proto3" json:"utxrs"`
	Pagination *query.PageResponse `protobuf:"bytes,2,opt,name=pagination,proto3" json:"pagination,omitempty"`
}

func (m *QueryUTXRsResponse) Reset()         { *m = QueryUTXRsResponse{} }
func (m *QueryUTXRsResponse) String() string { return proto.CompactTextString(m) }
func (*QueryUTXRsResponse) ProtoMessage()    {}
func (*QueryUTXRsResponse) Descriptor() ([]byte, []int) {
	return fileDescriptor_c9a196576cc7b35c, []int{5}
}
func (m *QueryUTXRsResponse) XXX_Unmarshal(b []byte) error {
	return m.Unmarshal(b)
}
func (m *QueryUTXRsResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
	if deterministic {
		return xxx_messageInfo_QueryUTXRsResponse.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 *QueryUTXRsResponse) XXX_Merge(src proto.Message) {
	xxx_messageInfo_QueryUTXRsResponse.Merge(m, src)
}
func (m *QueryUTXRsResponse) XXX_Size() int {
	return m.Size()
}
func (m *QueryUTXRsResponse) XXX_DiscardUnknown() {
	xxx_messageInfo_QueryUTXRsResponse.DiscardUnknown(m)
}

var xxx_messageInfo_QueryUTXRsResponse proto.InternalMessageInfo

func (m *QueryUTXRsResponse) GetUtxrs() []UTXR {
	if m != nil {
		return m.Utxrs
	}
	return nil
}

func (m *QueryUTXRsResponse) GetPagination() *query.PageResponse {
	if m != nil {
		return m.Pagination
	}
	return nil
}

// QueryTenantRequest is request type for the Query/Tenant RPC method.
type QueryTenantRequest struct {
	TenantId uint64 `protobuf:"varint,1,opt,name=tenant_id,json=tenantId,proto3" json:"tenant_id,omitempty"`
}

func (m *QueryTenantRequest) Reset()         { *m = QueryTenantRequest{} }
func (m *QueryTenantRequest) String() string { return proto.CompactTextString(m) }
func (*QueryTenantRequest) ProtoMessage()    {}
func (*QueryTenantRequest) Descriptor() ([]byte, []int) {
	return fileDescriptor_c9a196576cc7b35c, []int{6}
}
func (m *QueryTenantRequest) XXX_Unmarshal(b []byte) error {
	return m.Unmarshal(b)
}
func (m *QueryTenantRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
	if deterministic {
		return xxx_messageInfo_QueryTenantRequest.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 *QueryTenantRequest) XXX_Merge(src proto.Message) {
	xxx_messageInfo_QueryTenantRequest.Merge(m, src)
}
func (m *QueryTenantRequest) XXX_Size() int {
	return m.Size()
}
func (m *QueryTenantRequest) XXX_DiscardUnknown() {
	xxx_messageInfo_QueryTenantRequest.DiscardUnknown(m)
}

var xxx_messageInfo_QueryTenantRequest proto.InternalMessageInfo

func (m *QueryTenantRequest) GetTenantId() uint64 {
	if m != nil {
		return m.TenantId
	}
	return 0
}

// QueryTenantResponse is response type for the Query/Tenant RPC method.
type QueryTenantResponse struct {
	Tenant TenantWithTreasury `protobuf:"bytes,1,opt,name=tenant,proto3" json:"tenant"`
}

func (m *QueryTenantResponse) Reset()         { *m = QueryTenantResponse{} }
func (m *QueryTenantResponse) String() string { return proto.CompactTextString(m) }
func (*QueryTenantResponse) ProtoMessage()    {}
func (*QueryTenantResponse) Descriptor() ([]byte, []int) {
	return fileDescriptor_c9a196576cc7b35c, []int{7}
}
func (m *QueryTenantResponse) XXX_Unmarshal(b []byte) error {
	return m.Unmarshal(b)
}
func (m *QueryTenantResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
	if deterministic {
		return xxx_messageInfo_QueryTenantResponse.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 *QueryTenantResponse) XXX_Merge(src proto.Message) {
	xxx_messageInfo_QueryTenantResponse.Merge(m, src)
}
func (m *QueryTenantResponse) XXX_Size() int {
	return m.Size()
}
func (m *QueryTenantResponse) XXX_DiscardUnknown() {
	xxx_messageInfo_QueryTenantResponse.DiscardUnknown(m)
}

var xxx_messageInfo_QueryTenantResponse proto.InternalMessageInfo

func (m *QueryTenantResponse) GetTenant() TenantWithTreasury {
	if m != nil {
		return m.Tenant
	}
	return TenantWithTreasury{}
}

type TenantWithTreasury struct {
	Tenant   *Tenant   `protobuf:"bytes,1,opt,name=tenant,proto3" json:"tenant,omitempty"`
	Treasury *Treasury `protobuf:"bytes,2,opt,name=treasury,proto3" json:"treasury,omitempty"`
}

func (m *TenantWithTreasury) Reset()         { *m = TenantWithTreasury{} }
func (m *TenantWithTreasury) String() string { return proto.CompactTextString(m) }
func (*TenantWithTreasury) ProtoMessage()    {}
func (*TenantWithTreasury) Descriptor() ([]byte, []int) {
	return fileDescriptor_c9a196576cc7b35c, []int{8}
}
func (m *TenantWithTreasury) XXX_Unmarshal(b []byte) error {
	return m.Unmarshal(b)
}
func (m *TenantWithTreasury) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
	if deterministic {
		return xxx_messageInfo_TenantWithTreasury.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 *TenantWithTreasury) XXX_Merge(src proto.Message) {
	xxx_messageInfo_TenantWithTreasury.Merge(m, src)
}
func (m *TenantWithTreasury) XXX_Size() int {
	return m.Size()
}
func (m *TenantWithTreasury) XXX_DiscardUnknown() {
	xxx_messageInfo_TenantWithTreasury.DiscardUnknown(m)
}

var xxx_messageInfo_TenantWithTreasury proto.InternalMessageInfo

func (m *TenantWithTreasury) GetTenant() *Tenant {
	if m != nil {
		return m.Tenant
	}
	return nil
}

func (m *TenantWithTreasury) GetTreasury() *Treasury {
	if m != nil {
		return m.Treasury
	}
	return nil
}

type Treasury struct {
	Address string      `protobuf:"bytes,1,opt,name=address,proto3" json:"address,omitempty"`
	Balance *types.Coin `protobuf:"bytes,2,opt,name=balance,proto3" json:"balance,omitempty"`
}

func (m *Treasury) Reset()         { *m = Treasury{} }
func (m *Treasury) String() string { return proto.CompactTextString(m) }
func (*Treasury) ProtoMessage()    {}
func (*Treasury) Descriptor() ([]byte, []int) {
	return fileDescriptor_c9a196576cc7b35c, []int{9}
}
func (m *Treasury) XXX_Unmarshal(b []byte) error {
	return m.Unmarshal(b)
}
func (m *Treasury) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
	if deterministic {
		return xxx_messageInfo_Treasury.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 *Treasury) XXX_Merge(src proto.Message) {
	xxx_messageInfo_Treasury.Merge(m, src)
}
func (m *Treasury) XXX_Size() int {
	return m.Size()
}
func (m *Treasury) XXX_DiscardUnknown() {
	xxx_messageInfo_Treasury.DiscardUnknown(m)
}

var xxx_messageInfo_Treasury proto.InternalMessageInfo

func (m *Treasury) GetAddress() string {
	if m != nil {
		return m.Address
	}
	return ""
}

func (m *Treasury) GetBalance() *types.Coin {
	if m != nil {
		return m.Balance
	}
	return nil
}

// QueryTenantsRequest is request type for the Query/Tenants RPC method.
type QueryTenantsRequest struct {
	Pagination *query.PageRequest `protobuf:"bytes,1,opt,name=pagination,proto3" json:"pagination,omitempty"`
}

func (m *QueryTenantsRequest) Reset()         { *m = QueryTenantsRequest{} }
func (m *QueryTenantsRequest) String() string { return proto.CompactTextString(m) }
func (*QueryTenantsRequest) ProtoMessage()    {}
func (*QueryTenantsRequest) Descriptor() ([]byte, []int) {
	return fileDescriptor_c9a196576cc7b35c, []int{10}
}
func (m *QueryTenantsRequest) XXX_Unmarshal(b []byte) error {
	return m.Unmarshal(b)
}
func (m *QueryTenantsRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
	if deterministic {
		return xxx_messageInfo_QueryTenantsRequest.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 *QueryTenantsRequest) XXX_Merge(src proto.Message) {
	xxx_messageInfo_QueryTenantsRequest.Merge(m, src)
}
func (m *QueryTenantsRequest) XXX_Size() int {
	return m.Size()
}
func (m *QueryTenantsRequest) XXX_DiscardUnknown() {
	xxx_messageInfo_QueryTenantsRequest.DiscardUnknown(m)
}

var xxx_messageInfo_QueryTenantsRequest proto.InternalMessageInfo

func (m *QueryTenantsRequest) GetPagination() *query.PageRequest {
	if m != nil {
		return m.Pagination
	}
	return nil
}

// QueryTenantsResponse is response type for the Query/Tenants RPC method.
type QueryTenantsResponse struct {
	Tenants    []TenantWithTreasury `protobuf:"bytes,1,rep,name=tenants,proto3" json:"tenants"`
	Pagination *query.PageResponse  `protobuf:"bytes,2,opt,name=pagination,proto3" json:"pagination,omitempty"`
}

func (m *QueryTenantsResponse) Reset()         { *m = QueryTenantsResponse{} }
func (m *QueryTenantsResponse) String() string { return proto.CompactTextString(m) }
func (*QueryTenantsResponse) ProtoMessage()    {}
func (*QueryTenantsResponse) Descriptor() ([]byte, []int) {
	return fileDescriptor_c9a196576cc7b35c, []int{11}
}
func (m *QueryTenantsResponse) XXX_Unmarshal(b []byte) error {
	return m.Unmarshal(b)
}
func (m *QueryTenantsResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
	if deterministic {
		return xxx_messageInfo_QueryTenantsResponse.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 *QueryTenantsResponse) XXX_Merge(src proto.Message) {
	xxx_messageInfo_QueryTenantsResponse.Merge(m, src)
}
func (m *QueryTenantsResponse) XXX_Size() int {
	return m.Size()
}
func (m *QueryTenantsResponse) XXX_DiscardUnknown() {
	xxx_messageInfo_QueryTenantsResponse.DiscardUnknown(m)
}

var xxx_messageInfo_QueryTenantsResponse proto.InternalMessageInfo

func (m *QueryTenantsResponse) GetTenants() []TenantWithTreasury {
	if m != nil {
		return m.Tenants
	}
	return nil
}

func (m *QueryTenantsResponse) GetPagination() *query.PageResponse {
	if m != nil {
		return m.Pagination
	}
	return nil
}

func init() {
	proto.RegisterType((*QueryParamsRequest)(nil), "settlus.settlement.v1alpha1.QueryParamsRequest")
	proto.RegisterType((*QueryParamsResponse)(nil), "settlus.settlement.v1alpha1.QueryParamsResponse")
	proto.RegisterType((*QueryUTXRRRequest)(nil), "settlus.settlement.v1alpha1.QueryUTXRRRequest")
	proto.RegisterType((*QueryUTXRResponse)(nil), "settlus.settlement.v1alpha1.QueryUTXRResponse")
	proto.RegisterType((*QueryUTXRsRequest)(nil), "settlus.settlement.v1alpha1.QueryUTXRsRequest")
	proto.RegisterType((*QueryUTXRsResponse)(nil), "settlus.settlement.v1alpha1.QueryUTXRsResponse")
	proto.RegisterType((*QueryTenantRequest)(nil), "settlus.settlement.v1alpha1.QueryTenantRequest")
	proto.RegisterType((*QueryTenantResponse)(nil), "settlus.settlement.v1alpha1.QueryTenantResponse")
	proto.RegisterType((*TenantWithTreasury)(nil), "settlus.settlement.v1alpha1.TenantWithTreasury")
	proto.RegisterType((*Treasury)(nil), "settlus.settlement.v1alpha1.Treasury")
	proto.RegisterType((*QueryTenantsRequest)(nil), "settlus.settlement.v1alpha1.QueryTenantsRequest")
	proto.RegisterType((*QueryTenantsResponse)(nil), "settlus.settlement.v1alpha1.QueryTenantsResponse")
}

func init() {
	proto.RegisterFile("settlus/settlement/v1alpha1/query.proto", fileDescriptor_c9a196576cc7b35c)
}

var fileDescriptor_c9a196576cc7b35c = []byte{
	// 749 bytes of a gzipped FileDescriptorProto
	0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xac, 0x96, 0xcf, 0x4f, 0xd4, 0x40,
	0x14, 0xc7, 0x77, 0x70, 0xd9, 0x65, 0x87, 0x93, 0x23, 0x07, 0x5c, 0xb4, 0x62, 0x91, 0x1f, 0x11,
	0xd2, 0xa1, 0x98, 0x68, 0x14, 0x3d, 0x80, 0x51, 0xc3, 0xc1, 0x80, 0x0d, 0x46, 0x62, 0x62, 0xc8,
	0xec, 0xee, 0xa4, 0xdb, 0x64, 0xb7, 0x53, 0x3a, 0xb3, 0x04, 0x42, 0xb8, 0xf8, 0x17, 0x98, 0xe8,
	0xc1, 0x03, 0x07, 0x0f, 0x9e, 0x3c, 0x79, 0xf4, 0x4f, 0xe0, 0x48, 0xe2, 0xc5, 0x93, 0x31, 0xe0,
	0x1f, 0x62, 0x3a, 0x33, 0x2d, 0xad, 0x98, 0x6e, 0x21, 0x9e, 0xb6, 0x3b, 0x7d, 0xef, 0xfb, 0x3e,
	0xef, 0xc7, 0xbc, 0x14, 0x4e, 0x73, 0x2a, 0x44, 0xa7, 0xc7, 0xb1, 0xfc, 0xa5, 0x5d, 0xea, 0x0b,
	0xbc, 0x6d, 0x93, 0x4e, 0xd0, 0x26, 0x36, 0xde, 0xea, 0xd1, 0x70, 0xd7, 0x0a, 0x42, 0x26, 0x18,
	0x1a, 0xd3, 0x86, 0xd6, 0xa9, 0xa1, 0x15, 0x1b, 0xd6, 0x8d, 0x26, 0xe3, 0x5d, 0xc6, 0x71, 0x83,
	0x70, 0x8a, 0xb7, 0xed, 0x06, 0x15, 0xc4, 0xc6, 0x4d, 0xe6, 0xf9, 0xca, 0xb9, 0x3e, 0xe2, 0x32,
	0x97, 0xc9, 0x47, 0x1c, 0x3d, 0xe9, 0xd3, 0x6b, 0x2e, 0x63, 0x6e, 0x87, 0x62, 0x12, 0x78, 0x98,
	0xf8, 0x3e, 0x13, 0x44, 0x78, 0xcc, 0xe7, 0xfa, 0xed, 0xed, 0xb4, 0xa6, 0x24, 0x49, 0x94, 0x03,
	0xe2, 0x7a, 0xbe, 0x34, 0xd6, 0xb6, 0x73, 0x79, 0x59, 0xa4, 0x80, 0xa5, 0xb5, 0x39, 0x02, 0xd1,
	0x8b, 0x48, 0x6f, 0x8d, 0x84, 0xa4, 0xcb, 0x1d, 0xba, 0xd5, 0xa3, 0x5c, 0x98, 0x1b, 0xf0, 0x4a,
	0xe6, 0x94, 0x07, 0xcc, 0xe7, 0x14, 0x2d, 0xc1, 0x4a, 0x20, 0x4f, 0x46, 0xc1, 0x38, 0x98, 0x19,
	0x5e, 0x98, 0xb0, 0x72, 0x0a, 0x61, 0x29, 0xe7, 0xe5, 0xf2, 0xe1, 0xcf, 0x1b, 0x25, 0x47, 0x3b,
	0x9a, 0xab, 0xf0, 0xb2, 0x54, 0x7e, 0xb9, 0xbe, 0xe1, 0x38, 0x3a, 0x1c, 0x1a, 0x83, 0x35, 0x41,
	0x7d, 0xe2, 0x8b, 0x4d, 0xaf, 0x25, 0xa5, 0xcb, 0xce, 0x90, 0x3a, 0x58, 0x69, 0xa1, 0xeb, 0x10,
	0x86, 0xca, 0x2e, 0x7a, 0x3b, 0x30, 0x0e, 0x66, 0x6a, 0x4e, 0x4d, 0x9f, 0xac, 0xb4, 0xcc, 0xb5,
	0xb4, 0x60, 0x0c, 0xba, 0x08, 0xcb, 0x3d, 0xb1, 0x13, 0x6a, 0xcc, 0x9b, 0xb9, 0x98, 0x91, 0xa3,
	0x86, 0x94, 0x4e, 0xe6, 0x4e, 0x4a, 0x91, 0x17, 0x42, 0x7c, 0x0a, 0xe1, 0x69, 0x1b, 0x24, 0xe2,
	0xf0, 0xc2, 0x94, 0xa5, 0x7a, 0x66, 0x45, 0x3d, 0xb3, 0xd4, 0xf4, 0xe8, 0x9e, 0x59, 0x6b, 0xc4,
	0xa5, 0x5a, 0xd8, 0x49, 0x79, 0x9a, 0x07, 0x40, 0x77, 0x43, 0x87, 0xd6, 0xd9, 0x3c, 0x82, 0x83,
	0x11, 0x58, 0x54, 0xf5, 0x4b, 0xe7, 0x49, 0x47, 0x79, 0xa1, 0x67, 0xff, 0xa0, 0x9b, 0xee, 0x4b,
	0xa7, 0x62, 0x67, 0xf0, 0x6c, 0x4d, 0xb7, 0x2e, 0xf3, 0x2e, 0x52, 0x19, 0xb3, 0xa5, 0x07, 0x29,
	0x76, 0xd1, 0x19, 0x3d, 0x87, 0x15, 0x65, 0xa2, 0x3b, 0x84, 0x73, 0x53, 0x52, 0xce, 0xaf, 0x3c,
	0xd1, 0x5e, 0x0f, 0x29, 0xe1, 0xbd, 0x70, 0x37, 0x1e, 0x2a, 0x25, 0x62, 0x7e, 0x00, 0x10, 0x9d,
	0x35, 0x42, 0x8b, 0x7f, 0x45, 0x99, 0x28, 0x10, 0x25, 0xd6, 0x44, 0x4b, 0x70, 0x48, 0x68, 0x21,
	0x5d, 0xb3, 0xc9, 0x7c, 0x77, 0x6d, 0xec, 0x24, 0x6e, 0xe6, 0x26, 0x1c, 0x4a, 0x58, 0x46, 0x61,
	0x95, 0xb4, 0x5a, 0x21, 0xe5, 0xea, 0xee, 0xd4, 0x9c, 0xf8, 0x2f, 0xba, 0x0f, 0xab, 0x0d, 0xd2,
	0x21, 0x7e, 0x93, 0xea, 0x38, 0x57, 0x33, 0xbd, 0x89, 0xbb, 0xf2, 0x98, 0x79, 0xbe, 0x4c, 0x1b,
	0x38, 0xb1, 0xbd, 0xf9, 0x26, 0x53, 0xdd, 0x64, 0x56, 0xb3, 0xe3, 0x08, 0x2e, 0x3c, 0x8e, 0x5f,
	0x01, 0x1c, 0xc9, 0xea, 0xeb, 0xf6, 0xad, 0xc2, 0xaa, 0xaa, 0x52, 0x3c, 0x92, 0x17, 0xec, 0x5f,
	0xac, 0xf2, 0xdf, 0x46, 0x74, 0xe1, 0x5b, 0x05, 0x0e, 0x4a, 0x64, 0xf4, 0x11, 0xc0, 0x8a, 0xda,
	0x40, 0x28, 0x9f, 0xee, 0xec, 0xfa, 0xab, 0xcf, 0x17, 0x77, 0x50, 0x0c, 0xe6, 0xec, 0xdb, 0xef,
	0xbf, 0xdf, 0x0f, 0x4c, 0xa2, 0x09, 0x9c, 0xb7, 0x7d, 0xd5, 0x0e, 0x44, 0x5f, 0x00, 0x2c, 0x47,
	0xd7, 0x14, 0x59, 0xfd, 0xe3, 0xa4, 0xf7, 0x64, 0xbd, 0xa8, 0x7d, 0x4c, 0xb5, 0x2c, 0xa9, 0x1e,
	0xa2, 0x07, 0xb9, 0x54, 0xd1, 0x96, 0xc0, 0x7b, 0xc9, 0x1d, 0xde, 0xc7, 0x7b, 0xa7, 0xfb, 0x76,
	0x1f, 0x7d, 0x02, 0x70, 0x50, 0xae, 0xa3, 0xa2, 0xb4, 0x49, 0x15, 0x71, 0x61, 0x7b, 0x8d, 0x7b,
	0x57, 0xe2, 0xce, 0x23, 0xab, 0x2f, 0x2e, 0x4f, 0xf3, 0xa2, 0xcf, 0x00, 0x56, 0xd4, 0x8c, 0x15,
	0x69, 0x75, 0x66, 0x7b, 0x15, 0x69, 0x75, 0x76, 0x77, 0x99, 0xf7, 0x24, 0xa5, 0x8d, 0x70, 0x2e,
	0xa5, 0xc2, 0xcb, 0x60, 0x1e, 0x00, 0x58, 0xd5, 0x37, 0x09, 0x15, 0x0e, 0x9b, 0x54, 0xd3, 0x3e,
	0x87, 0x87, 0x26, 0x9d, 0x93, 0xa4, 0x53, 0xe8, 0x56, 0x01, 0x52, 0xbe, 0xfc, 0xe4, 0xf0, 0xd8,
	0x00, 0x47, 0xc7, 0x06, 0xf8, 0x75, 0x6c, 0x80, 0x77, 0x27, 0x46, 0xe9, 0xe8, 0xc4, 0x28, 0xfd,
	0x38, 0x31, 0x4a, 0xaf, 0x67, 0x5d, 0x4f, 0xb4, 0x7b, 0x0d, 0xab, 0xc9, 0xba, 0x89, 0x52, 0xb3,
	0x4d, 0x3c, 0x1f, 0xef, 0xa4, 0x15, 0xc5, 0x6e, 0x40, 0x79, 0xa3, 0x22, 0xbf, 0x2b, 0xee, 0xfc,
	0x09, 0x00, 0x00, 0xff, 0xff, 0x6a, 0x3c, 0x82, 0xe4, 0x4d, 0x09, 0x00, 0x00,
}

// Reference imports to suppress errors if they are not otherwise used.
var _ context.Context
var _ grpc.ClientConn

// This is a compile-time assertion to ensure that this generated file
// is compatible with the grpc package it is being compiled against.
const _ = grpc.SupportPackageIsVersion4

// QueryClient is the client API for Query service.
//
// For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.
type QueryClient interface {
	// Parameters queries the parameters of the module.
	Params(ctx context.Context, in *QueryParamsRequest, opts ...grpc.CallOption) (*QueryParamsResponse, error)
	// Queries a UTXR by tenant_id and request_id.
	UTXR(ctx context.Context, in *QueryUTXRRRequest, opts ...grpc.CallOption) (*QueryUTXRResponse, error)
	// Queries a list of TxRecord items.
	UTXRs(ctx context.Context, in *QueryUTXRsRequest, opts ...grpc.CallOption) (*QueryUTXRsResponse, error)
	// Queries a tenant by tenant_id.
	Tenant(ctx context.Context, in *QueryTenantRequest, opts ...grpc.CallOption) (*QueryTenantResponse, error)
	// Queries a all tenants.
	Tenants(ctx context.Context, in *QueryTenantsRequest, opts ...grpc.CallOption) (*QueryTenantsResponse, error)
}

type queryClient struct {
	cc grpc1.ClientConn
}

func NewQueryClient(cc grpc1.ClientConn) QueryClient {
	return &queryClient{cc}
}

func (c *queryClient) Params(ctx context.Context, in *QueryParamsRequest, opts ...grpc.CallOption) (*QueryParamsResponse, error) {
	out := new(QueryParamsResponse)
	err := c.cc.Invoke(ctx, "/settlus.settlement.v1alpha1.Query/Params", in, out, opts...)
	if err != nil {
		return nil, err
	}
	return out, nil
}

func (c *queryClient) UTXR(ctx context.Context, in *QueryUTXRRRequest, opts ...grpc.CallOption) (*QueryUTXRResponse, error) {
	out := new(QueryUTXRResponse)
	err := c.cc.Invoke(ctx, "/settlus.settlement.v1alpha1.Query/UTXR", in, out, opts...)
	if err != nil {
		return nil, err
	}
	return out, nil
}

func (c *queryClient) UTXRs(ctx context.Context, in *QueryUTXRsRequest, opts ...grpc.CallOption) (*QueryUTXRsResponse, error) {
	out := new(QueryUTXRsResponse)
	err := c.cc.Invoke(ctx, "/settlus.settlement.v1alpha1.Query/UTXRs", in, out, opts...)
	if err != nil {
		return nil, err
	}
	return out, nil
}

func (c *queryClient) Tenant(ctx context.Context, in *QueryTenantRequest, opts ...grpc.CallOption) (*QueryTenantResponse, error) {
	out := new(QueryTenantResponse)
	err := c.cc.Invoke(ctx, "/settlus.settlement.v1alpha1.Query/Tenant", in, out, opts...)
	if err != nil {
		return nil, err
	}
	return out, nil
}

func (c *queryClient) Tenants(ctx context.Context, in *QueryTenantsRequest, opts ...grpc.CallOption) (*QueryTenantsResponse, error) {
	out := new(QueryTenantsResponse)
	err := c.cc.Invoke(ctx, "/settlus.settlement.v1alpha1.Query/Tenants", in, out, opts...)
	if err != nil {
		return nil, err
	}
	return out, nil
}

// QueryServer is the server API for Query service.
type QueryServer interface {
	// Parameters queries the parameters of the module.
	Params(context.Context, *QueryParamsRequest) (*QueryParamsResponse, error)
	// Queries a UTXR by tenant_id and request_id.
	UTXR(context.Context, *QueryUTXRRRequest) (*QueryUTXRResponse, error)
	// Queries a list of TxRecord items.
	UTXRs(context.Context, *QueryUTXRsRequest) (*QueryUTXRsResponse, error)
	// Queries a tenant by tenant_id.
	Tenant(context.Context, *QueryTenantRequest) (*QueryTenantResponse, error)
	// Queries a all tenants.
	Tenants(context.Context, *QueryTenantsRequest) (*QueryTenantsResponse, error)
}

// UnimplementedQueryServer can be embedded to have forward compatible implementations.
type UnimplementedQueryServer struct {
}

func (*UnimplementedQueryServer) Params(ctx context.Context, req *QueryParamsRequest) (*QueryParamsResponse, error) {
	return nil, status.Errorf(codes.Unimplemented, "method Params not implemented")
}
func (*UnimplementedQueryServer) UTXR(ctx context.Context, req *QueryUTXRRRequest) (*QueryUTXRResponse, error) {
	return nil, status.Errorf(codes.Unimplemented, "method UTXR not implemented")
}
func (*UnimplementedQueryServer) UTXRs(ctx context.Context, req *QueryUTXRsRequest) (*QueryUTXRsResponse, error) {
	return nil, status.Errorf(codes.Unimplemented, "method UTXRs not implemented")
}
func (*UnimplementedQueryServer) Tenant(ctx context.Context, req *QueryTenantRequest) (*QueryTenantResponse, error) {
	return nil, status.Errorf(codes.Unimplemented, "method Tenant not implemented")
}
func (*UnimplementedQueryServer) Tenants(ctx context.Context, req *QueryTenantsRequest) (*QueryTenantsResponse, error) {
	return nil, status.Errorf(codes.Unimplemented, "method Tenants not implemented")
}

func RegisterQueryServer(s grpc1.Server, srv QueryServer) {
	s.RegisterService(&_Query_serviceDesc, srv)
}

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: "/settlus.settlement.v1alpha1.Query/Params",
	}
	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
		return srv.(QueryServer).Params(ctx, req.(*QueryParamsRequest))
	}
	return interceptor(ctx, in, info, handler)
}

func _Query_UTXR_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
	in := new(QueryUTXRRRequest)
	if err := dec(in); err != nil {
		return nil, err
	}
	if interceptor == nil {
		return srv.(QueryServer).UTXR(ctx, in)
	}
	info := &grpc.UnaryServerInfo{
		Server:     srv,
		FullMethod: "/settlus.settlement.v1alpha1.Query/UTXR",
	}
	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
		return srv.(QueryServer).UTXR(ctx, req.(*QueryUTXRRRequest))
	}
	return interceptor(ctx, in, info, handler)
}

func _Query_UTXRs_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
	in := new(QueryUTXRsRequest)
	if err := dec(in); err != nil {
		return nil, err
	}
	if interceptor == nil {
		return srv.(QueryServer).UTXRs(ctx, in)
	}
	info := &grpc.UnaryServerInfo{
		Server:     srv,
		FullMethod: "/settlus.settlement.v1alpha1.Query/UTXRs",
	}
	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
		return srv.(QueryServer).UTXRs(ctx, req.(*QueryUTXRsRequest))
	}
	return interceptor(ctx, in, info, handler)
}

func _Query_Tenant_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
	in := new(QueryTenantRequest)
	if err := dec(in); err != nil {
		return nil, err
	}
	if interceptor == nil {
		return srv.(QueryServer).Tenant(ctx, in)
	}
	info := &grpc.UnaryServerInfo{
		Server:     srv,
		FullMethod: "/settlus.settlement.v1alpha1.Query/Tenant",
	}
	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
		return srv.(QueryServer).Tenant(ctx, req.(*QueryTenantRequest))
	}
	return interceptor(ctx, in, info, handler)
}

func _Query_Tenants_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
	in := new(QueryTenantsRequest)
	if err := dec(in); err != nil {
		return nil, err
	}
	if interceptor == nil {
		return srv.(QueryServer).Tenants(ctx, in)
	}
	info := &grpc.UnaryServerInfo{
		Server:     srv,
		FullMethod: "/settlus.settlement.v1alpha1.Query/Tenants",
	}
	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
		return srv.(QueryServer).Tenants(ctx, req.(*QueryTenantsRequest))
	}
	return interceptor(ctx, in, info, handler)
}

var _Query_serviceDesc = grpc.ServiceDesc{
	ServiceName: "settlus.settlement.v1alpha1.Query",
	HandlerType: (*QueryServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "Params",
			Handler:    _Query_Params_Handler,
		},
		{
			MethodName: "UTXR",
			Handler:    _Query_UTXR_Handler,
		},
		{
			MethodName: "UTXRs",
			Handler:    _Query_UTXRs_Handler,
		},
		{
			MethodName: "Tenant",
			Handler:    _Query_Tenant_Handler,
		},
		{
			MethodName: "Tenants",
			Handler:    _Query_Tenants_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "settlus/settlement/v1alpha1/query.proto",
}

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
	{
		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 (m *QueryUTXRRRequest) 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 *QueryUTXRRRequest) MarshalTo(dAtA []byte) (int, error) {
	size := m.Size()
	return m.MarshalToSizedBuffer(dAtA[:size])
}

func (m *QueryUTXRRRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) {
	i := len(dAtA)
	_ = i
	var l int
	_ = l
	if len(m.RequestId) > 0 {
		i -= len(m.RequestId)
		copy(dAtA[i:], m.RequestId)
		i = encodeVarintQuery(dAtA, i, uint64(len(m.RequestId)))
		i--
		dAtA[i] = 0x12
	}
	if m.TenantId != 0 {
		i = encodeVarintQuery(dAtA, i, uint64(m.TenantId))
		i--
		dAtA[i] = 0x8
	}
	return len(dAtA) - i, nil
}

func (m *QueryUTXRResponse) 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 *QueryUTXRResponse) MarshalTo(dAtA []byte) (int, error) {
	size := m.Size()
	return m.MarshalToSizedBuffer(dAtA[:size])
}

func (m *QueryUTXRResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) {
	i := len(dAtA)
	_ = i
	var l int
	_ = l
	{
		size, err := m.Utxr.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 *QueryUTXRsRequest) 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 *QueryUTXRsRequest) MarshalTo(dAtA []byte) (int, error) {
	size := m.Size()
	return m.MarshalToSizedBuffer(dAtA[:size])
}

func (m *QueryUTXRsRequest) 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 m.TenantId != 0 {
		i = encodeVarintQuery(dAtA, i, uint64(m.TenantId))
		i--
		dAtA[i] = 0x8
	}
	return len(dAtA) - i, nil
}

func (m *QueryUTXRsResponse) 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 *QueryUTXRsResponse) MarshalTo(dAtA []byte) (int, error) {
	size := m.Size()
	return m.MarshalToSizedBuffer(dAtA[:size])
}

func (m *QueryUTXRsResponse) 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.Utxrs) > 0 {
		for iNdEx := len(m.Utxrs) - 1; iNdEx >= 0; iNdEx-- {
			{
				size, err := m.Utxrs[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 *QueryTenantRequest) 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 *QueryTenantRequest) MarshalTo(dAtA []byte) (int, error) {
	size := m.Size()
	return m.MarshalToSizedBuffer(dAtA[:size])
}

func (m *QueryTenantRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) {
	i := len(dAtA)
	_ = i
	var l int
	_ = l
	if m.TenantId != 0 {
		i = encodeVarintQuery(dAtA, i, uint64(m.TenantId))
		i--
		dAtA[i] = 0x8
	}
	return len(dAtA) - i, nil
}

func (m *QueryTenantResponse) 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 *QueryTenantResponse) MarshalTo(dAtA []byte) (int, error) {
	size := m.Size()
	return m.MarshalToSizedBuffer(dAtA[:size])
}

func (m *QueryTenantResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) {
	i := len(dAtA)
	_ = i
	var l int
	_ = l
	{
		size, err := m.Tenant.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 *TenantWithTreasury) 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 *TenantWithTreasury) MarshalTo(dAtA []byte) (int, error) {
	size := m.Size()
	return m.MarshalToSizedBuffer(dAtA[:size])
}

func (m *TenantWithTreasury) MarshalToSizedBuffer(dAtA []byte) (int, error) {
	i := len(dAtA)
	_ = i
	var l int
	_ = l
	if m.Treasury != nil {
		{
			size, err := m.Treasury.MarshalToSizedBuffer(dAtA[:i])
			if err != nil {
				return 0, err
			}
			i -= size
			i = encodeVarintQuery(dAtA, i, uint64(size))
		}
		i--
		dAtA[i] = 0x12
	}
	if m.Tenant != nil {
		{
			size, err := m.Tenant.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 *Treasury) 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 *Treasury) MarshalTo(dAtA []byte) (int, error) {
	size := m.Size()
	return m.MarshalToSizedBuffer(dAtA[:size])
}

func (m *Treasury) MarshalToSizedBuffer(dAtA []byte) (int, error) {
	i := len(dAtA)
	_ = i
	var l int
	_ = l
	if m.Balance != nil {
		{
			size, err := m.Balance.MarshalToSizedBuffer(dAtA[:i])
			if err != nil {
				return 0, err
			}
			i -= size
			i = encodeVarintQuery(dAtA, i, uint64(size))
		}
		i--
		dAtA[i] = 0x12
	}
	if len(m.Address) > 0 {
		i -= len(m.Address)
		copy(dAtA[i:], m.Address)
		i = encodeVarintQuery(dAtA, i, uint64(len(m.Address)))
		i--
		dAtA[i] = 0xa
	}
	return len(dAtA) - i, nil
}

func (m *QueryTenantsRequest) 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 *QueryTenantsRequest) MarshalTo(dAtA []byte) (int, error) {
	size := m.Size()
	return m.MarshalToSizedBuffer(dAtA[:size])
}

func (m *QueryTenantsRequest) 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 *QueryTenantsResponse) 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 *QueryTenantsResponse) MarshalTo(dAtA []byte) (int, error) {
	size := m.Size()
	return m.MarshalToSizedBuffer(dAtA[:size])
}

func (m *QueryTenantsResponse) 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.Tenants) > 0 {
		for iNdEx := len(m.Tenants) - 1; iNdEx >= 0; iNdEx-- {
			{
				size, err := m.Tenants[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 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 *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
	l = m.Params.Size()
	n += 1 + l + sovQuery(uint64(l))
	return n
}

func (m *QueryUTXRRRequest) Size() (n int) {
	if m == nil {
		return 0
	}
	var l int
	_ = l
	if m.TenantId != 0 {
		n += 1 + sovQuery(uint64(m.TenantId))
	}
	l = len(m.RequestId)
	if l > 0 {
		n += 1 + l + sovQuery(uint64(l))
	}
	return n
}

func (m *QueryUTXRResponse) Size() (n int) {
	if m == nil {
		return 0
	}
	var l int
	_ = l
	l = m.Utxr.Size()
	n += 1 + l + sovQuery(uint64(l))
	return n
}

func (m *QueryUTXRsRequest) Size() (n int) {
	if m == nil {
		return 0
	}
	var l int
	_ = l
	if m.TenantId != 0 {
		n += 1 + sovQuery(uint64(m.TenantId))
	}
	if m.Pagination != nil {
		l = m.Pagination.Size()
		n += 1 + l + sovQuery(uint64(l))
	}
	return n
}

func (m *QueryUTXRsResponse) Size() (n int) {
	if m == nil {
		return 0
	}
	var l int
	_ = l
	if len(m.Utxrs) > 0 {
		for _, e := range m.Utxrs {
			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 *QueryTenantRequest) Size() (n int) {
	if m == nil {
		return 0
	}
	var l int
	_ = l
	if m.TenantId != 0 {
		n += 1 + sovQuery(uint64(m.TenantId))
	}
	return n
}

func (m *QueryTenantResponse) Size() (n int) {
	if m == nil {
		return 0
	}
	var l int
	_ = l
	l = m.Tenant.Size()
	n += 1 + l + sovQuery(uint64(l))
	return n
}

func (m *TenantWithTreasury) Size() (n int) {
	if m == nil {
		return 0
	}
	var l int
	_ = l
	if m.Tenant != nil {
		l = m.Tenant.Size()
		n += 1 + l + sovQuery(uint64(l))
	}
	if m.Treasury != nil {
		l = m.Treasury.Size()
		n += 1 + l + sovQuery(uint64(l))
	}
	return n
}

func (m *Treasury) Size() (n int) {
	if m == nil {
		return 0
	}
	var l int
	_ = l
	l = len(m.Address)
	if l > 0 {
		n += 1 + l + sovQuery(uint64(l))
	}
	if m.Balance != nil {
		l = m.Balance.Size()
		n += 1 + l + sovQuery(uint64(l))
	}
	return n
}

func (m *QueryTenantsRequest) 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 *QueryTenantsResponse) Size() (n int) {
	if m == nil {
		return 0
	}
	var l int
	_ = l
	if len(m.Tenants) > 0 {
		for _, e := range m.Tenants {
			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 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 *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 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 (m *QueryUTXRRRequest) 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: QueryUTXRRRequest: wiretype end group for non-group")
		}
		if fieldNum <= 0 {
			return fmt.Errorf("proto: QueryUTXRRRequest: illegal tag %d (wire type %d)", fieldNum, wire)
		}
		switch fieldNum {
		case 1:
			if wireType != 0 {
				return fmt.Errorf("proto: wrong wireType = %d for field TenantId", wireType)
			}
			m.TenantId = 0
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowQuery
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				m.TenantId |= uint64(b&0x7F) << shift
				if b < 0x80 {
					break
				}
			}
		case 2:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field RequestId", 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.RequestId = 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 *QueryUTXRResponse) 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: QueryUTXRResponse: wiretype end group for non-group")
		}
		if fieldNum <= 0 {
			return fmt.Errorf("proto: QueryUTXRResponse: illegal tag %d (wire type %d)", fieldNum, wire)
		}
		switch fieldNum {
		case 1:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Utxr", 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.Utxr.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 *QueryUTXRsRequest) 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: QueryUTXRsRequest: wiretype end group for non-group")
		}
		if fieldNum <= 0 {
			return fmt.Errorf("proto: QueryUTXRsRequest: illegal tag %d (wire type %d)", fieldNum, wire)
		}
		switch fieldNum {
		case 1:
			if wireType != 0 {
				return fmt.Errorf("proto: wrong wireType = %d for field TenantId", wireType)
			}
			m.TenantId = 0
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowQuery
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				m.TenantId |= uint64(b&0x7F) << shift
				if b < 0x80 {
					break
				}
			}
		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.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 *QueryUTXRsResponse) 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: QueryUTXRsResponse: wiretype end group for non-group")
		}
		if fieldNum <= 0 {
			return fmt.Errorf("proto: QueryUTXRsResponse: illegal tag %d (wire type %d)", fieldNum, wire)
		}
		switch fieldNum {
		case 1:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Utxrs", 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.Utxrs = append(m.Utxrs, UTXR{})
			if err := m.Utxrs[len(m.Utxrs)-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 *QueryTenantRequest) 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: QueryTenantRequest: wiretype end group for non-group")
		}
		if fieldNum <= 0 {
			return fmt.Errorf("proto: QueryTenantRequest: illegal tag %d (wire type %d)", fieldNum, wire)
		}
		switch fieldNum {
		case 1:
			if wireType != 0 {
				return fmt.Errorf("proto: wrong wireType = %d for field TenantId", wireType)
			}
			m.TenantId = 0
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowQuery
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				m.TenantId |= uint64(b&0x7F) << shift
				if b < 0x80 {
					break
				}
			}
		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 *QueryTenantResponse) 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: QueryTenantResponse: wiretype end group for non-group")
		}
		if fieldNum <= 0 {
			return fmt.Errorf("proto: QueryTenantResponse: illegal tag %d (wire type %d)", fieldNum, wire)
		}
		switch fieldNum {
		case 1:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Tenant", 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.Tenant.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 *TenantWithTreasury) 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: TenantWithTreasury: wiretype end group for non-group")
		}
		if fieldNum <= 0 {
			return fmt.Errorf("proto: TenantWithTreasury: illegal tag %d (wire type %d)", fieldNum, wire)
		}
		switch fieldNum {
		case 1:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Tenant", 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.Tenant == nil {
				m.Tenant = &Tenant{}
			}
			if err := m.Tenant.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
				return err
			}
			iNdEx = postIndex
		case 2:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Treasury", 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.Treasury == nil {
				m.Treasury = &Treasury{}
			}
			if err := m.Treasury.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 *Treasury) 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: Treasury: wiretype end group for non-group")
		}
		if fieldNum <= 0 {
			return fmt.Errorf("proto: Treasury: illegal tag %d (wire type %d)", fieldNum, wire)
		}
		switch fieldNum {
		case 1:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Address", 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.Address = string(dAtA[iNdEx:postIndex])
			iNdEx = postIndex
		case 2:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Balance", 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.Balance == nil {
				m.Balance = &types.Coin{}
			}
			if err := m.Balance.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 *QueryTenantsRequest) 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: QueryTenantsRequest: wiretype end group for non-group")
		}
		if fieldNum <= 0 {
			return fmt.Errorf("proto: QueryTenantsRequest: 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 *QueryTenantsResponse) 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: QueryTenantsResponse: wiretype end group for non-group")
		}
		if fieldNum <= 0 {
			return fmt.Errorf("proto: QueryTenantsResponse: illegal tag %d (wire type %d)", fieldNum, wire)
		}
		switch fieldNum {
		case 1:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Tenants", 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.Tenants = append(m.Tenants, TenantWithTreasury{})
			if err := m.Tenants[len(m.Tenants)-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 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")
)
