Documentation ¶
Index ¶
- Constants
- Variables
- func ParamKeyTable() paramtypes.KeyTable
- func RegisterCodec(cdc *codec.Codec)
- func RegisterInterfaces(registry codectypes.InterfaceRegistry)
- func ValidateGenesis(data GenesisState) error
- type GenesisState
- type InvarRoute
- type MsgVerifyInvariant
- func (*MsgVerifyInvariant) Descriptor() ([]byte, []int)
- func (this *MsgVerifyInvariant) Equal(that interface{}) bool
- func (msg MsgVerifyInvariant) FullInvariantRoute() string
- func (m *MsgVerifyInvariant) GetInvariantModuleName() string
- func (m *MsgVerifyInvariant) GetInvariantRoute() string
- func (m *MsgVerifyInvariant) GetSender() github_com_cosmos_cosmos_sdk_types.AccAddress
- func (msg MsgVerifyInvariant) GetSignBytes() []byte
- func (msg MsgVerifyInvariant) GetSigners() []sdk.AccAddress
- func (m *MsgVerifyInvariant) Marshal() (dAtA []byte, err error)
- func (m *MsgVerifyInvariant) MarshalTo(dAtA []byte) (int, error)
- func (m *MsgVerifyInvariant) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*MsgVerifyInvariant) ProtoMessage()
- func (m *MsgVerifyInvariant) Reset()
- func (msg MsgVerifyInvariant) Route() string
- func (m *MsgVerifyInvariant) Size() (n int)
- func (m *MsgVerifyInvariant) String() string
- func (msg MsgVerifyInvariant) Type() string
- func (m *MsgVerifyInvariant) Unmarshal(dAtA []byte) error
- func (msg MsgVerifyInvariant) ValidateBasic() error
- func (m *MsgVerifyInvariant) XXX_DiscardUnknown()
- func (m *MsgVerifyInvariant) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *MsgVerifyInvariant) XXX_Merge(src proto.Message)
- func (m *MsgVerifyInvariant) XXX_Size() int
- func (m *MsgVerifyInvariant) XXX_Unmarshal(b []byte) error
- type SupplyKeeper
Constants ¶
const ( EventTypeInvariant = "invariant" AttributeValueCrisis = ModuleName AttributeKeyRoute = "route" )
crisis module event types
const (
// module name
ModuleName = "crisis"
)
Variables ¶
var ( ErrInvalidLengthCrisis = fmt.Errorf("proto: negative length found during unmarshaling") ErrIntOverflowCrisis = fmt.Errorf("proto: integer overflow") ErrUnexpectedEndOfGroupCrisis = fmt.Errorf("proto: unexpected end of group") )
var ( ErrNoSender = sdkerrors.Register(ModuleName, 2, "sender address is empty") ErrUnknownInvariant = sdkerrors.Register(ModuleName, 3, "unknown invariant") )
x/crisis module sentinel errors
var ( // ModuleCdc references the global x/crisis module codec. Note, the codec should // ONLY be used in certain instances of tests and for JSON encoding as Amino is // still used for that purpose. // // The actual codec used for serialization should be provided to x/crisis and // defined at the application level. ModuleCdc = codec.NewHybridCodec(amino, codectypes.NewInterfaceRegistry()) )
var ( // key for constant fee parameter ParamStoreKeyConstantFee = []byte("ConstantFee") )
Functions ¶
func RegisterCodec ¶
RegisterCodec registers the necessary x/crisis interfaces and concrete types on the provided Amino codec. These types are used for Amino JSON serialization.
func RegisterInterfaces ¶
func RegisterInterfaces(registry codectypes.InterfaceRegistry)
func ValidateGenesis ¶
func ValidateGenesis(data GenesisState) error
ValidateGenesis - validate crisis genesis data
Types ¶
type GenesisState ¶
GenesisState - crisis genesis state
func DefaultGenesisState ¶
func DefaultGenesisState() GenesisState
DefaultGenesisState creates a default GenesisState object
func NewGenesisState ¶
func NewGenesisState(constantFee sdk.Coin) GenesisState
NewGenesisState creates a new GenesisState object
type InvarRoute ¶
invariant route
func NewInvarRoute ¶
func NewInvarRoute(moduleName, route string, invar sdk.Invariant) InvarRoute
NewInvarRoute - create an InvarRoute object
type MsgVerifyInvariant ¶
type MsgVerifyInvariant struct { Sender github_com_cosmos_cosmos_sdk_types.AccAddress `protobuf:"bytes,1,opt,name=sender,proto3,casttype=github.com/cosmos/cosmos-sdk/types.AccAddress" json:"sender,omitempty"` InvariantModuleName string `` /* 149-byte string literal not displayed */ InvariantRoute string `` /* 126-byte string literal not displayed */ }
MsgVerifyInvariant - message struct to verify a particular invariance
func NewMsgVerifyInvariant ¶
func NewMsgVerifyInvariant(sender sdk.AccAddress, invModeName, invRoute string) *MsgVerifyInvariant
NewMsgVerifyInvariant creates a new MsgVerifyInvariant object
func (*MsgVerifyInvariant) Descriptor ¶
func (*MsgVerifyInvariant) Descriptor() ([]byte, []int)
func (*MsgVerifyInvariant) Equal ¶
func (this *MsgVerifyInvariant) Equal(that interface{}) bool
func (MsgVerifyInvariant) FullInvariantRoute ¶
func (msg MsgVerifyInvariant) FullInvariantRoute() string
FullInvariantRoute - get the messages full invariant route
func (*MsgVerifyInvariant) GetInvariantModuleName ¶
func (m *MsgVerifyInvariant) GetInvariantModuleName() string
func (*MsgVerifyInvariant) GetInvariantRoute ¶
func (m *MsgVerifyInvariant) GetInvariantRoute() string
func (*MsgVerifyInvariant) GetSender ¶
func (m *MsgVerifyInvariant) GetSender() github_com_cosmos_cosmos_sdk_types.AccAddress
func (MsgVerifyInvariant) GetSignBytes ¶
func (msg MsgVerifyInvariant) GetSignBytes() []byte
GetSignBytes gets the sign bytes for the msg MsgVerifyInvariant
func (MsgVerifyInvariant) GetSigners ¶
func (msg MsgVerifyInvariant) GetSigners() []sdk.AccAddress
get the bytes for the message signer to sign on
func (*MsgVerifyInvariant) Marshal ¶
func (m *MsgVerifyInvariant) Marshal() (dAtA []byte, err error)
func (*MsgVerifyInvariant) MarshalTo ¶
func (m *MsgVerifyInvariant) MarshalTo(dAtA []byte) (int, error)
func (*MsgVerifyInvariant) MarshalToSizedBuffer ¶
func (m *MsgVerifyInvariant) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*MsgVerifyInvariant) ProtoMessage ¶
func (*MsgVerifyInvariant) ProtoMessage()
func (*MsgVerifyInvariant) Reset ¶
func (m *MsgVerifyInvariant) Reset()
func (MsgVerifyInvariant) Route ¶
func (msg MsgVerifyInvariant) Route() string
func (*MsgVerifyInvariant) Size ¶
func (m *MsgVerifyInvariant) Size() (n int)
func (*MsgVerifyInvariant) String ¶
func (m *MsgVerifyInvariant) String() string
func (MsgVerifyInvariant) Type ¶
func (msg MsgVerifyInvariant) Type() string
func (*MsgVerifyInvariant) Unmarshal ¶
func (m *MsgVerifyInvariant) Unmarshal(dAtA []byte) error
func (MsgVerifyInvariant) ValidateBasic ¶
func (msg MsgVerifyInvariant) ValidateBasic() error
quick validity check
func (*MsgVerifyInvariant) XXX_DiscardUnknown ¶
func (m *MsgVerifyInvariant) XXX_DiscardUnknown()
func (*MsgVerifyInvariant) XXX_Marshal ¶
func (m *MsgVerifyInvariant) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*MsgVerifyInvariant) XXX_Merge ¶
func (m *MsgVerifyInvariant) XXX_Merge(src proto.Message)
func (*MsgVerifyInvariant) XXX_Size ¶
func (m *MsgVerifyInvariant) XXX_Size() int
func (*MsgVerifyInvariant) XXX_Unmarshal ¶
func (m *MsgVerifyInvariant) XXX_Unmarshal(b []byte) error
type SupplyKeeper ¶
type SupplyKeeper interface {
SendCoinsFromAccountToModule(ctx sdk.Context, senderAddr sdk.AccAddress, recipientModule string, amt sdk.Coins) error
}
SupplyKeeper defines the expected supply keeper (noalias)