types

package
v8.0.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 22, 2024 License: Apache-2.0 Imports: 43 Imported by: 30

Documentation

Overview

Package types is a reverse proxy.

It translates gRPC into RESTful JSON APIs.

Index

Constants

View Source
const (
	ModuleName = "ratelimit"

	// StoreKey defines the primary module store key
	StoreKey = ModuleName

	// RouterKey is the message route for slashing
	RouterKey = ModuleName

	// QuerierRoute defines the module's query routing key
	QuerierRoute = ModuleName
)
View Source
const (
	TypeMsgAddRateLimit    = "AddRateLimit"
	TypeMsgUpdateRateLimit = "UpdateRateLimit"
	TypeMsgRemoveRateLimit = "RemoveRateLimit"
	TypeMsgResetRateLimit  = "ResetRateLimit"
)

Variables

View Source
var (
	ErrRateLimitAlreadyExists = errorsmod.Register(ModuleName, 1,
		"ratelimit key duplicated")
	ErrRateLimitNotFound = errorsmod.Register(ModuleName, 2,
		"rate limit not found")
	ErrZeroChannelValue = errorsmod.Register(ModuleName, 3,
		"channel value is zero")
	ErrQuotaExceeded = errorsmod.Register(ModuleName, 4,
		"quota exceeded")
	ErrInvalidClientState = errorsmod.Register(ModuleName, 5,
		"unable to determine client state from channelId")
	ErrChannelNotFound = errorsmod.Register(ModuleName, 6,
		"channel does not exist")
	ErrDenomIsBlacklisted = errorsmod.Register(ModuleName, 7,
		"denom is blacklisted",
	)
)

x/ratelimit module sentinel errors

View Source
var (
	EventTransferDenied = "transfer_denied"

	EventRateLimitExceeded = "rate_limit_exceeded"
	EventBlacklistedDenom  = "blacklisted_denom"

	AttributeKeyReason  = "reason"
	AttributeKeyModule  = "module"
	AttributeKeyAction  = "action"
	AttributeKeyDenom   = "denom"
	AttributeKeyChannel = "channel"
	AttributeKeyAmount  = "amount"
	AttributeKeyError   = "error"
)
View Source
var (
	ErrInvalidLengthGenesis        = fmt.Errorf("proto: negative length found during unmarshaling")
	ErrIntOverflowGenesis          = fmt.Errorf("proto: integer overflow")
	ErrUnexpectedEndOfGroupGenesis = fmt.Errorf("proto: unexpected end of group")
)
View Source
var (
	PathKeyPrefix             = KeyPrefix("path")
	RateLimitKeyPrefix        = KeyPrefix("rate-limit")
	PendingSendPacketPrefix   = KeyPrefix("pending-send-packet")
	DenomBlacklistKeyPrefix   = KeyPrefix("denom-blacklist")
	AddressWhitelistKeyPrefix = KeyPrefix("address-blacklist")
	HourEpochKey              = KeyPrefix("hour-epoch")

	PendingSendPacketChannelLength int = 16
)
View Source
var (
	ErrInvalidLengthParams        = fmt.Errorf("proto: negative length found during unmarshaling")
	ErrIntOverflowParams          = fmt.Errorf("proto: integer overflow")
	ErrUnexpectedEndOfGroupParams = fmt.Errorf("proto: unexpected end of group")
)
View Source
var (
	ErrInvalidLengthQuery        = fmt.Errorf("proto: negative length found during unmarshaling")
	ErrIntOverflowQuery          = fmt.Errorf("proto: integer overflow")
	ErrUnexpectedEndOfGroupQuery = fmt.Errorf("proto: unexpected end of group")
)
View Source
var (
	ErrInvalidLengthRatelimit        = fmt.Errorf("proto: negative length found during unmarshaling")
	ErrIntOverflowRatelimit          = fmt.Errorf("proto: integer overflow")
	ErrUnexpectedEndOfGroupRatelimit = fmt.Errorf("proto: unexpected end of group")
)
View Source
var (
	ErrInvalidLengthTx        = fmt.Errorf("proto: negative length found during unmarshaling")
	ErrIntOverflowTx          = fmt.Errorf("proto: integer overflow")
	ErrUnexpectedEndOfGroupTx = fmt.Errorf("proto: unexpected end of group")
)
View Source
var (
	ModuleCdc = codec.NewAminoCodec(amino)
)
View Source
var PacketDirection_name = map[int32]string{
	0: "PACKET_SEND",
	1: "PACKET_RECV",
}
View Source
var PacketDirection_value = map[string]int32{
	"PACKET_SEND": 0,
	"PACKET_RECV": 1,
}

Functions

func GetAddressWhitelistKey

func GetAddressWhitelistKey(sender, receiver string) []byte

Get the whitelist path key from a sender and receiver address

func GetPendingSendPacketKey

func GetPendingSendPacketKey(channelId string, sequenceNumber uint64) []byte

Get the pending send packet key from the channel ID and sequence number The channel ID must be fixed length to allow for extracting the underlying values from a key

func GetRateLimitItemKey

func GetRateLimitItemKey(denom string, channelId string) []byte

Get the rate limit byte key built from the denom and channelId

func KeyPrefix

func KeyPrefix(p string) []byte

func ParamKeyTable

func ParamKeyTable() paramtypes.KeyTable

ParamKeyTable the param key table for launch module

func ParsePendingPacketId

func ParsePendingPacketId(pendingPacketId string) (channelId string, sequence uint64, err error)

Splits a pending send packet of the form {channelId}/{sequenceNumber} into the channel Id and sequence number respectively

func RegisterInterfaces

func RegisterInterfaces(registry cdctypes.InterfaceRegistry)

func RegisterLegacyAminoCodec

func RegisterLegacyAminoCodec(cdc *codec.LegacyAmino)

func RegisterMsgServer

func RegisterMsgServer(s grpc1.Server, srv MsgServer)

func RegisterQueryHandler

func RegisterQueryHandler(ctx context.Context, mux *runtime.ServeMux, conn *grpc.ClientConn) error

RegisterQueryHandler registers the http handlers for service Query to "mux". The handlers forward requests to the grpc endpoint over "conn".

func RegisterQueryHandlerClient

func RegisterQueryHandlerClient(ctx context.Context, mux *runtime.ServeMux, client QueryClient) error

RegisterQueryHandlerClient registers the http handlers for service Query to "mux". The handlers forward requests to the grpc endpoint over the given implementation of "QueryClient". Note: the gRPC framework executes interceptors within the gRPC handler. If the passed in "QueryClient" doesn't go through the normal gRPC flow (creating a gRPC client etc.) then it will be up to the passed in "QueryClient" to call the correct interceptors.

func RegisterQueryHandlerFromEndpoint

func RegisterQueryHandlerFromEndpoint(ctx context.Context, mux *runtime.ServeMux, endpoint string, opts []grpc.DialOption) (err error)

RegisterQueryHandlerFromEndpoint is same as RegisterQueryHandler but automatically dials to "endpoint" and closes the connection when "ctx" gets done.

func RegisterQueryHandlerServer

func RegisterQueryHandlerServer(ctx context.Context, mux *runtime.ServeMux, server QueryServer) error

RegisterQueryHandlerServer registers the http handlers for service Query to "mux". UnaryRPC :call QueryServer directly. StreamingRPC :currently unsupported pending https://github.com/grpc/grpc-go/issues/906. Note that using this registration option will cause many gRPC library features to stop working. Consider using RegisterQueryHandlerFromEndpoint instead.

func RegisterQueryServer

func RegisterQueryServer(s grpc1.Server, srv QueryServer)

Types

type BankKeeper

type BankKeeper interface {
	GetSupply(ctx context.Context, denom string) sdk.Coin
}

BankKeeper defines the banking contract that must be fulfilled when creating a x/ratelimit keeper.

type ChannelKeeper

type ChannelKeeper interface {
	GetChannel(ctx sdk.Context, portID string, channelID string) (channeltypes.Channel, bool)
	GetChannelClientState(ctx sdk.Context, portID string, channelID string) (string, ibcexported.ClientState, error)
}

ChannelKeeper defines the channel contract that must be fulfilled when creating a x/ratelimit keeper.

type Flow

type Flow struct {
	// Inflow defines the total amount of inbound transfers for the given
	// rate limit in the current window
	Inflow cosmossdk_io_math.Int `protobuf:"bytes,1,opt,name=inflow,proto3,customtype=cosmossdk.io/math.Int" json:"inflow"`
	// Outflow defines the total amount of outbound transfers for the given
	// rate limit in the current window
	Outflow cosmossdk_io_math.Int `protobuf:"bytes,2,opt,name=outflow,proto3,customtype=cosmossdk.io/math.Int" json:"outflow"`
	// ChannelValue stores the total supply of the denom at the start of
	// the rate limit. This is used as the denominator when checking
	// the rate limit threshold
	// The ChannelValue is fixed for the duration of the rate limit window
	ChannelValue cosmossdk_io_math.Int `protobuf:"bytes,3,opt,name=channel_value,json=channelValue,proto3,customtype=cosmossdk.io/math.Int" json:"channel_value"`
}

func NewFlow

func NewFlow(channelValue sdkmath.Int) Flow

Initializes a new flow from the channel value

func (*Flow) AddInflow

func (f *Flow) AddInflow(amount sdkmath.Int, quota Quota) error

Adds an amount to the rate limit's flow after an incoming packet was received Returns an error if the new inflow will cause the rate limit to exceed its quota

func (*Flow) AddOutflow

func (f *Flow) AddOutflow(amount sdkmath.Int, quota Quota) error

Adds an amount to the rate limit's flow after a packet was sent Returns an error if the new outflow will cause the rate limit to exceed its quota

func (*Flow) Descriptor

func (*Flow) Descriptor() ([]byte, []int)

func (*Flow) Marshal

func (m *Flow) Marshal() (dAtA []byte, err error)

func (*Flow) MarshalTo

func (m *Flow) MarshalTo(dAtA []byte) (int, error)

func (*Flow) MarshalToSizedBuffer

func (m *Flow) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*Flow) ProtoMessage

func (*Flow) ProtoMessage()

func (*Flow) Reset

func (m *Flow) Reset()

func (*Flow) Size

func (m *Flow) Size() (n int)

func (*Flow) String

func (m *Flow) String() string

func (*Flow) Unmarshal

