Documentation ¶
Overview ¶
nolint autogenerated code using github.com/rigelrozanski/multitool aliases generated for the following subdirectories:
Index ¶
- Constants
- Variables
- func EndBlocker(ctx sdk.Context, k keeper.Keeper)
- func InitGenesis(ctx sdk.Context, k keeper.Keeper, supplyKeeper keeper.SupplyKeeper, ...)
- func ModuleAccountInvariant(keeper keeper.Keeper) sdk.Invariant
- func NewHandler(keeper Keeper) sdk.Handler
- func RegisterInvariants(ir sdk.InvariantRegistry, keeper keeper.Keeper)
- func ValidateGenesis(data GenesisState) error
- type AppModule
- func (AppModule) BeginBlock(_ sdk.Context, _ abci.RequestBeginBlock)
- func (am AppModule) EndBlock(ctx sdk.Context, _ abci.RequestEndBlock) []abci.ValidatorUpdate
- func (am AppModule) ExportGenesis(ctx sdk.Context) json.RawMessage
- func (AppModule) GenerateGenesisState(simState *module.SimulationState)
- func (am AppModule) InitGenesis(ctx sdk.Context, data json.RawMessage) []abci.ValidatorUpdate
- func (AppModule) Name() string
- func (am AppModule) NewHandler() sdk.Handler
- func (am AppModule) NewQuerierHandler() sdk.Querier
- func (AppModule) ProposalContents(_ module.SimulationState) []sim.WeightedProposalContent
- func (AppModule) QuerierRoute() string
- func (AppModule) RandomizedParams(r *rand.Rand) []sim.ParamChange
- func (am AppModule) RegisterInvariants(ir sdk.InvariantRegistry)
- func (AppModule) RegisterStoreDecoder(sdr sdk.StoreDecoderRegistry)
- func (AppModule) Route() string
- func (am AppModule) WeightedOperations(simState module.SimulationState) []sim.WeightedOperation
- type AppModuleBasic
- func (AppModuleBasic) DefaultGenesis() json.RawMessage
- func (AppModuleBasic) GetQueryCmd(cdc *codec.Codec) *cobra.Command
- func (a AppModuleBasic) GetTxCmd(cdc *codec.Codec) *cobra.Command
- func (AppModuleBasic) Name() string
- func (AppModuleBasic) RegisterCodec(cdc *codec.Codec)
- func (a AppModuleBasic) RegisterRESTRoutes(ctx context.CLIContext, rtr *mux.Router)
- func (AppModuleBasic) ValidateGenesis(bz json.RawMessage) error
- type Content
- type Deposit
- type DepositParams
- type Deposits
- type GenesisState
- type Handler
- type Keeper
- type MsgDeposit
- type MsgSubmitProposal
- type MsgVote
- type Params
- type Proposal
- type ProposalStatus
- type Proposals
- type TallyParams
- type TallyResult
- type Vote
- type Votes
- type VotingParams
Constants ¶
const ( ModuleName = types.ModuleName StoreKey = types.StoreKey RouterKey = types.RouterKey DefaultParamspace = types.DefaultParamspace ProposalTypeText = types.ProposalTypeText QueryParams = types.QueryParams StatusNil = types.StatusNil StatusDepositPeriod = types.StatusDepositPeriod StatusVotingPeriod = types.StatusVotingPeriod StatusPassed = types.StatusPassed StatusRejected = types.StatusRejected StatusFailed = types.StatusFailed )
Variables ¶
var ( // functions aliases RegisterCodec = types.RegisterCodec RegisterProposalTypeCodec = types.RegisterProposalTypeCodec ErrInvalidProposer = types.ErrInvalidProposer ErrInvalidHeight = types.ErrInvalidHeight ErrInvalidProposalContent = types.ErrInvalidProposalContent ErrInvalidProposalType = types.ErrInvalidProposalType ErrInvalidGenesis = types.ErrInvalidGenesis ErrNoProposalHandlerExists = types.ErrNoProposalHandlerExists ProposalKey = types.ProposalKey ActiveProposalByTimeKey = types.ActiveProposalByTimeKey ActiveProposalQueueKey = types.ActiveProposalQueueKey InactiveProposalByTimeKey = types.InactiveProposalByTimeKey InactiveProposalQueueKey = types.InactiveProposalQueueKey DepositKey = types.DepositKey VoteKey = types.VoteKey NewMsgSubmitProposal = types.NewMsgSubmitProposal NewMsgDeposit = types.NewMsgDeposit NewMsgVote = types.NewMsgVote ParamKeyTable = types.ParamKeyTable NewDepositParams = types.NewDepositParams NewTallyParams = types.NewTallyParams NewVotingParams = types.NewVotingParams NewParams = types.NewParams NewTallyResultFromMap = types.NewTallyResultFromMap EmptyTallyResult = types.EmptyTallyResult NewTextProposal = types.NewTextProposal RegisterProposalType = types.RegisterProposalType ContentFromProposalType = types.ContentFromProposalType IsValidProposalType = types.IsValidProposalType ProposalHandler = types.ProposalHandler NewQueryProposalParams = types.NewQueryProposalParams NewQueryDepositParams = types.NewQueryDepositParams NewQueryVoteParams = types.NewQueryVoteParams NewQueryProposalsParams = types.NewQueryProposalsParams // variable aliases ModuleCdc = types.ModuleCdc ProposalsKeyPrefix = types.ProposalsKeyPrefix ActiveProposalQueuePrefix = types.ActiveProposalQueuePrefix InactiveProposalQueuePrefix = types.InactiveProposalQueuePrefix ProposalIDKey = types.ProposalIDKey DepositsKeyPrefix = types.DepositsKeyPrefix VotesKeyPrefix = types.VotesKeyPrefix ParamStoreKeyDepositParams = types.ParamStoreKeyDepositParams ParamStoreKeyVotingParams = types.ParamStoreKeyVotingParams ParamStoreKeyTallyParams = types.ParamStoreKeyTallyParams NewKeeper = keeper.NewKeeper NewQuerier = keeper.NewQuerier NewRouter = keeper.NewRouter )
Functions ¶
func EndBlocker ¶
EndBlocker called every block, process inflation, update validator set.
func InitGenesis ¶
func InitGenesis(ctx sdk.Context, k keeper.Keeper, supplyKeeper keeper.SupplyKeeper, data GenesisState)
InitGenesis - store genesis parameters
func ModuleAccountInvariant ¶
ModuleAccountInvariant checks that the module account coins reflects the sum of deposit amounts held on store
func NewHandler ¶
NewHandler handle all "gov" type messages.
func RegisterInvariants ¶
func RegisterInvariants(ir sdk.InvariantRegistry, keeper keeper.Keeper)
RegisterInvariants registers all governance invariants
func ValidateGenesis ¶
func ValidateGenesis(data GenesisState) error
ValidateGenesis checks if parameters are within valid ranges
Types ¶
type AppModule ¶
type AppModule struct { AppModuleBasic // contains filtered or unexported fields }
AppModule defines app module
func NewAppModule ¶
func NewAppModule(keeper Keeper, supplyKeeper keeper.SupplyKeeper) AppModule
NewAppModule creates a new AppModule object
func (AppModule) BeginBlock ¶
func (AppModule) BeginBlock(_ sdk.Context, _ abci.RequestBeginBlock)
BeginBlock implements module begin-block
func (AppModule) EndBlock ¶
func (am AppModule) EndBlock(ctx sdk.Context, _ abci.RequestEndBlock) []abci.ValidatorUpdate
EndBlock implements module end-block
func (AppModule) ExportGenesis ¶
func (am AppModule) ExportGenesis(ctx sdk.Context) json.RawMessage
ExportGenesis exports module genesis
func (AppModule) GenerateGenesisState ¶
func (AppModule) GenerateGenesisState(simState *module.SimulationState)
GenerateGenesisState creates a randomized GenState of the staking module.
func (AppModule) InitGenesis ¶
func (am AppModule) InitGenesis(ctx sdk.Context, data json.RawMessage) []abci.ValidatorUpdate
InitGenesis inits module genesis
func (AppModule) NewHandler ¶
NewHandler gets module handler
func (AppModule) NewQuerierHandler ¶
NewQuerierHandler gets module querier
func (AppModule) ProposalContents ¶
func (AppModule) ProposalContents(_ module.SimulationState) []sim.WeightedProposalContent
ProposalContents doesn't return any content functions for governance proposals.
func (AppModule) QuerierRoute ¶
QuerierRoute module querier route name
func (AppModule) RandomizedParams ¶
func (AppModule) RandomizedParams(r *rand.Rand) []sim.ParamChange
RandomizedParams creates randomized staking param changes for the simulator.
func (AppModule) RegisterInvariants ¶
func (am AppModule) RegisterInvariants(ir sdk.InvariantRegistry)
RegisterInvariants registers invariants
func (AppModule) RegisterStoreDecoder ¶
func (AppModule) RegisterStoreDecoder(sdr sdk.StoreDecoderRegistry)
RegisterStoreDecoder registers a decoder for staking module's types
func (AppModule) WeightedOperations ¶
func (am AppModule) WeightedOperations(simState module.SimulationState) []sim.WeightedOperation
WeightedOperations returns the all the staking module operations with their respective weights.
type AppModuleBasic ¶
type AppModuleBasic struct {
// contains filtered or unexported fields
}
AppModuleBasic defines app module basics object
func NewAppModuleBasic ¶
func NewAppModuleBasic(proposalHandlers ...client.ProposalHandler) AppModuleBasic
NewAppModuleBasic creates a new AppModuleBasic object
func (AppModuleBasic) DefaultGenesis ¶
func (AppModuleBasic) DefaultGenesis() json.RawMessage
DefaultGenesis sets default genesis state
func (AppModuleBasic) GetQueryCmd ¶
func (AppModuleBasic) GetQueryCmd(cdc *codec.Codec) *cobra.Command
GetQueryCmd gets the root query command of this module
func (AppModuleBasic) GetTxCmd ¶
func (a AppModuleBasic) GetTxCmd(cdc *codec.Codec) *cobra.Command
GetTxCmd gets the root tx command of this module
func (AppModuleBasic) RegisterCodec ¶
func (AppModuleBasic) RegisterCodec(cdc *codec.Codec)
RegisterCodec registers module codec
func (AppModuleBasic) RegisterRESTRoutes ¶
func (a AppModuleBasic) RegisterRESTRoutes(ctx context.CLIContext, rtr *mux.Router)
RegisterRESTRoutes registers rest routes
func (AppModuleBasic) ValidateGenesis ¶
func (AppModuleBasic) ValidateGenesis(bz json.RawMessage) error
ValidateGenesis validates module genesis
type DepositParams ¶
type DepositParams = types.DepositParams
type GenesisState ¶
type GenesisState struct { StartingProposalID uint64 `json:"starting_proposal_id" yaml:"starting_proposal_id"` Deposits Deposits `json:"deposits" yaml:"deposits"` Votes Votes `json:"votes" yaml:"votes"` Proposals []Proposal `json:"proposals" yaml:"proposals"` WaitingProposals map[string]uint64 `json:"waiting_proposals" yaml:"waiting_proposals"` DepositParams DepositParams `json:"deposit_params" yaml:"deposit_params"` VotingParams VotingParams `json:"voting_params" yaml:"voting_params"` TallyParams TallyParams `json:"tally_params" yaml:"tally_params"` }
GenesisState - all staking state that must be provided at genesis
func DefaultGenesisState ¶
func DefaultGenesisState() GenesisState
DefaultGenesisState get raw genesis raw message for testing
func ExportGenesis ¶
func ExportGenesis(ctx sdk.Context, k keeper.Keeper) GenesisState
ExportGenesis - output genesis parameters
type MsgDeposit ¶
type MsgDeposit = types.MsgDeposit
type MsgSubmitProposal ¶
type MsgSubmitProposal = types.MsgSubmitProposal
type ProposalStatus ¶
type ProposalStatus = types.ProposalStatus
type TallyParams ¶
type TallyParams = types.TallyParams
type TallyResult ¶
type TallyResult = types.TallyResult
type VotingParams ¶
type VotingParams = types.VotingParams