// Code generated by protoc-gen-gogo. DO NOT EDIT.
// source: provenance/msgfees/v1/query.proto

package types

import (
	context "context"
	encoding_binary "encoding/binary"
	fmt "fmt"
	github_com_cosmos_cosmos_sdk_types "github.com/cosmos/cosmos-sdk/types"
	types "github.com/cosmos/cosmos-sdk/types"
	_ "github.com/cosmos/cosmos-sdk/types/tx/amino"
	_ "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

// CalculateTxFeesRequest is the request type for the Query RPC method.
// Deprecated: This query is deprecated. It is replaced by the CalculateTxFees query in the x/flatfees module.
// This query endpoint will be removed in a future release.
type CalculateTxFeesRequest struct {
	// tx_bytes is the transaction to simulate.
	TxBytes []byte `protobuf:"bytes,1,opt,name=tx_bytes,json=txBytes,proto3" json:"tx_bytes,omitempty"`
	// default_base_denom used to be the denom used for gas fees.
	// Deprecated: This field is now ignored. The fees will be in the appropriate denomination(s) automatically.
	DefaultBaseDenom string `protobuf:"bytes,2,opt,name=default_base_denom,json=defaultBaseDenom,proto3" json:"default_base_denom,omitempty"`
	// gas_adjustment is the adjustment factor to be multiplied against the estimate gas returned by the tx simulation.
	// This only affects the returned gas (since the fee is flat).
	GasAdjustment float32 `protobuf:"fixed32,3,opt,name=gas_adjustment,json=gasAdjustment,proto3" json:"gas_adjustment,omitempty"`
}

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

var xxx_messageInfo_CalculateTxFeesRequest proto.InternalMessageInfo

func (m *CalculateTxFeesRequest) GetTxBytes() []byte {
	if m != nil {
		return m.TxBytes
	}
	return nil
}

func (m *CalculateTxFeesRequest) GetDefaultBaseDenom() string {
	if m != nil {
		return m.DefaultBaseDenom
	}
	return ""
}

func (m *CalculateTxFeesRequest) GetGasAdjustment() float32 {
	if m != nil {
		return m.GasAdjustment
	}
	return 0
}

// CalculateTxFeesResponse is the response type for the Query RPC method.
// Deprecated: This query is deprecated. It is replaced by the CalculateTxFees query in the x/flatfees module.
// This query endpoint will be removed in a future release.
type CalculateTxFeesResponse struct {
	// additional_fees are the amount of coins to be for addition msg fees
	// Deprecated: This field will always be empty
	AdditionalFees github_com_cosmos_cosmos_sdk_types.Coins `protobuf:"bytes,1,rep,name=additional_fees,json=additionalFees,proto3,castrepeated=github.com/cosmos/cosmos-sdk/types.Coins" json:"additional_fees"`
	// total_fees are the total amount of fees needed for the transactions (msg fees + gas fee)
	// note: the gas fee is calculated with the floor gas price module param.
	TotalFees github_com_cosmos_cosmos_sdk_types.Coins `protobuf:"bytes,2,rep,name=total_fees,json=totalFees,proto3,castrepeated=github.com/cosmos/cosmos-sdk/types.Coins" json:"total_fees"`
	// estimated_gas is the amount of gas needed for the transaction
	EstimatedGas uint64 `protobuf:"varint,3,opt,name=estimated_gas,json=estimatedGas,proto3" json:"estimated_gas,omitempty"`
}

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

var xxx_messageInfo_CalculateTxFeesResponse proto.InternalMessageInfo

func (m *CalculateTxFeesResponse) GetAdditionalFees() github_com_cosmos_cosmos_sdk_types.Coins {
	if m != nil {
		return m.AdditionalFees
	}
	return nil
}

func (m *CalculateTxFeesResponse) GetTotalFees() github_com_cosmos_cosmos_sdk_types.Coins {
	if m != nil {
		return m.TotalFees
	}
	return nil
}

func (m *CalculateTxFeesResponse) GetEstimatedGas() uint64 {
	if m != nil {
		return m.EstimatedGas
	}
	return 0
}

func init() {
	proto.RegisterType((*CalculateTxFeesRequest)(nil), "provenance.msgfees.v1.CalculateTxFeesRequest")
	proto.RegisterType((*CalculateTxFeesResponse)(nil), "provenance.msgfees.v1.CalculateTxFeesResponse")
}

func init() { proto.RegisterFile("provenance/msgfees/v1/query.proto", fileDescriptor_73f2d53a5aebf81b) }

var fileDescriptor_73f2d53a5aebf81b = []byte{
	// 527 bytes of a gzipped FileDescriptorProto
	0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xbc, 0x53, 0x3d, 0x6f, 0x13, 0x41,
	0x10, 0xf5, 0x3a, 0x7c, 0x65, 0xc9, 0x07, 0x9c, 0xf8, 0x70, 0x22, 0x74, 0x31, 0x46, 0x48, 0x26,
	0xc2, 0xbb, 0x72, 0x42, 0x45, 0x87, 0x83, 0x42, 0x0b, 0x27, 0x2a, 0x9a, 0xd3, 0xfa, 0x6e, 0xb2,
	0x2c, 0xdc, 0xed, 0x3a, 0x9e, 0x3d, 0xcb, 0xee, 0x10, 0x15, 0xa2, 0x42, 0xa2, 0xe3, 0x07, 0x20,
	0x44, 0xe5, 0x9f, 0x91, 0x0a, 0x45, 0xa2, 0xa1, 0x02, 0x64, 0x23, 0xe5, 0x6f, 0xa0, 0x3d, 0x5f,
	0x6c, 0x0b, 0x5c, 0x50, 0xd1, 0xdc, 0xed, 0xcd, 0xbc, 0xb9, 0x79, 0xf3, 0x76, 0x1e, 0xbd, 0xd9,
	0xe9, 0x9a, 0x1e, 0x68, 0xa1, 0x23, 0xe0, 0x29, 0xca, 0x03, 0x00, 0xe4, 0xbd, 0x26, 0x3f, 0xcc,
	0xa0, 0x3b, 0x60, 0x9d, 0xae, 0xb1, 0xc6, 0xbb, 0x3a, 0x83, 0xb0, 0x02, 0xc2, 0x7a, 0xcd, 0xcd,
	0xcb, 0x22, 0x55, 0xda, 0xf0, 0xfc, 0x39, 0x41, 0x6e, 0x5e, 0x91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0xc6, 0xfd, 0xa9, 0x01, 0x73, 0xa5, 0xdb, 0xe7, 0x72, 0x03,
	0xec, 0xfe, 0x0e, 0x00, 0x00, 0xff, 0xff, 0xe6, 0x41, 0x5d, 0x54, 0xa3, 0x03, 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 {
	// CalculateTxFees simulates executing a transaction for estimating gas usage and additional fees.
	// Deprecated: This query is deprecated. It is replaced by the CalculateTxFees query in the x/flatfees module.
	// This query endpoint will be removed in a future release.
	CalculateTxFees(ctx context.Context, in *CalculateTxFeesRequest, opts ...grpc.CallOption) (*CalculateTxFeesResponse, error)
}

type queryClient struct {
	cc grpc1.ClientConn
}

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

func (c *queryClient) CalculateTxFees(ctx context.Context, in *CalculateTxFeesRequest, opts ...grpc.CallOption) (*CalculateTxFeesResponse, error) {
	out := new(CalculateTxFeesResponse)
	err := c.cc.Invoke(ctx, "/provenance.msgfees.v1.Query/CalculateTxFees", in, out, opts...)
	if err != nil {
		return nil, err
	}
	return out, nil
}

// QueryServer is the server API for Query service.
type QueryServer interface {
	// CalculateTxFees simulates executing a transaction for estimating gas usage and additional fees.
	// Deprecated: This query is deprecated. It is replaced by the CalculateTxFees query in the x/flatfees module.
	// This query endpoint will be removed in a future release.
	CalculateTxFees(context.Context, *CalculateTxFeesRequest) (*CalculateTxFeesResponse, error)
}

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

func (*UnimplementedQueryServer) CalculateTxFees(ctx context.Context, req *CalculateTxFeesRequest) (*CalculateTxFeesResponse, error) {
	return nil, status.Errorf(codes.Unimplemented, "method CalculateTxFees not implemented")
}

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

func _Query_CalculateTxFees_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
	in := new(CalculateTxFeesRequest)
	if err := dec(in); err != nil {
		return nil, err
	}
	if interceptor == nil {
		return srv.(QueryServer).CalculateTxFees(ctx, in)
	}
	info := &grpc.UnaryServerInfo{
		Server:     srv,
		FullMethod: "/provenance.msgfees.v1.Query/CalculateTxFees",
	}
	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
		return srv.(QueryServer).CalculateTxFees(ctx, req.(*CalculateTxFeesRequest))
	}
	return interceptor(ctx, in, info, handler)
}