func (m *Flow) Unmarshal(dAtA []byte) error

func (*Flow) XXX_DiscardUnknown

func (m *Flow) XXX_DiscardUnknown()

func (*Flow) XXX_Marshal

func (m *Flow) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*Flow) XXX_Merge

func (m *Flow) XXX_Merge(src proto.Message)

func (*Flow) XXX_Size

func (m *Flow) XXX_Size() int

func (*Flow) XXX_Unmarshal

func (m *Flow) XXX_Unmarshal(b []byte) error

type GenesisState

type GenesisState struct {
	Params                           Params                   `protobuf:"bytes,1,opt,name=params,proto3" json:"params" yaml:"params"`
	RateLimits                       []RateLimit              `protobuf:"bytes,2,rep,name=rate_limits,json=rateLimits,proto3" json:"rate_limits" yaml:"rate_limits"`
	WhitelistedAddressPairs          []WhitelistedAddressPair `` /* 155-byte string literal not displayed */
	BlacklistedDenoms                []string                 `protobuf:"bytes,4,rep,name=blacklisted_denoms,json=blacklistedDenoms,proto3" json:"blacklisted_denoms,omitempty"`
	PendingSendPacketSequenceNumbers []string                 `` /* 163-byte string literal not displayed */
	HourEpoch                        HourEpoch                `protobuf:"bytes,6,opt,name=hour_epoch,json=hourEpoch,proto3" json:"hour_epoch" yaml:"hour_epoch"`
}

GenesisState defines the ratelimit module's genesis state.

func DefaultGenesis

func DefaultGenesis() *GenesisState

DefaultGenesis returns the default Capability genesis state

func (*GenesisState) Descriptor

func (*GenesisState) Descriptor() ([]byte, []int)

func (*GenesisState) GetBlacklistedDenoms

func (m *GenesisState) GetBlacklistedDenoms() []string

func (*GenesisState) GetHourEpoch

func (m *GenesisState) GetHourEpoch() HourEpoch

func (*GenesisState) GetParams

func (m *GenesisState) GetParams() Params

func (*GenesisState) GetPendingSendPacketSequenceNumbers

func (m *GenesisState) GetPendingSendPacketSequenceNumbers() []string

func (*GenesisState) GetRateLimits

func (m *GenesisState) GetRateLimits() []RateLimit

func (*GenesisState) GetWhitelistedAddressPairs

func (m *GenesisState) GetWhitelistedAddressPairs() []WhitelistedAddressPair

func (*GenesisState) Marshal

func (m *GenesisState) Marshal() (dAtA []byte, err error)

func (*GenesisState) MarshalTo

func (m *GenesisState) MarshalTo(dAtA []byte) (int, error)

func (*GenesisState) MarshalToSizedBuffer

func (m *GenesisState) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*GenesisState) ProtoMessage

func (*GenesisState) ProtoMessage()

func (*GenesisState) Reset

func (m *GenesisState) Reset()

func (*GenesisState) Size

func (m *GenesisState) Size() (n int)

func (*GenesisState) String

func (m *GenesisState) String() string

func (*GenesisState) Unmarshal

func (m *GenesisState) Unmarshal(dAtA []byte) error

func (GenesisState) Validate

func (gs GenesisState) Validate() error

Validate performs basic genesis state validation returning an error upon any failure.

func (*GenesisState) XXX_DiscardUnknown

func (m *GenesisState) XXX_DiscardUnknown()

func (*GenesisState) XXX_Marshal

func (m *GenesisState) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*GenesisState) XXX_Merge

func (m *GenesisState) XXX_Merge(src proto.Message)

func (*GenesisState) XXX_Size

func (m *GenesisState) XXX_Size() int

func (*GenesisState) XXX_Unmarshal

func (m *GenesisState) XXX_Unmarshal(b []byte) error

type HourEpoch

type HourEpoch struct {
	EpochNumber      uint64        `protobuf:"varint,1,opt,name=epoch_number,json=epochNumber,proto3" json:"epoch_number,omitempty"`
	Duration         time.Duration `protobuf:"bytes,2,opt,name=duration,proto3,stdduration" json:"duration,omitempty"`
	EpochStartTime   time.Time     `protobuf:"bytes,3,opt,name=epoch_start_time,json=epochStartTime,proto3,stdtime" json:"epoch_start_time"`
	EpochStartHeight int64         `protobuf:"varint,4,opt,name=epoch_start_height,json=epochStartHeight,proto3" json:"epoch_start_height,omitempty"`
}

func (*HourEpoch) Descriptor

func (*HourEpoch) Descriptor() ([]byte, []int)

func (*HourEpoch) GetDuration

func (m *HourEpoch) GetDuration() time.Duration

func (*HourEpoch) GetEpochNumber

func (m *HourEpoch) GetEpochNumber() uint64

func (*HourEpoch) GetEpochStartHeight

func (m *HourEpoch) GetEpochStartHeight() int64

func (*HourEpoch) GetEpochStartTime

func (m *HourEpoch) GetEpochStartTime() time.Time

func (*HourEpoch) Marshal

func (m *HourEpoch) Marshal() (dAtA []byte, err error)

func (*HourEpoch) MarshalTo

func (m *HourEpoch) MarshalTo(dAtA []byte) (int, error)

func (*HourEpoch) MarshalToSizedBuffer

func (m *HourEpoch) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*HourEpoch) ProtoMessage

func (*HourEpoch) ProtoMessage()

func (*HourEpoch) Reset

func (m *HourEpoch) Reset()

func (*HourEpoch) Size

func (m *HourEpoch) Size() (n int)

func (*HourEpoch) String

func (m *HourEpoch) String() string

func (*HourEpoch) Unmarshal

func (m *HourEpoch) Unmarshal(dAtA []byte) error

func (*HourEpoch) XXX_DiscardUnknown

func (m *HourEpoch) XXX_DiscardUnknown()

func (*HourEpoch) XXX_Marshal

func (m *HourEpoch) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*HourEpoch) XXX_Merge

func (m *HourEpoch) XXX_Merge(src proto.Message)

func (*HourEpoch) XXX_Size

func (m *HourEpoch) XXX_Size() int

func (*HourEpoch) XXX_Unmarshal

func (m *HourEpoch) XXX_Unmarshal(b []byte) error

type ICS4Wrapper

type ICS4Wrapper interface {
	WriteAcknowledgement(ctx sdk.Context, chanCap *capabilitytypes.Capability, packet ibcexported.PacketI, acknowledgement ibcexported.Acknowledgement) error
	SendPacket(
		ctx sdk.Context,
		chanCap *capabilitytypes.Capability,
		sourcePort string,
		sourceChannel string,
		timeoutHeight clienttypes.Height,
		timeoutTimestamp uint64,
		data []byte,
	) (sequence uint64, err error)
	GetAppVersion(ctx sdk.Context, portID, channelID string) (string, bool)
}

ICS4Wrapper defines the expected ICS4Wrapper for middleware

type MsgAddRateLimit

type MsgAddRateLimit struct {
	// Authority defines the x/gov module account
	Authority string `protobuf:"bytes,1,opt,name=authority,proto3" json:"authority,omitempty"`
	// Denom for the rate limit, as it appears on the rate limited chain
	// When rate limiting a non-native token, this will be an ibc denom
	Denom string `protobuf:"bytes,2,opt,name=denom,proto3" json:"denom,omitempty"`
	// ChannelId for the rate limit, on the side of the rate limited chain
	ChannelId string `protobuf:"bytes,3,opt,name=channel_id,json=channelId,proto3" json:"channel_id,omitempty"`
	// MaxPercentSend defines the threshold for outflows
	// The threshold is defined as a percentage (e.g. 10 indicates 10%)
	MaxPercentSend cosmossdk_io_math.Int `` /* 128-byte string literal not displayed */
	// MaxPercentSend defines the threshold for inflows
	// The threshold is defined as a percentage (e.g. 10 indicates 10%)
	MaxPercentRecv cosmossdk_io_math.Int `` /* 128-byte string literal not displayed */
	// DurationHours specifies the number of hours before the rate limit
	// is reset (e.g. 24 indicates that the rate limit is reset each day)
	DurationHours uint64 `protobuf:"varint,6,opt,name=duration_hours,json=durationHours,proto3" json:"duration_hours,omitempty"`
}

Gov tx to add a new rate limit

func NewMsgAddRateLimit

func NewMsgAddRateLimit(denom, channelId string, maxPercentSend sdkmath.Int, maxPercentRecv sdkmath.Int, durationHours uint64) *MsgAddRateLimit

func (*MsgAddRateLimit) Descriptor

func (*MsgAddRateLimit) Descriptor() ([]byte, []int)

func (*MsgAddRateLimit) GetAuthority

func (m *MsgAddRateLimit) GetAuthority() string

func (*MsgAddRateLimit) GetChannelId

func (m *MsgAddRateLimit) GetChannelId() string

func (*MsgAddRateLimit) GetDenom

func (m *MsgAddRateLimit) GetDenom() string

func (*MsgAddRateLimit) GetDurationHours

func (m *MsgAddRateLimit) GetDurationHours() uint64

func (*MsgAddRateLimit) GetSignBytes

func (msg *MsgAddRateLimit) GetSignBytes() []byte

func (*MsgAddRateLimit) GetSigners

func (msg *MsgAddRateLimit) GetSigners() []sdk.AccAddress

func (*MsgAddRateLimit) Marshal

func (m *MsgAddRateLimit) Marshal() (dAtA []byte, err error)

func (*MsgAddRateLimit) MarshalTo

func (m *MsgAddRateLimit) MarshalTo(dAtA []byte) (int, error)

func (*MsgAddRateLimit) MarshalToSizedBuffer

func (m *MsgAddRateLimit) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*MsgAddRateLimit) ProtoMessage

func (*MsgAddRateLimit) ProtoMessage()

func (*MsgAddRateLimit) Reset

func (m *MsgAddRateLimit) Reset()

func (MsgAddRateLimit) Route

func (msg MsgAddRateLimit) Route() string

func (*MsgAddRateLimit) Size

func (m *MsgAddRateLimit) Size() (n int)

func (*MsgAddRateLimit) String

func (m *MsgAddRateLimit) String() string

func (MsgAddRateLimit) Type

func (msg MsgAddRateLimit) Type() string

func (*MsgAddRateLimit) Unmarshal

