Documentation ¶
Overview ¶
nolint
Index ¶
- Constants
- Variables
- func EndBlocker(ctx sdk.Context, k keeper.Keeper) (validatorUpdates []abci.ValidatorUpdate, ...)
- func EndBreatheBlock(ctx sdk.Context, k keeper.Keeper) (validatorUpdates []abci.ValidatorUpdate, ...)
- func InitGenesis(ctx sdk.Context, keeper Keeper, data types.GenesisState) (res []abci.ValidatorUpdate, err error)
- func NewHandler(k keeper.Keeper, govKeeper gov.Keeper) sdk.Handler
- func NewStakeHandler(k Keeper) sdk.Handler
- func ValidateGenesis(data types.GenesisState) error
- func WriteGenesis(ctx sdk.Context, keeper Keeper) types.GenesisState
- func WriteValidators(ctx sdk.Context, keeper Keeper) (vals []tmtypes.GenesisValidator)
- type BaseParams
- type ChainDelegateEvent
- type ChainRedelegateEvent
- type ChainUndelegateEvent
- type Commission
- type CompletedREDEvent
- type CompletedUBDEvent
- type CreateValidatorJsonMsg
- type DVPair
- type DVVTriplet
- type DelegateEvent
- type Delegation
- type DelegationRemovedEvent
- type DelegationUpdateEvent
- type Description
- type DistributionData
- type DistributionEvent
- type ElectedValidatorsEvent
- type GenesisState
- type Keeper
- type MsgBeginUnbonding
- type MsgCreateSideChainValidator
- type MsgCreateValidator
- func NewTestMsgCreateValidator(address sdk.ValAddress, pubKey crypto.PubKey, amt int64) MsgCreateValidator
- func NewTestMsgCreateValidatorOnBehalfOf(delAddr sdk.AccAddress, valAddr sdk.ValAddress, valPubKey crypto.PubKey, ...) MsgCreateValidator
- func NewTestMsgCreateValidatorWithCommission(address sdk.ValAddress, pubKey crypto.PubKey, amt int64, ...) MsgCreateValidator
- type MsgCreateValidatorOpen
- type MsgCreateValidatorProposal
- type MsgDelegate
- type MsgEditSideChainValidator
- type MsgEditValidator
- type MsgRedelegate
- type MsgRemoveValidator
- type MsgSideChainDelegate
- type MsgSideChainRedelegate
- type MsgSideChainUndelegate
- type MsgUndelegate
- type Params
- type Pool
- type QueryBondsParams
- type QueryCrossStakeInfoParams
- type QueryDelegatorParams
- type QueryTopValidatorsParams
- type QueryValidatorParams
- type REDUpdateEvent
- type RedelegateEvent
- type Redelegation
- type UBDUpdateEvent
- type UnbondingDelegation
- type UndelegateEvent
- type Validator
- type ValidatorRemovedEvent
- type ValidatorUpdateEvent
Constants ¶
const ( QueryValidators = querier.QueryValidators QueryValidator = querier.QueryValidator QueryValidatorUnbondingDelegations = querier.QueryValidatorUnbondingDelegations QueryValidatorRedelegations = querier.QueryValidatorRedelegations QueryDelegation = querier.QueryDelegation QueryUnbondingDelegation = querier.QueryUnbondingDelegation QueryDelegatorDelegations = querier.QueryDelegatorDelegations QueryDelegatorUnbondingDelegations = querier.QueryDelegatorUnbondingDelegations QueryDelegatorRedelegations = querier.QueryDelegatorRedelegations QueryDelegatorValidators = querier.QueryDelegatorValidators QueryDelegatorValidator = querier.QueryDelegatorValidator QueryPool = querier.QueryPool QueryParameters = querier.QueryParameters QueryCrossStakeInfo = querier.QueryCrossStakeInfoByAscAddress Topic = types.Topic )
const ( DefaultCodespace = types.DefaultCodespace CodeInvalidValidator = types.CodeInvalidValidator CodeInvalidDelegation = types.CodeInvalidDelegation CodeInvalidInput = types.CodeInvalidInput CodeValidatorJailed = types.CodeValidatorJailed CodeInternal = types.CodeInternal CodeUnknownRequest = types.CodeUnknownRequest ChainIDForFlashChain = types.ChainIDForFlashChain )
Variables ¶
var ( NewKeeper = keeper.NewKeeper GetValidatorKey = keeper.GetValidatorKey GetValidatorByConsAddrKey = keeper.GetValidatorByConsAddrKey GetValidatorsByPowerIndexKey = keeper.GetValidatorsByPowerIndexKey GetDelegationKey = keeper.GetDelegationKey GetDelegationsKey = keeper.GetDelegationsKey PoolKey = keeper.PoolKey IntraTxCounterKey = keeper.IntraTxCounterKey LastValidatorPowerKey = keeper.LastValidatorPowerKey LastTotalPowerKey = keeper.LastTotalPowerKey ValidatorsKey = keeper.ValidatorsKey ValidatorsByConsAddrKey = keeper.ValidatorsByConsAddrKey ValidatorsByPowerIndexKey = keeper.ValidatorsByPowerIndexKey DelegationKey = keeper.DelegationKey GetUBDKey = keeper.GetUBDKey GetUBDByValIndexKey = keeper.GetUBDByValIndexKey GetUBDsKey = keeper.GetUBDsKey GetUBDsByValIndexKey = keeper.GetUBDsByValIndexKey GetREDKey = keeper.GetREDKey GetREDByValSrcIndexKey = keeper.GetREDByValSrcIndexKey GetREDByValDstIndexKey = keeper.GetREDByValDstIndexKey GetREDsKey = keeper.GetREDsKey GetREDsFromValSrcIndexKey = keeper.GetREDsFromValSrcIndexKey GetREDsToValDstIndexKey = keeper.GetREDsToValDstIndexKey GetREDsByDelToValDstIndexKey = keeper.GetREDsByDelToValDstIndexKey TestingUpdateValidator = keeper.TestingUpdateValidator MigratePowerRankKey = keeper.MigratePowerRankKey MigrateValidatorDistributionAddr = keeper.MigrateValidators MigrateWhiteLabelOracleRelayer = keeper.MigrateWhiteLabelOracleRelayer DefaultParamspace = keeper.DefaultParamspace KeyUnbondingTime = types.KeyUnbondingTime KeyMaxValidators = types.KeyMaxValidators KeyBondDenom = types.KeyBondDenom DefaultParams = types.DefaultParams InitialPool = types.InitialPool NewValidator = types.NewValidator NewValidatorWithFeeAddr = types.NewValidatorWithFeeAddr NewSideChainValidator = types.NewSideChainValidator NewDescription = types.NewDescription NewCommission = types.NewCommission NewCommissionMsg = types.NewCommissionMsg NewCommissionWithTime = types.NewCommissionWithTime NewGenesisState = types.NewGenesisState DefaultGenesisState = types.DefaultGenesisState RegisterCodec = types.RegisterCodec NewMsgCreateValidator = types.NewMsgCreateValidator NewMsgRemoveValidator = types.NewMsgRemoveValidator NewMsgBeginUnbonding = types.NewMsgBeginUnbonding NewMsgCreateValidatorOnBehalfOf = types.NewMsgCreateValidatorOnBehalfOf NewMsgEditValidator = types.NewMsgEditValidator NewMsgDelegate = types.NewMsgDelegate NewMsgUndelegate = types.NewMsgUndelegate NewMsgRedelegate = types.NewMsgRedelegate NewMsgCreateSideChainValidator = types.NewMsgCreateSideChainValidator NewMsgCreateSideChainValidatorOnBehalfOf = types.NewMsgCreateSideChainValidatorOnBehalfOf NewMsgEditSideChainValidator = types.NewMsgEditSideChainValidator NewMsgSideChainDelegate = types.NewMsgSideChainDelegate NewMsgSideChainRedelegate = types.NewMsgSideChainRedelegate NewMsgSideChainUndelegate = types.NewMsgSideChainUndelegate NewQuerier = querier.NewQuerier NewBaseParams = querier.NewBaseParams FeeCollectorAddr = keeper.FeeCollectorAddr DelegationAccAddr = keeper.DelegationAccAddr FeeForAllAccAddr = keeper.FeeForAllFcValsAccAddr )
var ( ErrNilValidatorAddr = types.ErrNilValidatorAddr ErrNoValidatorFound = types.ErrNoValidatorFound ErrValidatorOwnerExists = types.ErrValidatorOwnerExists ErrValidatorPubKeyExists = types.ErrValidatorPubKeyExists ErrValidatorSideConsAddrExist = types.ErrValidatorSideConsAddrExists ErrInvalidDelegator = types.ErrInvalidDelegator ErrValidatorJailed = types.ErrValidatorJailed ErrInvalidProposal = types.ErrInvalidProposal ErrBadRemoveValidator = types.ErrBadRemoveValidator ErrDescriptionLength = types.ErrDescriptionLength ErrCommissionNegative = types.ErrCommissionNegative ErrCommissionHuge = types.ErrCommissionHuge ErrNilDelegatorAddr = types.ErrNilDelegatorAddr ErrBadDenom = types.ErrBadDenom ErrBadDelegationAmount = types.ErrBadDelegationAmount ErrNoDelegation = types.ErrNoDelegation ErrBadDelegatorAddr = types.ErrBadDelegatorAddr ErrNoDelegatorForAddress = types.ErrNoDelegatorForAddress ErrDelegationValidatorEmpty = types.ErrDelegationValidatorEmpty ErrInvalidSideChainId = types.ErrInvalidSideChainId ErrNotMature = types.ErrNotMature ErrNoUnbondingDelegation = types.ErrNoUnbondingDelegation ErrNoRedelegation = types.ErrNoRedelegation ErrBadRedelegationSrc = types.ErrBadRedelegationSrc ErrBadRedelegationDst = types.ErrBadRedelegationDst ErrSelfRedelegation = types.ErrSelfRedelegation ErrInvalidRedelegator = types.ErrInvalidRedelegator ErrNotSelfDelegate = types.ErrNotSelfDelegate ErrMissingSignature = types.ErrMissingSignature ErrInvalidPubKey = types.ErrInvalidPubKey )
Functions ¶
func EndBlocker ¶
func EndBlocker(ctx sdk.Context, k keeper.Keeper) (validatorUpdates []abci.ValidatorUpdate, completedUbds []types.UnbondingDelegation)
func EndBreatheBlock ¶
func EndBreatheBlock(ctx sdk.Context, k keeper.Keeper) (validatorUpdates []abci.ValidatorUpdate, completedUbds []types.UnbondingDelegation)
func InitGenesis ¶
func InitGenesis(ctx sdk.Context, keeper Keeper, data types.GenesisState) (res []abci.ValidatorUpdate, err error)
InitGenesis sets the pool and parameters for the provided keeper and initializes the IntraTxCounter. For each validator in data, it sets that validator in the keeper along with manually setting the indexes. In addition, it also sets any delegations found in data. Finally, it updates the bonded validators. Returns final validator set after applying all declaration and delegations
func NewStakeHandler ¶
func ValidateGenesis ¶
func ValidateGenesis(data types.GenesisState) error
ValidateGenesis validates the provided staking genesis state to ensure the expected invariants holds. (i.e. params in correct bounds, no duplicate validators)
func WriteGenesis ¶
func WriteGenesis(ctx sdk.Context, keeper Keeper) types.GenesisState
WriteGenesis returns a GenesisState for a given context and keeper. The GenesisState will contain the pool, params, validators, and bonds found in the keeper.
func WriteValidators ¶
func WriteValidators(ctx sdk.Context, keeper Keeper) (vals []tmtypes.GenesisValidator)
WriteValidators returns a slice of bonded genesis validators.
Types ¶
type BaseParams ¶
type BaseParams = querier.BaseParams
type ChainDelegateEvent ¶
type ChainDelegateEvent = types.ChainDelegateEvent
type ChainRedelegateEvent ¶
type ChainRedelegateEvent = types.ChainRedelegateEvent
type ChainUndelegateEvent ¶
type ChainUndelegateEvent = types.ChainUndelegateEvent
type Commission ¶
type Commission = types.Commission
type CompletedREDEvent ¶
type CompletedREDEvent = types.CompletedREDEvent
type CompletedUBDEvent ¶
type CompletedUBDEvent = types.CompletedUBDEvent
type CreateValidatorJsonMsg ¶
type CreateValidatorJsonMsg = types.CreateValidatorJsonMsg
type DVVTriplet ¶
type DVVTriplet = types.DVVTriplet
type DelegateEvent ¶
type DelegateEvent = types.DelegateEvent
type Delegation ¶
type Delegation = types.Delegation
type DelegationRemovedEvent ¶
type DelegationRemovedEvent = types.DelegationRemovedEvent
type DelegationUpdateEvent ¶
type DelegationUpdateEvent = types.DelegationUpdateEvent
type Description ¶
type Description = types.Description
type DistributionData ¶
type DistributionData = types.DistributionData
type DistributionEvent ¶
type DistributionEvent = types.DistributionEvent
type ElectedValidatorsEvent ¶
type ElectedValidatorsEvent = types.ElectedValidatorsEvent
type GenesisState ¶
type GenesisState = types.GenesisState
type MsgBeginUnbonding ¶
type MsgBeginUnbonding = types.MsgBeginUnbonding
type MsgCreateSideChainValidator ¶
type MsgCreateSideChainValidator = types.MsgCreateSideChainValidator
type MsgCreateValidator ¶
type MsgCreateValidator = types.MsgCreateValidator
func NewTestMsgCreateValidator ¶
func NewTestMsgCreateValidator(address sdk.ValAddress, pubKey crypto.PubKey, amt int64) MsgCreateValidator
func NewTestMsgCreateValidatorOnBehalfOf ¶
func NewTestMsgCreateValidatorOnBehalfOf(delAddr sdk.AccAddress, valAddr sdk.ValAddress, valPubKey crypto.PubKey, amt int64) MsgCreateValidator
func NewTestMsgCreateValidatorWithCommission ¶
func NewTestMsgCreateValidatorWithCommission(address sdk.ValAddress, pubKey crypto.PubKey, amt int64, commissionRate sdk.Dec) MsgCreateValidator
type MsgCreateValidatorOpen ¶
type MsgCreateValidatorOpen = types.MsgCreateValidatorOpen
type MsgCreateValidatorProposal ¶
type MsgCreateValidatorProposal = types.MsgCreateValidatorProposal
type MsgDelegate ¶
type MsgDelegate = types.MsgDelegate
func NewTestMsgDelegate ¶
func NewTestMsgDelegate(delAddr sdk.AccAddress, valAddr sdk.ValAddress, amt int64) MsgDelegate
type MsgEditSideChainValidator ¶
type MsgEditSideChainValidator = types.MsgEditSideChainValidator
type MsgEditValidator ¶
type MsgEditValidator = types.MsgEditValidator
type MsgRedelegate ¶
type MsgRedelegate = types.MsgRedelegate
type MsgRemoveValidator ¶
type MsgRemoveValidator = types.MsgRemoveValidator
type MsgSideChainDelegate ¶
type MsgSideChainDelegate = types.MsgSideChainDelegate
type MsgSideChainRedelegate ¶
type MsgSideChainRedelegate = types.MsgSideChainRedelegate
type MsgSideChainUndelegate ¶
type MsgSideChainUndelegate = types.MsgSideChainUndelegate
type MsgUndelegate ¶
type MsgUndelegate = types.MsgUndelegate
type QueryBondsParams ¶
type QueryBondsParams = querier.QueryBondsParams
type QueryCrossStakeInfoParams ¶
type QueryCrossStakeInfoParams = querier.QueryCrossStakeInfoParams
type QueryDelegatorParams ¶
type QueryDelegatorParams = querier.QueryDelegatorParams
type QueryTopValidatorsParams ¶
type QueryTopValidatorsParams = querier.QueryTopValidatorsParams
type QueryValidatorParams ¶
type QueryValidatorParams = querier.QueryValidatorParams
type REDUpdateEvent ¶
type REDUpdateEvent = types.REDUpdateEvent
type RedelegateEvent ¶
type RedelegateEvent = types.RedelegateEvent
type Redelegation ¶
type Redelegation = types.Redelegation
type UBDUpdateEvent ¶
type UBDUpdateEvent = types.UBDUpdateEvent
type UnbondingDelegation ¶
type UnbondingDelegation = types.UnbondingDelegation
type UndelegateEvent ¶
type UndelegateEvent = types.UndelegateEvent
type ValidatorRemovedEvent ¶
type ValidatorRemovedEvent = types.ValidatorRemovedEvent
type ValidatorUpdateEvent ¶
type ValidatorUpdateEvent = types.ValidatorUpdateEvent