var Query_serviceDesc = _Query_serviceDesc
var _Query_serviceDesc = grpc.ServiceDesc{
	ServiceName: "provenance.msgfees.v1.Query",
	HandlerType: (*QueryServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "CalculateTxFees",
			Handler:    _Query_CalculateTxFees_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "provenance/msgfees/v1/query.proto",
}

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

func (m *CalculateTxFeesRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) {
	i := len(dAtA)
	_ = i
	var l int
	_ = l
	if m.GasAdjustment != 0 {
		i -= 4
		encoding_binary.LittleEndian.PutUint32(dAtA[i:], uint32(math.Float32bits(float32(m.GasAdjustment))))
		i--
		dAtA[i] = 0x1d
	}
	if len(m.DefaultBaseDenom) > 0 {
		i -= len(m.DefaultBaseDenom)
		copy(dAtA[i:], m.DefaultBaseDenom)
		i = encodeVarintQuery(dAtA, i, uint64(len(m.DefaultBaseDenom)))
		i--
		dAtA[i] = 0x12
	}
	if len(m.TxBytes) > 0 {
		i -= len(m.TxBytes)
		copy(dAtA[i:], m.TxBytes)
		i = encodeVarintQuery(dAtA, i, uint64(len(m.TxBytes)))
		i--
		dAtA[i] = 0xa
	}
	return len(dAtA) - i, nil
}

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

func (m *CalculateTxFeesResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) {
	i := len(dAtA)
	_ = i
	var l int
	_ = l
	if m.EstimatedGas != 0 {
		i = encodeVarintQuery(dAtA, i, uint64(m.EstimatedGas))
		i--
		dAtA[i] = 0x18
	}
	if len(m.TotalFees) > 0 {
		for iNdEx := len(m.TotalFees) - 1; iNdEx >= 0; iNdEx-- {
			{
				size, err := m.TotalFees[iNdEx].MarshalToSizedBuffer(dAtA[:i])
				if err != nil {
					return 0, err
				}
				i -= size
				i = encodeVarintQuery(dAtA, i, uint64(size))
			}
			i--
			dAtA[i] = 0x12
		}
	}
	if len(m.AdditionalFees) > 0 {
		for iNdEx := len(m.AdditionalFees) - 1; iNdEx >= 0; iNdEx-- {
			{
				size, err := m.AdditionalFees[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 *CalculateTxFeesRequest) Size() (n int) {
	if m == nil {
		return 0
	}
	var l int
	_ = l
	l = len(m.TxBytes)
	if l > 0 {
		n += 1 + l + sovQuery(uint64(l))
	}
	l = len(m.DefaultBaseDenom)
	if l > 0 {
		n += 1 + l + sovQuery(uint64(l))
	}
	if m.GasAdjustment != 0 {
		n += 5
	}
	return n
}

func (m *CalculateTxFeesResponse) Size() (n int) {
	if m == nil {
		return 0
	}
	var l int
	_ = l
	if len(m.AdditionalFees) > 0 {
		for _, e := range m.AdditionalFees {
			l = e.Size()
			n += 1 + l + sovQuery(uint64(l))
		}
	}
	if len(m.TotalFees) > 0 {
		for _, e := range m.TotalFees {
			l = e.Size()
			n += 1 + l + sovQuery(uint64(l))
		}
	}
	if m.EstimatedGas != 0 {
		n += 1 + sovQuery(uint64(m.EstimatedGas))
	}
	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 *CalculateTxFeesRequest) 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: CalculateTxFeesRequest: wiretype end group for non-group")
		}
		if fieldNum <= 0 {
			return fmt.Errorf("proto: CalculateTxFeesRequest: illegal tag %d (wire type %d)", fieldNum, wire)
		}
		switch fieldNum {
		case 1:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field TxBytes", wireType)
			}
			var byteLen int
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowQuery
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				byteLen |= int(b&0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			if byteLen < 0 {
				return ErrInvalidLengthQuery
			}
			postIndex := iNdEx + byteLen
			if postIndex < 0 {
				return ErrInvalidLengthQuery
			}
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.TxBytes = append(m.TxBytes[:0], dAtA[iNdEx:postIndex]...)
			if m.TxBytes == nil {
				m.TxBytes = []byte{}
			}
			iNdEx = postIndex
		case 2:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field DefaultBaseDenom", 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.DefaultBaseDenom = string(dAtA[iNdEx:postIndex])
			iNdEx = postIndex
		case 3:
			if wireType != 5 {
				return fmt.Errorf("proto: wrong wireType = %d for field GasAdjustment", wireType)
			}
			var v uint32
			if (iNdEx + 4) > l {
				return io.ErrUnexpectedEOF
			}
			v = uint32(encoding_binary.LittleEndian.Uint32(dAtA[iNdEx:]))
			iNdEx += 4
			m.GasAdjustment = float32(math.Float32frombits(v))
		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 *CalculateTxFeesResponse) 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: CalculateTxFeesResponse: wiretype end group for non-group")
		}
		if fieldNum <= 0 {
			return fmt.Errorf("proto: CalculateTxFeesResponse: illegal tag %d (wire type %d)", fieldNum, wire)
		}
		switch fieldNum {
		case 1:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field AdditionalFees", 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.AdditionalFees = append(m.AdditionalFees, types.Coin{})
			if err := m.AdditionalFees[len(m.AdditionalFees)-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 TotalFees", 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.TotalFees = append(m.TotalFees, types.Coin{})
			if err := m.TotalFees[len(m.TotalFees)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
				return err
			}
			iNdEx = postIndex
		case 3:
			if wireType != 0 {
				return fmt.Errorf("proto: wrong wireType = %d for field EstimatedGas", wireType)
			}
			m.EstimatedGas = 0
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowQuery
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				m.EstimatedGas |= 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 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")
)