func (m *MsgAddRateLimit) Unmarshal(dAtA []byte) error

func (*MsgAddRateLimit) ValidateBasic

func (msg *MsgAddRateLimit) ValidateBasic() error

func (*MsgAddRateLimit) XXX_DiscardUnknown

func (m *MsgAddRateLimit) XXX_DiscardUnknown()

func (*MsgAddRateLimit) XXX_Marshal

func (m *MsgAddRateLimit) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*MsgAddRateLimit) XXX_Merge

func (m *MsgAddRateLimit) XXX_Merge(src proto.Message)

func (*MsgAddRateLimit) XXX_Size

func (m *MsgAddRateLimit) XXX_Size() int

func (*MsgAddRateLimit) XXX_Unmarshal

func (m *MsgAddRateLimit) XXX_Unmarshal(b []byte) error

type MsgAddRateLimitResponse

type MsgAddRateLimitResponse struct {
}

func (*MsgAddRateLimitResponse) Descriptor

func (*MsgAddRateLimitResponse) Descriptor() ([]byte, []int)

func (*MsgAddRateLimitResponse) Marshal

func (m *MsgAddRateLimitResponse) Marshal() (dAtA []byte, err error)

func (*MsgAddRateLimitResponse) MarshalTo

func (m *MsgAddRateLimitResponse) MarshalTo(dAtA []byte) (int, error)

func (*MsgAddRateLimitResponse) MarshalToSizedBuffer

func (m *MsgAddRateLimitResponse) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*MsgAddRateLimitResponse) ProtoMessage

func (*MsgAddRateLimitResponse) ProtoMessage()

func (*MsgAddRateLimitResponse) Reset

func (m *MsgAddRateLimitResponse) Reset()

func (*MsgAddRateLimitResponse) Size

func (m *MsgAddRateLimitResponse) Size() (n int)

func (*MsgAddRateLimitResponse) String

func (m *MsgAddRateLimitResponse) String() string

func (*MsgAddRateLimitResponse) Unmarshal

func (m *MsgAddRateLimitResponse) Unmarshal(dAtA []byte) error

func (*MsgAddRateLimitResponse) XXX_DiscardUnknown

func (m *MsgAddRateLimitResponse) XXX_DiscardUnknown()

func (*MsgAddRateLimitResponse) XXX_Marshal

func (m *MsgAddRateLimitResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*MsgAddRateLimitResponse) XXX_Merge

func (m *MsgAddRateLimitResponse) XXX_Merge(src proto.Message)

func (*MsgAddRateLimitResponse) XXX_Size

func (m *MsgAddRateLimitResponse) XXX_Size() int

func (*MsgAddRateLimitResponse) XXX_Unmarshal

func (m *MsgAddRateLimitResponse) XXX_Unmarshal(b []byte) error

type MsgClient

type MsgClient interface {
	// Gov tx to add a new rate limit
	AddRateLimit(ctx context.Context, in *MsgAddRateLimit, opts ...grpc.CallOption) (*MsgAddRateLimitResponse, error)
	// Gov tx to update an existing rate limit
	UpdateRateLimit(ctx context.Context, in *MsgUpdateRateLimit, opts ...grpc.CallOption) (*MsgUpdateRateLimitResponse, error)
	// Gov tx to remove a rate limit
	RemoveRateLimit(ctx context.Context, in *MsgRemoveRateLimit, opts ...grpc.CallOption) (*MsgRemoveRateLimitResponse, error)
	// Gov tx to reset the flow on a rate limit
	ResetRateLimit(ctx context.Context, in *MsgResetRateLimit, opts ...grpc.CallOption) (*MsgResetRateLimitResponse, error)
}

MsgClient is the client API for Msg service.

For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.

func NewMsgClient

func NewMsgClient(cc grpc1.ClientConn) MsgClient

type MsgRemoveRateLimit

type MsgRemoveRateLimit struct {
	// Authority defines the x/gov module account
	Authority string `protobuf:"bytes,1,opt,name=authority,proto3" json:"authority,omitempty"`
	// Denom for the rate limit, as it appears on the rate limited chain
	// When rate limiting a non-native token, this will be an ibc denom
	Denom string `protobuf:"bytes,2,opt,name=denom,proto3" json:"denom,omitempty"`
	// ChannelId for the rate limit, on the side of the rate limited chain
	ChannelId string `protobuf:"bytes,3,opt,name=channel_id,json=channelId,proto3" json:"channel_id,omitempty"`
}

Gov tx to remove a rate limit

func NewMsgRemoveRateLimit

func NewMsgRemoveRateLimit(denom, channelId string) *MsgRemoveRateLimit

func (*MsgRemoveRateLimit) Descriptor

func (*MsgRemoveRateLimit) Descriptor() ([]byte, []int)

func (*MsgRemoveRateLimit) GetAuthority

func (m *MsgRemoveRateLimit) GetAuthority() string

func (*MsgRemoveRateLimit) GetChannelId

func (m *MsgRemoveRateLimit) GetChannelId() string

func (*MsgRemoveRateLimit) GetDenom

func (m *MsgRemoveRateLimit) GetDenom() string

func (*MsgRemoveRateLimit) GetSignBytes

func (msg *MsgRemoveRateLimit) GetSignBytes() []byte

func (*MsgRemoveRateLimit) GetSigners

func (msg *MsgRemoveRateLimit) GetSigners() []sdk.AccAddress

func (*MsgRemoveRateLimit) Marshal

func (m *MsgRemoveRateLimit) Marshal() (dAtA []byte, err error)

func (*MsgRemoveRateLimit) MarshalTo

func (m *MsgRemoveRateLimit) MarshalTo(dAtA []byte) (int, error)

func (*MsgRemoveRateLimit) MarshalToSizedBuffer

func (m *MsgRemoveRateLimit) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*MsgRemoveRateLimit) ProtoMessage

func (*MsgRemoveRateLimit) ProtoMessage()

func (*MsgRemoveRateLimit) Reset

func (m *MsgRemoveRateLimit) Reset()

func (MsgRemoveRateLimit) Route

func (msg MsgRemoveRateLimit) Route() string

func (*MsgRemoveRateLimit) Size

func (m *MsgRemoveRateLimit) Size() (n int)

func (*MsgRemoveRateLimit) String

func (m *MsgRemoveRateLimit) String() string

func (MsgRemoveRateLimit) Type

func (msg MsgRemoveRateLimit) Type() string

func (*MsgRemoveRateLimit) Unmarshal

func (m *MsgRemoveRateLimit) Unmarshal(dAtA []byte) error

func (*MsgRemoveRateLimit) ValidateBasic

func (msg *MsgRemoveRateLimit) ValidateBasic() error

func (*MsgRemoveRateLimit) XXX_DiscardUnknown

func (m *MsgRemoveRateLimit) XXX_DiscardUnknown()

func (*MsgRemoveRateLimit) XXX_Marshal

func (m *MsgRemoveRateLimit) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*MsgRemoveRateLimit) XXX_Merge

func (m *MsgRemoveRateLimit) XXX_Merge(src proto.Message)

func (*MsgRemoveRateLimit) XXX_Size

func (m *MsgRemoveRateLimit) XXX_Size() int

func (*MsgRemoveRateLimit) XXX_Unmarshal

func (m *MsgRemoveRateLimit) XXX_Unmarshal(b []byte) error

type MsgRemoveRateLimitResponse

type MsgRemoveRateLimitResponse struct {
}

func (*MsgRemoveRateLimitResponse) Descriptor

func (*MsgRemoveRateLimitResponse) Descriptor() ([]byte, []int)

func (*MsgRemoveRateLimitResponse) Marshal

func (m *MsgRemoveRateLimitResponse) Marshal() (dAtA []byte, err error)

func (*MsgRemoveRateLimitResponse) MarshalTo

func (m *MsgRemoveRateLimitResponse) MarshalTo(dAtA []byte) (int, error)

func (*MsgRemoveRateLimitResponse) MarshalToSizedBuffer

func (m *MsgRemoveRateLimitResponse) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*MsgRemoveRateLimitResponse) ProtoMessage

func (*MsgRemoveRateLimitResponse) ProtoMessage()

func (*MsgRemoveRateLimitResponse) Reset

func (m *MsgRemoveRateLimitResponse) Reset()

func (*MsgRemoveRateLimitResponse) Size

func (m *MsgRemoveRateLimitResponse) Size() (n int)

func (*MsgRemoveRateLimitResponse) String

func (m *MsgRemoveRateLimitResponse) String() string

func (*MsgRemoveRateLimitResponse) Unmarshal

func (m *MsgRemoveRateLimitResponse) Unmarshal(dAtA []byte) error

func (*MsgRemoveRateLimitResponse) XXX_DiscardUnknown

func (m *MsgRemoveRateLimitResponse) XXX_DiscardUnknown()

func (*MsgRemoveRateLimitResponse) XXX_Marshal

func (m *MsgRemoveRateLimitResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*MsgRemoveRateLimitResponse) XXX_Merge

func (m *MsgRemoveRateLimitResponse) XXX_Merge(src proto.Message)

func (*MsgRemoveRateLimitResponse) XXX_Size

func (m *MsgRemoveRateLimitResponse) XXX_Size() int

func (*MsgRemoveRateLimitResponse) XXX_Unmarshal

func (m *MsgRemoveRateLimitResponse) XXX_Unmarshal(b []byte) error

type MsgResetRateLimit

type MsgResetRateLimit struct {
	// Authority defines the x/gov module account
	Authority string `protobuf:"bytes,1,opt,name=authority,proto3" json:"authority,omitempty"`
	// Denom for the rate limit, as it appears on the rate limited chain
	// When rate limiting a non-native token, this will be an ibc denom
	Denom string `protobuf:"bytes,2,opt,name=denom,proto3" json:"denom,omitempty"`
	// ChannelId for the rate limit, on the side of the rate limited chain
	ChannelId string `protobuf:"bytes,3,opt,name=channel_id,json=channelId,proto3" json:"channel_id,omitempty"`
}

Gov tx to reset the flow on a rate limit

func NewMsgResetRateLimit

func NewMsgResetRateLimit(denom, channelId string) *MsgResetRateLimit

func (*MsgResetRateLimit) Descriptor

func (*MsgResetRateLimit) Descriptor() ([]byte, []int)

func (*MsgResetRateLimit) GetAuthority

func (m *MsgResetRateLimit) GetAuthority() string

func (*MsgResetRateLimit) GetChannelId

func (m *MsgResetRateLimit) GetChannelId() string

func (*MsgResetRateLimit) GetDenom

func (m *MsgResetRateLimit) GetDenom() string

func (*MsgResetRateLimit) GetSignBytes

func (msg *MsgResetRateLimit) GetSignBytes() []byte

func (*MsgResetRateLimit) GetSigners

func (msg *MsgResetRateLimit) GetSigners() []sdk.AccAddress

func (*MsgResetRateLimit) Marshal

func (m *MsgResetRateLimit) Marshal() (dAtA []byte, err error)

func (*MsgResetRateLimit) MarshalTo

func (m *MsgResetRateLimit) MarshalTo(dAtA []byte) (int, error)

func (*MsgResetRateLimit) MarshalToSizedBuffer

func (m *MsgResetRateLimit) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*MsgResetRateLimit) ProtoMessage

func (*MsgResetRateLimit) ProtoMessage()

func (*MsgResetRateLimit) Reset

func (m *MsgResetRateLimit) Reset()

func (MsgResetRateLimit) Route

func (msg MsgResetRateLimit) Route() string

func (*MsgResetRateLimit) Size

func (m *MsgResetRateLimit) Size() (n int)

func (*MsgResetRateLimit) String

func (m *MsgResetRateLimit) String() string

func (MsgResetRateLimit) Type

func (msg MsgResetRateLimit) Type() string

func (*MsgResetRateLimit) Unmarshal

func (m *MsgResetRateLimit) Unmarshal(dAtA []byte) error

func (*MsgResetRateLimit) ValidateBasic

func (msg *MsgResetRateLimit) ValidateBasic() error

func (*MsgResetRateLimit) XXX_DiscardUnknown

func (m *MsgResetRateLimit) XXX_DiscardUnknown()

func (*MsgResetRateLimit) XXX_Marshal

func (m *MsgResetRateLimit) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*MsgResetRateLimit) XXX_Merge

func (m *MsgResetRateLimit) XXX_Merge(src proto.Message)

func (*MsgResetRateLimit) XXX_Size

func (m *MsgResetRateLimit) XXX_Size() int

func (*MsgResetRateLimit) XXX_Unmarshal

func (m *MsgResetRateLimit) XXX_Unmarshal(b []byte) error

type MsgResetRateLimitResponse

type MsgResetRateLimitResponse struct {
}

func (*MsgResetRateLimitResponse) Descriptor

func (*MsgResetRateLimitResponse) Descriptor() ([]byte, []int)

func (*MsgResetRateLimitResponse) Marshal

func (m *MsgResetRateLimitResponse) Marshal() (dAtA []byte, err error)

func (*MsgResetRateLimitResponse) MarshalTo

func (m *MsgResetRateLimitResponse) MarshalTo(dAtA []byte) (int, error)

func (*MsgResetRateLimitResponse) MarshalToSizedBuffer

func (m *MsgResetRateLimitResponse) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*MsgResetRateLimitResponse) ProtoMessage

func (*MsgResetRateLimitResponse) ProtoMessage()

func (*MsgResetRateLimitResponse) Reset

func (m *MsgResetRateLimitResponse) Reset()

func (*MsgResetRateLimitResponse) Size

func (m *MsgResetRateLimitResponse) Size() (n int)

func (*MsgResetRateLimitResponse) String

func (m *MsgResetRateLimitResponse) String() string

func (*MsgResetRateLimitResponse) Unmarshal

func (m *MsgResetRateLimitResponse) Unmarshal(dAtA []byte) error

func (*MsgResetRateLimitResponse) XXX_DiscardUnknown

func (m *MsgResetRateLimitResponse) XXX_DiscardUnknown()

func (*MsgResetRateLimitResponse) XXX_Marshal

func (m *MsgResetRateLimitResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*MsgResetRateLimitResponse) XXX_Merge

func (m *MsgResetRateLimitResponse) XXX_Merge(src proto.Message)

func (*MsgResetRateLimitResponse) XXX_Size

func (m *MsgResetRateLimitResponse) XXX_Size() int

func (*MsgResetRateLimitResponse) XXX_Unmarshal

func (m *MsgResetRateLimitResponse) XXX_Unmarshal(b []byte) error

type MsgServer

type MsgServer interface {
	// Gov tx to add a new rate limit
	AddRateLimit(context.Context, *MsgAddRateLimit) (*MsgAddRateLimitResponse, error)
	// Gov tx to update an existing rate limit
	UpdateRateLimit(context.Context, *MsgUpdateRateLimit) (*MsgUpdateRateLimitResponse, error)
	// Gov tx to remove a rate limit
	RemoveRateLimit(context.Context, *MsgRemoveRateLimit) (*MsgRemoveRateLimitResponse, error)
	// Gov tx to reset the flow on a rate limit
	ResetRateLimit(context.Context, *MsgResetRateLimit) (*MsgResetRateLimitResponse, error)
}

MsgServer is the server API for Msg service.

type MsgUpdateRateLimit

type MsgUpdateRateLimit struct {
	// Authority defines the x/gov module account
	Authority string `protobuf:"bytes,1,opt,name=authority,proto3" json:"authority,omitempty"`
	// Denom for the rate limit, as it appears on the rate limited chain
	// When rate limiting a non-native token, this will be an ibc denom
	Denom string `protobuf:"bytes,2,opt,name=denom,proto3" json:"denom,omitempty"`
	// ChannelId for the rate limit, on the side of the rate limited chain
	ChannelId string `protobuf:"bytes,3,opt,name=channel_id,json=channelId,proto3" json:"channel_id,omitempty"`
	// MaxPercentSend defines the threshold for outflows
	// The threshold is defined as a percentage (e.g. 10 indicates 10%)
	MaxPercentSend cosmossdk_io_math.Int `` /* 128-byte string literal not displayed */
	// MaxPercentSend defines the threshold for inflows
	// The threshold is defined as a percentage (e.g. 10 indicates 10%)
	MaxPercentRecv cosmossdk_io_math.Int `` /* 128-byte string literal not displayed */
	// DurationHours specifies the number of hours before the rate limit
	// is reset (e.g. 24 indicates that the rate limit is reset each day)
	DurationHours uint64 `protobuf:"varint,6,opt,name=duration_hours,json=durationHours,proto3" json:"duration_hours,omitempty"`
}

Gov tx to update an existing rate limit

func NewMsgUpdateRateLimit

func NewMsgUpdateRateLimit(denom, channelId string, maxPercentSend sdkmath.Int, maxPercentRecv sdkmath.Int, durationHours uint64) *MsgUpdateRateLimit

func (*MsgUpdateRateLimit) Descriptor

func (*MsgUpdateRateLimit) Descriptor() ([]byte, []int)

func (*MsgUpdateRateLimit) GetAuthority

func (m *MsgUpdateRateLimit) GetAuthority() string

func (*MsgUpdateRateLimit) GetChannelId

func (m *MsgUpdateRateLimit) GetChannelId() string

func (*MsgUpdateRateLimit) GetDenom

func (m *MsgUpdateRateLimit) GetDenom() string

func (*MsgUpdateRateLimit) GetDurationHours

func (m *MsgUpdateRateLimit) GetDurationHours() uint64

func (*MsgUpdateRateLimit) GetSignBytes

func (msg *MsgUpdateRateLimit) GetSignBytes() []byte

func (*MsgUpdateRateLimit) GetSigners

func (msg *MsgUpdateRateLimit) GetSigners() []sdk.AccAddress

func (*MsgUpdateRateLimit) Marshal

func (m *MsgUpdateRateLimit) Marshal() (dAtA []byte, err error)

func (*MsgUpdateRateLimit) MarshalTo

func (m *MsgUpdateRateLimit) MarshalTo(dAtA []byte) (int, error)

func (*MsgUpdateRateLimit) MarshalToSizedBuffer

func (m *MsgUpdateRateLimit) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*MsgUpdateRateLimit) ProtoMessage

func (*MsgUpdateRateLimit) ProtoMessage()

func (*MsgUpdateRateLimit) Reset

func (m *MsgUpdateRateLimit) Reset()

func (MsgUpdateRateLimit) Route

func (msg MsgUpdateRateLimit) Route() string

func (*MsgUpdateRateLimit) Size

func (m *MsgUpdateRateLimit) Size() (n int)

func (*MsgUpdateRateLimit) String

func (m *MsgUpdateRateLimit) String() string

func (MsgUpdateRateLimit) Type

func (msg MsgUpdateRateLimit) Type() string

func (*MsgUpdateRateLimit) Unmarshal

func (m *MsgUpdateRateLimit) Unmarshal(dAtA []byte) error

func (*MsgUpdateRateLimit) ValidateBasic

func (msg *MsgUpdateRateLimit) ValidateBasic() error

func (*MsgUpdateRateLimit) XXX_DiscardUnknown

func (m *MsgUpdateRateLimit) XXX_DiscardUnknown()

func (*MsgUpdateRateLimit) XXX_Marshal

func (m *MsgUpdateRateLimit) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*MsgUpdateRateLimit) XXX_Merge

func (m *MsgUpdateRateLimit) XXX_Merge(src proto.Message)

func (*MsgUpdateRateLimit) XXX_Size

func (m *MsgUpdateRateLimit) XXX_Size() int

func (*MsgUpdateRateLimit) XXX_Unmarshal

func (m *MsgUpdateRateLimit) XXX_Unmarshal(b []byte) error

type MsgUpdateRateLimitResponse

type MsgUpdateRateLimitResponse struct {
}

func (*MsgUpdateRateLimitResponse) Descriptor

func (*MsgUpdateRateLimitResponse) Descriptor() ([]byte, []int)

func (*MsgUpdateRateLimitResponse) Marshal

func (m *MsgUpdateRateLimitResponse) Marshal() (dAtA []byte, err error)

func (*MsgUpdateRateLimitResponse) MarshalTo

func (m *MsgUpdateRateLimitResponse) MarshalTo(dAtA []byte) (int, error)

func (*MsgUpdateRateLimitResponse) MarshalToSizedBuffer

func (m *MsgUpdateRateLimitResponse) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*MsgUpdateRateLimitResponse) ProtoMessage

func (*MsgUpdateRateLimitResponse) ProtoMessage()

func (*MsgUpdateRateLimitResponse) Reset

func (m *MsgUpdateRateLimitResponse) Reset()

func (*MsgUpdateRateLimitResponse) Size

func (m *MsgUpdateRateLimitResponse) Size() (n int)

func (*MsgUpdateRateLimitResponse) String

func (m *MsgUpdateRateLimitResponse) String() string

func (*MsgUpdateRateLimitResponse) Unmarshal

func (m *MsgUpdateRateLimitResponse) Unmarshal(dAtA []byte) error

func (*MsgUpdateRateLimitResponse) XXX_DiscardUnknown

func (m *MsgUpdateRateLimitResponse) XXX_DiscardUnknown()

func (*MsgUpdateRateLimitResponse) XXX_Marshal

func (m *MsgUpdateRateLimitResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*MsgUpdateRateLimitResponse) XXX_Merge

func (m *MsgUpdateRateLimitResponse) XXX_Merge(src proto.Message)

func (*MsgUpdateRateLimitResponse) XXX_Size

func (m *MsgUpdateRateLimitResponse) XXX_Size() int

func (*MsgUpdateRateLimitResponse) XXX_Unmarshal

func (m *MsgUpdateRateLimitResponse) XXX_Unmarshal(b []byte) error

type PacketDirection

type PacketDirection int32

PacketDirection defines whether the transfer packet is being sent from this chain or is being received on this chain

const (
	PACKET_SEND PacketDirection = 0
	PACKET_RECV PacketDirection = 1
)

func (PacketDirection) EnumDescriptor

func (PacketDirection) EnumDescriptor() ([]byte, []int)

func (PacketDirection) String

func (x PacketDirection) String() string

type Params

type Params struct {
}

Params defines the ratelimit module's parameters.

func DefaultParams

func DefaultParams() Params

DefaultParams returns a default set of parameters

func NewParams

func NewParams() Params

NewParams creates a new Params instance

func (*Params) Descriptor

func (*Params) Descriptor() ([]byte, []int)

func (*Params) Marshal

func (m *Params) Marshal() (dAtA []byte, err error)

func (*Params) MarshalTo

func (m *Params) MarshalTo(dAtA []byte) (int, error)

func (*Params) MarshalToSizedBuffer

func (m *Params) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*Params) ParamSetPairs

func (p *Params) ParamSetPairs() paramtypes.ParamSetPairs

ParamSetPairs get the params.ParamSet

func (*Params) ProtoMessage

func (*Params) ProtoMessage()

func (*Params) Reset

func (m *Params) Reset()

func (*Params) Size

func (m *Params) Size() (n int)

func (*Params) String

func (m *Params) String() string

func (*Params) Unmarshal

func (m *Params) Unmarshal(dAtA []byte) error

func (Params) Validate

func (p Params) Validate() error

Validate validates the set of params

func (*Params) XXX_DiscardUnknown

func (m *Params) XXX_DiscardUnknown()

func (*Params) XXX_Marshal

func (m *Params) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*Params) XXX_Merge

func (m *Params) XXX_Merge(src proto.Message)

func (*Params) XXX_Size

func (m *Params) XXX_Size() int

func (*Params) XXX_Unmarshal

func (m *Params) XXX_Unmarshal(b []byte) error

type Path

type Path struct {
	Denom     string `protobuf:"bytes,1,opt,name=denom,proto3" json:"denom,omitempty"`
	ChannelId string `protobuf:"bytes,2,opt,name=channel_id,json=channelId,proto3" json:"channel_id,omitempty"`
}

Path holds the denom and channelID that define the rate limited route

func (*Path) Descriptor

func (*Path) Descriptor() ([]byte, []int)

func (*Path) GetChannelId

func (m *Path) GetChannelId() string

func (*Path) GetDenom

func (m *Path) GetDenom() string

func (*Path) Marshal

func (m *Path) Marshal() (dAtA []byte, err error)

func (*Path) MarshalTo

func (m *Path) MarshalTo(dAtA []byte) (int, error)

func (*Path) MarshalToSizedBuffer

func (m *Path) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*Path) ProtoMessage

func (*Path) ProtoMessage()

func (*Path) Reset

func (m *Path) Reset()

func (*Path) Size

func (m *Path) Size() (n int)

func (*Path) String

func (m *Path) String() string

func (*Path) Unmarshal

func (m *Path) Unmarshal(dAtA []byte) error

func (*Path) XXX_DiscardUnknown

func (m *Path) XXX_DiscardUnknown()

func (*Path) XXX_Marshal

func (m *Path) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*Path) XXX_Merge

func (m *Path) XXX_Merge(src proto.Message)

func (*Path) XXX_Size

func (m *Path) XXX_Size() int

func (*Path) XXX_Unmarshal

func (m *Path) XXX_Unmarshal(b []byte) error

type QueryAllBlacklistedDenomsRequest

type QueryAllBlacklistedDenomsRequest struct {
}

Queries all blacklisted denoms

func (*QueryAllBlacklistedDenomsRequest) Descriptor

func (*QueryAllBlacklistedDenomsRequest) Descriptor() ([]byte, []int)

func (*QueryAllBlacklistedDenomsRequest) Marshal

func (m *QueryAllBlacklistedDenomsRequest) Marshal() (dAtA []byte, err error)

func (*QueryAllBlacklistedDenomsRequest) MarshalTo

func (m *QueryAllBlacklistedDenomsRequest) MarshalTo(dAtA []byte) (int, error)

func (*QueryAllBlacklistedDenomsRequest) MarshalToSizedBuffer

func (m *QueryAllBlacklistedDenomsRequest) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*QueryAllBlacklistedDenomsRequest) ProtoMessage

func (*QueryAllBlacklistedDenomsRequest) ProtoMessage()

func (*QueryAllBlacklistedDenomsRequest) Reset

func (*QueryAllBlacklistedDenomsRequest) Size

func (m *QueryAllBlacklistedDenomsRequest) Size() (n int)

func (*QueryAllBlacklistedDenomsRequest) String

func (*QueryAllBlacklistedDenomsRequest) Unmarshal

func (m *QueryAllBlacklistedDenomsRequest) Unmarshal(dAtA []byte) error

func (*QueryAllBlacklistedDenomsRequest) XXX_DiscardUnknown

func (m *QueryAllBlacklistedDenomsRequest) XXX_DiscardUnknown()

func (*QueryAllBlacklistedDenomsRequest) XXX_Marshal

func (m *QueryAllBlacklistedDenomsRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*QueryAllBlacklistedDenomsRequest) XXX_Merge

func (*QueryAllBlacklistedDenomsRequest) XXX_Size

func (m *QueryAllBlacklistedDenomsRequest) XXX_Size() int

func (*QueryAllBlacklistedDenomsRequest) XXX_Unmarshal

func (m *QueryAllBlacklistedDenomsRequest) XXX_Unmarshal(b []byte) error

type QueryAllBlacklistedDenomsResponse

type QueryAllBlacklistedDenomsResponse struct {
	Denoms []string `protobuf:"bytes,1,rep,name=denoms,proto3" json:"denoms,omitempty"`
}

func (*QueryAllBlacklistedDenomsResponse) Descriptor

func (*QueryAllBlacklistedDenomsResponse) Descriptor() ([]byte, []int)

func (*QueryAllBlacklistedDenomsResponse) GetDenoms

func (m *QueryAllBlacklistedDenomsResponse) GetDenoms() []string

func (*QueryAllBlacklistedDenomsResponse) Marshal

func (m *QueryAllBlacklistedDenomsResponse) Marshal() (dAtA []byte, err error)

func (*QueryAllBlacklistedDenomsResponse) MarshalTo

func (m *QueryAllBlacklistedDenomsResponse) MarshalTo(dAtA []byte) (int, error)

func (*QueryAllBlacklistedDenomsResponse) MarshalToSizedBuffer

func (m *QueryAllBlacklistedDenomsResponse) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*QueryAllBlacklistedDenomsResponse) ProtoMessage

func (*QueryAllBlacklistedDenomsResponse) ProtoMessage()

func (*QueryAllBlacklistedDenomsResponse) Reset

func (*QueryAllBlacklistedDenomsResponse) Size

func (m *QueryAllBlacklistedDenomsResponse) Size() (n int)

func (*QueryAllBlacklistedDenomsResponse) String

func (*QueryAllBlacklistedDenomsResponse) Unmarshal

func (m *QueryAllBlacklistedDenomsResponse) Unmarshal(dAtA []byte) error

func (*QueryAllBlacklistedDenomsResponse) XXX_DiscardUnknown

func (m *QueryAllBlacklistedDenomsResponse) XXX_DiscardUnknown()

func (*QueryAllBlacklistedDenomsResponse) XXX_Marshal

func (m *QueryAllBlacklistedDenomsResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*QueryAllBlacklistedDenomsResponse) XXX_Merge

func (*QueryAllBlacklistedDenomsResponse) XXX_Size

func (m *QueryAllBlacklistedDenomsResponse) XXX_Size() int

func (*QueryAllBlacklistedDenomsResponse) XXX_Unmarshal

func (m *QueryAllBlacklistedDenomsResponse) XXX_Unmarshal(b []byte) error

type QueryAllRateLimitsRequest

type QueryAllRateLimitsRequest struct {
}

Queries all rate limits

func (*QueryAllRateLimitsRequest) Descriptor

func (*QueryAllRateLimitsRequest) Descriptor() ([]byte, []int)

func (*QueryAllRateLimitsRequest) Marshal

func (m *QueryAllRateLimitsRequest) Marshal() (dAtA []byte, err error)

func (*QueryAllRateLimitsRequest) MarshalTo

func (m *QueryAllRateLimitsRequest) MarshalTo(dAtA []byte) (int, error)

func (*QueryAllRateLimitsRequest) MarshalToSizedBuffer

func (m *QueryAllRateLimitsRequest) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*QueryAllRateLimitsRequest) ProtoMessage

func (*QueryAllRateLimitsRequest) ProtoMessage()

func (*QueryAllRateLimitsRequest) Reset

func (m *QueryAllRateLimitsRequest) Reset()

func (*QueryAllRateLimitsRequest) Size

func (m *QueryAllRateLimitsRequest) Size() (n int)

func (*QueryAllRateLimitsRequest) String

func (m *QueryAllRateLimitsRequest) String() string

func (*QueryAllRateLimitsRequest) Unmarshal

func (m *QueryAllRateLimitsRequest) Unmarshal(dAtA []byte) error

func (*QueryAllRateLimitsRequest) XXX_DiscardUnknown

func (m *QueryAllRateLimitsRequest) XXX_DiscardUnknown()

func (*QueryAllRateLimitsRequest) XXX_Marshal

func (m *QueryAllRateLimitsRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*QueryAllRateLimitsRequest) XXX_Merge

func (m *QueryAllRateLimitsRequest) XXX_Merge(src proto.Message)

func (*QueryAllRateLimitsRequest) XXX_Size

func (m *QueryAllRateLimitsRequest) XXX_Size() int

func (*QueryAllRateLimitsRequest) XXX_Unmarshal

func (m *QueryAllRateLimitsRequest) XXX_Unmarshal(b []byte) error

type QueryAllRateLimitsResponse

type QueryAllRateLimitsResponse struct {
	RateLimits []RateLimit `protobuf:"bytes,1,rep,name=rate_limits,json=rateLimits,proto3" json:"rate_limits"`
}

func (*QueryAllRateLimitsResponse) Descriptor

func (*QueryAllRateLimitsResponse) Descriptor() ([]byte, []int)

func (*QueryAllRateLimitsResponse) GetRateLimits

func (m *QueryAllRateLimitsResponse) GetRateLimits() []RateLimit

func (*QueryAllRateLimitsResponse) Marshal

func (m *QueryAllRateLimitsResponse) Marshal() (dAtA []byte, err error)

func (*QueryAllRateLimitsResponse) MarshalTo

func (m *QueryAllRateLimitsResponse) MarshalTo(dAtA []byte) (int, error)

func (*QueryAllRateLimitsResponse) MarshalToSizedBuffer

func (m *QueryAllRateLimitsResponse) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*QueryAllRateLimitsResponse) ProtoMessage

func (*QueryAllRateLimitsResponse) ProtoMessage()

func (*QueryAllRateLimitsResponse) Reset

func (m *QueryAllRateLimitsResponse) Reset()

func (*QueryAllRateLimitsResponse) Size

func (m *QueryAllRateLimitsResponse) Size() (n int)

func (*QueryAllRateLimitsResponse) String

func (m *QueryAllRateLimitsResponse) String() string

func (*QueryAllRateLimitsResponse) Unmarshal

func (m *QueryAllRateLimitsResponse) Unmarshal(dAtA []byte) error

func (*QueryAllRateLimitsResponse) XXX_DiscardUnknown

func (m *QueryAllRateLimitsResponse) XXX_DiscardUnknown()

func (*QueryAllRateLimitsResponse) XXX_Marshal

func (m *QueryAllRateLimitsResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*QueryAllRateLimitsResponse) XXX_Merge

func (m *QueryAllRateLimitsResponse) XXX_Merge(src proto.Message)

func (*QueryAllRateLimitsResponse) XXX_Size

func (m *QueryAllRateLimitsResponse) XXX_Size() int

func (*QueryAllRateLimitsResponse) XXX_Unmarshal

func (m *QueryAllRateLimitsResponse) XXX_Unmarshal(b []byte) error

type QueryAllWhitelistedAddressesRequest

type QueryAllWhitelistedAddressesRequest struct {
}

Queries all whitelisted address pairs

func (*QueryAllWhitelistedAddressesRequest) Descriptor

func (*QueryAllWhitelistedAddressesRequest) Descriptor() ([]byte, []int)

func (*QueryAllWhitelistedAddressesRequest) Marshal

func (m *QueryAllWhitelistedAddressesRequest) Marshal() (dAtA []byte, err error)

func (*QueryAllWhitelistedAddressesRequest) MarshalTo

func (m *QueryAllWhitelistedAddressesRequest) MarshalTo(dAtA []byte) (int, error)

func (*QueryAllWhitelistedAddressesRequest) MarshalToSizedBuffer

func (m *QueryAllWhitelistedAddressesRequest) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*QueryAllWhitelistedAddressesRequest) ProtoMessage

func (*QueryAllWhitelistedAddressesRequest) ProtoMessage()

func (*QueryAllWhitelistedAddressesRequest) Reset

func (*QueryAllWhitelistedAddressesRequest) Size

func (*QueryAllWhitelistedAddressesRequest) String

func (*QueryAllWhitelistedAddressesRequest) Unmarshal

func (m *QueryAllWhitelistedAddressesRequest) Unmarshal(dAtA []byte) error

func (*QueryAllWhitelistedAddressesRequest) XXX_DiscardUnknown

func (m *QueryAllWhitelistedAddressesRequest) XXX_DiscardUnknown()

func (*QueryAllWhitelistedAddressesRequest) XXX_Marshal

func (m *QueryAllWhitelistedAddressesRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*QueryAllWhitelistedAddressesRequest) XXX_Merge

func (*QueryAllWhitelistedAddressesRequest) XXX_Size

func (*QueryAllWhitelistedAddressesRequest) XXX_Unmarshal

func (m *QueryAllWhitelistedAddressesRequest) XXX_Unmarshal(b []byte) error

type QueryAllWhitelistedAddressesResponse

type QueryAllWhitelistedAddressesResponse struct {
	AddressPairs []WhitelistedAddressPair `protobuf:"bytes,1,rep,name=address_pairs,json=addressPairs,proto3" json:"address_pairs"`
}

func (*QueryAllWhitelistedAddressesResponse) Descriptor

func (*QueryAllWhitelistedAddressesResponse) Descriptor() ([]byte, []int)

func (*QueryAllWhitelistedAddressesResponse) GetAddressPairs

func (*QueryAllWhitelistedAddressesResponse) Marshal

func (m *QueryAllWhitelistedAddressesResponse) Marshal() (dAtA []byte, err error)

func (*QueryAllWhitelistedAddressesResponse) MarshalTo

func (m *QueryAllWhitelistedAddressesResponse) MarshalTo(dAtA []byte) (int, error)

func (*QueryAllWhitelistedAddressesResponse) MarshalToSizedBuffer

func (m *QueryAllWhitelistedAddressesResponse) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*QueryAllWhitelistedAddressesResponse) ProtoMessage

func (*QueryAllWhitelistedAddressesResponse) ProtoMessage()

func (*QueryAllWhitelistedAddressesResponse) Reset

func (*QueryAllWhitelistedAddressesResponse) Size

func (*QueryAllWhitelistedAddressesResponse) String

func (*QueryAllWhitelistedAddressesResponse) Unmarshal

func (m *QueryAllWhitelistedAddressesResponse) Unmarshal(dAtA []byte) error

func (*QueryAllWhitelistedAddressesResponse) XXX_DiscardUnknown

func (m *QueryAllWhitelistedAddressesResponse) XXX_DiscardUnknown()

func (*QueryAllWhitelistedAddressesResponse) XXX_Marshal

func (m *QueryAllWhitelistedAddressesResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*QueryAllWhitelistedAddressesResponse) XXX_Merge

func (*QueryAllWhitelistedAddressesResponse) XXX_Size

func (*QueryAllWhitelistedAddressesResponse) XXX_Unmarshal

func (m *QueryAllWhitelistedAddressesResponse) XXX_Unmarshal(b []byte) error

type QueryClient

type QueryClient interface {
	// Queries all rate limits
	AllRateLimits(ctx context.Context, in *QueryAllRateLimitsRequest, opts ...grpc.CallOption) (*QueryAllRateLimitsResponse, error)
	// Queries a specific rate limit by channel ID and denom
	// Ex:
	//  - /ratelimit/{channel_id}/by_denom?denom={denom}
	RateLimit(ctx context.Context, in *QueryRateLimitRequest, opts ...grpc.CallOption) (*QueryRateLimitResponse, error)
	// Queries all the rate limits for a given chain
	RateLimitsByChainId(ctx context.Context, in *QueryRateLimitsByChainIdRequest, opts ...grpc.CallOption) (*QueryRateLimitsByChainIdResponse, error)
	// Queries all the rate limits for a given channel ID
	RateLimitsByChannelId(ctx context.Context, in *QueryRateLimitsByChannelIdRequest, opts ...grpc.CallOption) (*QueryRateLimitsByChannelIdResponse, error)
	// Queries all blacklisted denoms
	AllBlacklistedDenoms(ctx context.Context, in *QueryAllBlacklistedDenomsRequest, opts ...grpc.CallOption) (*QueryAllBlacklistedDenomsResponse, error)
	// Queries all whitelisted address pairs
	AllWhitelistedAddresses(ctx context.Context, in *QueryAllWhitelistedAddressesRequest, opts ...grpc.CallOption) (*QueryAllWhitelistedAddressesResponse, error)
}

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.

func NewQueryClient

func NewQueryClient(cc grpc1.ClientConn) QueryClient

type QueryRateLimitRequest

type QueryRateLimitRequest struct {
	Denom     string `protobuf:"bytes,1,opt,name=denom,proto3" json:"denom,omitempty"`
	ChannelId string `protobuf:"bytes,2,opt,name=channel_id,json=channelId,proto3" json:"channel_id,omitempty"`
}

Queries a specific rate limit by channel ID and denom

func (*QueryRateLimitRequest) Descriptor

func (*QueryRateLimitRequest) Descriptor() ([]byte, []int)

func (*QueryRateLimitRequest) GetChannelId

func (m *QueryRateLimitRequest) GetChannelId() string

func (*QueryRateLimitRequest) GetDenom

func (m *QueryRateLimitRequest) GetDenom() string

func (*QueryRateLimitRequest) Marshal

func (m *QueryRateLimitRequest) Marshal() (dAtA []byte, err error)

func (*QueryRateLimitRequest) MarshalTo

func (m *QueryRateLimitRequest) MarshalTo(dAtA []byte) (int, error)

func (*QueryRateLimitRequest) MarshalToSizedBuffer

func (m *QueryRateLimitRequest) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*QueryRateLimitRequest) ProtoMessage

func (*QueryRateLimitRequest) ProtoMessage()

func (*QueryRateLimitRequest) Reset

func (m *QueryRateLimitRequest) Reset()

func (*QueryRateLimitRequest) Size

func (m *QueryRateLimitRequest) Size() (n int)

func (*QueryRateLimitRequest) String

func (m *QueryRateLimitRequest) String() string

func (*QueryRateLimitRequest) Unmarshal

func (m *QueryRateLimitRequest) Unmarshal(dAtA []byte) error

func (*QueryRateLimitRequest) XXX_DiscardUnknown

func (m *QueryRateLimitRequest) XXX_DiscardUnknown()

func (*QueryRateLimitRequest) XXX_Marshal

func (m *QueryRateLimitRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*QueryRateLimitRequest) XXX_Merge

func (m *QueryRateLimitRequest) XXX_Merge(src proto.Message)

func (*QueryRateLimitRequest) XXX_Size

func (m *QueryRateLimitRequest) XXX_Size() int

func (*QueryRateLimitRequest) XXX_Unmarshal

func (m *QueryRateLimitRequest) XXX_Unmarshal(b []byte) error

type QueryRateLimitResponse

type QueryRateLimitResponse struct {
	RateLimit *RateLimit `protobuf:"bytes,1,opt,name=rate_limit,json=rateLimit,proto3" json:"rate_limit,omitempty"`
}

func (*QueryRateLimitResponse) Descriptor

func (*QueryRateLimitResponse) Descriptor() ([]byte, []int)

func (*QueryRateLimitResponse) GetRateLimit

func (m *QueryRateLimitResponse) GetRateLimit() *RateLimit

func (*QueryRateLimitResponse) Marshal

func (m *QueryRateLimitResponse) Marshal() (dAtA []byte, err error)

func (*QueryRateLimitResponse) MarshalTo

func (m *QueryRateLimitResponse) MarshalTo(dAtA []byte) (int, error)

func (*QueryRateLimitResponse) MarshalToSizedBuffer

func (m *QueryRateLimitResponse) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*QueryRateLimitResponse) ProtoMessage

func (*QueryRateLimitResponse) ProtoMessage()

func (*QueryRateLimitResponse) Reset

func (m *QueryRateLimitResponse) Reset()

func (*QueryRateLimitResponse) Size

func (m *QueryRateLimitResponse) Size() (n int)

func (*QueryRateLimitResponse) String

func (m *QueryRateLimitResponse) String() string

func (*QueryRateLimitResponse) Unmarshal

func (m *QueryRateLimitResponse) Unmarshal(dAtA []byte) error

func (*QueryRateLimitResponse) XXX_DiscardUnknown

func (m *QueryRateLimitResponse) XXX_DiscardUnknown()

func (*QueryRateLimitResponse) XXX_Marshal

func (m *QueryRateLimitResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*QueryRateLimitResponse) XXX_Merge

func (m *QueryRateLimitResponse) XXX_Merge(src proto.Message)

func (*QueryRateLimitResponse) XXX_Size

func (m *QueryRateLimitResponse) XXX_Size() int

func (*QueryRateLimitResponse) XXX_Unmarshal

func (m *QueryRateLimitResponse) XXX_Unmarshal(b []byte) error

type QueryRateLimitsByChainIdRequest

type QueryRateLimitsByChainIdRequest struct {
	ChainId string `protobuf:"bytes,1,opt,name=chain_id,json=chainId,proto3" json:"chain_id,omitempty"`
}

Queries all the rate limits for a given chain

func (*QueryRateLimitsByChainIdRequest) Descriptor

func (*QueryRateLimitsByChainIdRequest) Descriptor() ([]byte, []int)

func (*QueryRateLimitsByChainIdRequest) GetChainId

func (m *QueryRateLimitsByChainIdRequest) GetChainId() string

func (*QueryRateLimitsByChainIdRequest) Marshal

func (m *QueryRateLimitsByChainIdRequest) Marshal() (dAtA []byte, err error)

func (*QueryRateLimitsByChainIdRequest) MarshalTo

func (m *QueryRateLimitsByChainIdRequest) MarshalTo(dAtA []byte) (int, error)

func (*QueryRateLimitsByChainIdRequest) MarshalToSizedBuffer

func (m *QueryRateLimitsByChainIdRequest) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*QueryRateLimitsByChainIdRequest) ProtoMessage

func (*QueryRateLimitsByChainIdRequest) ProtoMessage()

func (*QueryRateLimitsByChainIdRequest) Reset

func (*QueryRateLimitsByChainIdRequest) Size

func (m *QueryRateLimitsByChainIdRequest) Size() (n int)

func (*QueryRateLimitsByChainIdRequest) String

func (*QueryRateLimitsByChainIdRequest) Unmarshal

func (m *QueryRateLimitsByChainIdRequest) Unmarshal(dAtA []byte) error

func (*QueryRateLimitsByChainIdRequest) XXX_DiscardUnknown

func (m *QueryRateLimitsByChainIdRequest) XXX_DiscardUnknown()

func (*QueryRateLimitsByChainIdRequest) XXX_Marshal

func (m *QueryRateLimitsByChainIdRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*QueryRateLimitsByChainIdRequest) XXX_Merge

func (m *QueryRateLimitsByChainIdRequest) XXX_Merge(src proto.Message)

func (*QueryRateLimitsByChainIdRequest) XXX_Size

func (m *QueryRateLimitsByChainIdRequest) XXX_Size() int

func (*QueryRateLimitsByChainIdRequest) XXX_Unmarshal

func (m *QueryRateLimitsByChainIdRequest) XXX_Unmarshal(b []byte) error

type QueryRateLimitsByChainIdResponse

type QueryRateLimitsByChainIdResponse struct {
	RateLimits []RateLimit `protobuf:"bytes,1,rep,name=rate_limits,json=rateLimits,proto3" json:"rate_limits"`
}

func (*QueryRateLimitsByChainIdResponse) Descriptor

func (*QueryRateLimitsByChainIdResponse) Descriptor() ([]byte, []int)

func (*QueryRateLimitsByChainIdResponse) GetRateLimits

func (m *QueryRateLimitsByChainIdResponse) GetRateLimits() []RateLimit

func (*QueryRateLimitsByChainIdResponse) Marshal

func (m *QueryRateLimitsByChainIdResponse) Marshal() (dAtA []byte, err error)

func (*QueryRateLimitsByChainIdResponse) MarshalTo

func (m *QueryRateLimitsByChainIdResponse) MarshalTo(dAtA []byte) (int, error)

func (*QueryRateLimitsByChainIdResponse) MarshalToSizedBuffer

func (m *QueryRateLimitsByChainIdResponse) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*QueryRateLimitsByChainIdResponse) ProtoMessage

func (*QueryRateLimitsByChainIdResponse) ProtoMessage()

func (*QueryRateLimitsByChainIdResponse) Reset

func (*QueryRateLimitsByChainIdResponse) Size

func (m *QueryRateLimitsByChainIdResponse) Size() (n int)

func (*QueryRateLimitsByChainIdResponse) String

func (*QueryRateLimitsByChainIdResponse) Unmarshal

func (m *QueryRateLimitsByChainIdResponse) Unmarshal(dAtA []byte) error

func (*QueryRateLimitsByChainIdResponse) XXX_DiscardUnknown

func (m *QueryRateLimitsByChainIdResponse) XXX_DiscardUnknown()

func (*QueryRateLimitsByChainIdResponse) XXX_Marshal

func (m *QueryRateLimitsByChainIdResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*QueryRateLimitsByChainIdResponse) XXX_Merge

func (*QueryRateLimitsByChainIdResponse) XXX_Size

func (m *QueryRateLimitsByChainIdResponse) XXX_Size() int

func (*QueryRateLimitsByChainIdResponse) XXX_Unmarshal

func (m *QueryRateLimitsByChainIdResponse) XXX_Unmarshal(b []byte) error

type QueryRateLimitsByChannelIdRequest

type QueryRateLimitsByChannelIdRequest struct {
	ChannelId string `protobuf:"bytes,1,opt,name=channel_id,json=channelId,proto3" json:"channel_id,omitempty"`
}

Queries all the rate limits for a given channel ID

func (*QueryRateLimitsByChannelIdRequest) Descriptor

func (*QueryRateLimitsByChannelIdRequest) Descriptor() ([]byte, []int)

func (*QueryRateLimitsByChannelIdRequest) GetChannelId

func (m *QueryRateLimitsByChannelIdRequest) GetChannelId() string

func (*QueryRateLimitsByChannelIdRequest) Marshal

func (m *QueryRateLimitsByChannelIdRequest) Marshal() (dAtA []byte, err error)

func (*QueryRateLimitsByChannelIdRequest) MarshalTo

func (m *QueryRateLimitsByChannelIdRequest) MarshalTo(dAtA []byte) (int, error)

func (*QueryRateLimitsByChannelIdRequest) MarshalToSizedBuffer

func (m *QueryRateLimitsByChannelIdRequest) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*QueryRateLimitsByChannelIdRequest) ProtoMessage

func (*QueryRateLimitsByChannelIdRequest) ProtoMessage()

func (*QueryRateLimitsByChannelIdRequest) Reset

func (*QueryRateLimitsByChannelIdRequest) Size

func (m *QueryRateLimitsByChannelIdRequest) Size() (n int)

func (*QueryRateLimitsByChannelIdRequest) String

func (*QueryRateLimitsByChannelIdRequest) Unmarshal

func (m *QueryRateLimitsByChannelIdRequest) Unmarshal(dAtA []byte) error

func (*QueryRateLimitsByChannelIdRequest) XXX_DiscardUnknown

func (m *QueryRateLimitsByChannelIdRequest) XXX_DiscardUnknown()

func (*QueryRateLimitsByChannelIdRequest) XXX_Marshal

func (m *QueryRateLimitsByChannelIdRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*QueryRateLimitsByChannelIdRequest) XXX_Merge

func (*QueryRateLimitsByChannelIdRequest) XXX_Size

func (m *QueryRateLimitsByChannelIdRequest) XXX_Size() int

func (*QueryRateLimitsByChannelIdRequest) XXX_Unmarshal

func (m *QueryRateLimitsByChannelIdRequest) XXX_Unmarshal(b []byte) error

type QueryRateLimitsByChannelIdResponse

type QueryRateLimitsByChannelIdResponse struct {
	RateLimits []RateLimit `protobuf:"bytes,1,rep,name=rate_limits,json=rateLimits,proto3" json:"rate_limits"`
}

func (*QueryRateLimitsByChannelIdResponse) Descriptor

func (*QueryRateLimitsByChannelIdResponse) Descriptor() ([]byte, []int)

func (*QueryRateLimitsByChannelIdResponse) GetRateLimits

func (m *QueryRateLimitsByChannelIdResponse) GetRateLimits() []RateLimit

func (*QueryRateLimitsByChannelIdResponse) Marshal

func (m *QueryRateLimitsByChannelIdResponse) Marshal() (dAtA []byte, err error)

func (*QueryRateLimitsByChannelIdResponse) MarshalTo

func (m *QueryRateLimitsByChannelIdResponse) MarshalTo(dAtA []byte) (int, error)

func (*QueryRateLimitsByChannelIdResponse) MarshalToSizedBuffer

func (m *QueryRateLimitsByChannelIdResponse) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*QueryRateLimitsByChannelIdResponse) ProtoMessage

func (*QueryRateLimitsByChannelIdResponse) ProtoMessage()

func (*QueryRateLimitsByChannelIdResponse) Reset

func (*QueryRateLimitsByChannelIdResponse) Size

func (*QueryRateLimitsByChannelIdResponse) String

func (*QueryRateLimitsByChannelIdResponse) Unmarshal

func (m *QueryRateLimitsByChannelIdResponse) Unmarshal(dAtA []byte) error

func (*QueryRateLimitsByChannelIdResponse) XXX_DiscardUnknown

func (m *QueryRateLimitsByChannelIdResponse) XXX_DiscardUnknown()

func (*QueryRateLimitsByChannelIdResponse) XXX_Marshal

func (m *QueryRateLimitsByChannelIdResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*QueryRateLimitsByChannelIdResponse) XXX_Merge

func (*QueryRateLimitsByChannelIdResponse) XXX_Size

func (*QueryRateLimitsByChannelIdResponse) XXX_Unmarshal

func (m *QueryRateLimitsByChannelIdResponse) XXX_Unmarshal(b []byte) error

type QueryServer

type QueryServer interface {
	// Queries all rate limits
	AllRateLimits(context.Context, *QueryAllRateLimitsRequest) (*QueryAllRateLimitsResponse, error)
	// Queries a specific rate limit by channel ID and denom
	// Ex:
	//  - /ratelimit/{channel_id}/by_denom?denom={denom}
	RateLimit(context.Context, *QueryRateLimitRequest) (*QueryRateLimitResponse, error)
	// Queries all the rate limits for a given chain
	RateLimitsByChainId(context.Context, *QueryRateLimitsByChainIdRequest) (*QueryRateLimitsByChainIdResponse, error)
	// Queries all the rate limits for a given channel ID
	RateLimitsByChannelId(context.Context, *QueryRateLimitsByChannelIdRequest) (*QueryRateLimitsByChannelIdResponse, error)
	// Queries all blacklisted denoms
	AllBlacklistedDenoms(context.Context, *QueryAllBlacklistedDenomsRequest) (*QueryAllBlacklistedDenomsResponse, error)
	// Queries all whitelisted address pairs
	AllWhitelistedAddresses(context.Context, *QueryAllWhitelistedAddressesRequest) (*QueryAllWhitelistedAddressesResponse, error)
}

QueryServer is the server API for Query service.

type Quota

type Quota struct {
	// MaxPercentSend defines the threshold for outflows
	// The threshold is defined as a percentage (e.g. 10 indicates 10%)
	MaxPercentSend cosmossdk_io_math.Int `` /* 128-byte string literal not displayed */
	// MaxPercentSend defines the threshold for inflows
	// The threshold is defined as a percentage (e.g. 10 indicates 10%)
	MaxPercentRecv cosmossdk_io_math.Int `` /* 128-byte string literal not displayed */
	// DurationHours specifies the number of hours before the rate limit
	// is reset (e.g. 24 indicates that the rate limit is reset each day)
	DurationHours uint64 `protobuf:"varint,3,opt,name=duration_hours,json=durationHours,proto3" json:"duration_hours,omitempty"`
}

Quota defines the rate limit thresholds for transfer packets

func (*Quota) CheckExceedsQuota

func (q *Quota) CheckExceedsQuota(direction PacketDirection, amount sdkmath.Int, totalValue sdkmath.Int) bool

CheckExceedsQuota checks if new in/out flow is going to reach the max in/out or not

func (*Quota) Descriptor

func (*Quota) Descriptor() ([]byte, []int)

func (*Quota) GetDurationHours

func (m *Quota) GetDurationHours() uint64

func (*Quota) Marshal

func (m *Quota) Marshal() (dAtA []byte, err error)

func (*Quota) MarshalTo

func (m *Quota) MarshalTo(dAtA []byte) (int, error)

func (*Quota) MarshalToSizedBuffer

func (m *Quota) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*Quota) ProtoMessage

func (*Quota) ProtoMessage()

func (*Quota) Reset

func (m *Quota) Reset()

func (*Quota) Size

func (m *Quota) Size() (n int)

func (*Quota) String

func (m *Quota) String() string

func (*Quota) Unmarshal

func (m *Quota) Unmarshal(dAtA []byte) error

func (*Quota) XXX_DiscardUnknown

func (m *Quota) XXX_DiscardUnknown()

func (*Quota) XXX_Marshal

func (m *Quota) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*Quota) XXX_Merge

func (m *Quota) XXX_Merge(src proto.Message)

func (*Quota) XXX_Size

func (m *Quota) XXX_Size() int

func (*Quota) XXX_Unmarshal

func (m *Quota) XXX_Unmarshal(b []byte) error

type RateLimit

type RateLimit struct {
	Path  *Path  `protobuf:"bytes,1,opt,name=path,proto3" json:"path,omitempty"`
	Quota *Quota `protobuf:"bytes,2,opt,name=quota,proto3" json:"quota,omitempty"`
	Flow  *Flow  `protobuf:"bytes,3,opt,name=flow,proto3" json:"flow,omitempty"`
}

RateLimit stores all the context about a given rate limit, including the relevant denom and channel, rate limit thresholds, and current progress towards the limits

func (*RateLimit) Descriptor

func (*RateLimit) Descriptor() ([]byte, []int)

func (*RateLimit) GetFlow

func (m *RateLimit) GetFlow() *Flow

func (*RateLimit) GetPath

func (m *RateLimit) GetPath() *Path

func (*RateLimit) GetQuota

func (m *RateLimit) GetQuota() *Quota

func (*RateLimit) Marshal

func (m *RateLimit) Marshal() (dAtA []byte, err error)

func (*RateLimit) MarshalTo

func (m *RateLimit) MarshalTo(dAtA []byte) (int, error)

func (*RateLimit) MarshalToSizedBuffer

func (m *RateLimit) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*RateLimit) ProtoMessage

func (*RateLimit) ProtoMessage()

func (*RateLimit) Reset

func (m *RateLimit) Reset()

func (*RateLimit) Size

func (m *RateLimit) Size() (n int)

func (*RateLimit) String

func (m *RateLimit) String() string

func (*RateLimit) Unmarshal

func (m *RateLimit) Unmarshal(dAtA []byte) error

func (*RateLimit) XXX_DiscardUnknown

func (m *RateLimit) XXX_DiscardUnknown()

func (*RateLimit) XXX_Marshal

func (m *RateLimit) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*RateLimit) XXX_Merge

func (m *RateLimit) XXX_Merge(src proto.Message)

func (*RateLimit) XXX_Size

func (m *RateLimit) XXX_Size() int

func (*RateLimit) XXX_Unmarshal

func (m *RateLimit) XXX_Unmarshal(b []byte) error

type UnimplementedMsgServer

type UnimplementedMsgServer struct {
}

UnimplementedMsgServer can be embedded to have forward compatible implementations.

func (*UnimplementedMsgServer) AddRateLimit

func (*UnimplementedMsgServer) RemoveRateLimit

func (*UnimplementedMsgServer) ResetRateLimit

func (*UnimplementedMsgServer) UpdateRateLimit

type UnimplementedQueryServer

type UnimplementedQueryServer struct {
}

UnimplementedQueryServer can be embedded to have forward compatible implementations.

func (*UnimplementedQueryServer) AllRateLimits

func (*UnimplementedQueryServer) RateLimit

func (*UnimplementedQueryServer) RateLimitsByChainId

type WhitelistedAddressPair

type WhitelistedAddressPair struct {
	Sender   string `protobuf:"bytes,1,opt,name=sender,proto3" json:"sender,omitempty"`
	Receiver string `protobuf:"bytes,2,opt,name=receiver,proto3" json:"receiver,omitempty"`
}

WhitelistedAddressPair represents a sender-receiver combo that is not subject to rate limit restrictions

func (*WhitelistedAddressPair) Descriptor

func (*WhitelistedAddressPair) Descriptor() ([]byte, []int)

func (*WhitelistedAddressPair) GetReceiver

func (m *WhitelistedAddressPair) GetReceiver() string

func (*WhitelistedAddressPair) GetSender

func (m *WhitelistedAddressPair) GetSender() string

func (*WhitelistedAddressPair) Marshal

func (m *WhitelistedAddressPair) Marshal() (dAtA []byte, err error)

func (*WhitelistedAddressPair) MarshalTo

func (m *WhitelistedAddressPair) MarshalTo(dAtA []byte) (int, error)

func (*WhitelistedAddressPair) MarshalToSizedBuffer

func (m *WhitelistedAddressPair) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*WhitelistedAddressPair) ProtoMessage

func (*WhitelistedAddressPair) ProtoMessage()

func (*WhitelistedAddressPair) Reset

func (m *WhitelistedAddressPair) Reset()

func (*WhitelistedAddressPair) Size

func (m *WhitelistedAddressPair) Size() (n int)

func (*WhitelistedAddressPair) String

func (m *WhitelistedAddressPair) String() string

func (*WhitelistedAddressPair) Unmarshal

func (m *WhitelistedAddressPair) Unmarshal(dAtA []byte) error

func (*WhitelistedAddressPair) XXX_DiscardUnknown

func (m *WhitelistedAddressPair) XXX_DiscardUnknown()

func (*WhitelistedAddressPair) XXX_Marshal

func (m *WhitelistedAddressPair) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*WhitelistedAddressPair) XXX_Merge

func (m *WhitelistedAddressPair) XXX_Merge(src proto.Message)

func (*WhitelistedAddressPair) XXX_Size

func (m *WhitelistedAddressPair) XXX_Size() int

func (*WhitelistedAddressPair) XXX_Unmarshal

func (m *WhitelistedAddressPair) XXX_Unmarshal(b []byte) error

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL