simulation

package
v0.48.86 Latest Latest
Warning

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

Go to latest
Published: Oct 24, 2023 License: Apache-2.0 Imports: 17 Imported by: 0

Documentation

Index

Constants

View Source
const (
	DefaultWeightMsgCreateValidator           int = 100
	DefaultWeightMsgEditValidator             int = 5
	DefaultWeightMsgDelegate                  int = 100
	DefaultWeightMsgUndelegate                int = 100
	DefaultWeightMsgBeginRedelegate           int = 100
	DefaultWeightMsgCancelUnbondingDelegation int = 100

	OpWeightMsgCreateValidator           = "op_weight_msg_create_validator"
	OpWeightMsgEditValidator             = "op_weight_msg_edit_validator"
	OpWeightMsgDelegate                  = "op_weight_msg_delegate"
	OpWeightMsgUndelegate                = "op_weight_msg_undelegate"
	OpWeightMsgBeginRedelegate           = "op_weight_msg_begin_redelegate"
	OpWeightMsgCancelUnbondingDelegation = "op_weight_msg_cancel_unbonding_delegation"
)

Simulation operation weights constants

Variables

This section is empty.

Functions

func NewDecodeStore added in v0.48.84

func NewDecodeStore(cdc codec.Codec) func(kvA, kvB kv.Pair) string

NewDecodeStore returns a decoder function closure that unmarshals the KVPair's Value to the corresponding staking type.

func ParamChanges added in v0.48.84

func ParamChanges(r *rand.Rand) []simtypes.ParamChange

ParamChanges defines the parameters that can be modified by param change proposals on the simulation

func RandomizedGenState added in v0.48.84

func RandomizedGenState(simState *module.SimulationState)

RandomizedGenState generates a random GenesisState for staking

func SimulateMsgBeginRedelegate

func SimulateMsgBeginRedelegate(ak types.AccountKeeper, bk types.BankKeeper, k *keeper.Keeper) simtypes.Operation

SimulateMsgBeginRedelegate generates a MsgBeginRedelegate with random values

func SimulateMsgCancelUnbondingDelegate added in v0.48.84

func SimulateMsgCancelUnbondingDelegate(ak types.AccountKeeper, bk types.BankKeeper, k *keeper.Keeper) simtypes.Operation

SimulateMsgCancelUnbondingDelegate generates a MsgCancelUnbondingDelegate with random values

func SimulateMsgCreateValidator

func SimulateMsgCreateValidator(ak types.AccountKeeper, bk types.BankKeeper, k *keeper.Keeper) simtypes.Operation

SimulateMsgCreateValidator generates a MsgCreateValidator with random values

func SimulateMsgDelegate

func SimulateMsgDelegate(ak types.AccountKeeper, bk types.BankKeeper, k *keeper.Keeper) simtypes.Operation

SimulateMsgDelegate generates a MsgDelegate with random values

func SimulateMsgEditValidator

func SimulateMsgEditValidator(ak types.AccountKeeper, bk types.BankKeeper, k *keeper.Keeper) simtypes.Operation

SimulateMsgEditValidator generates a MsgEditValidator with random values

func SimulateMsgUndelegate

func SimulateMsgUndelegate(ak types.AccountKeeper, bk types.BankKeeper, k *keeper.Keeper) simtypes.Operation

SimulateMsgUndelegate generates a MsgUndelegate with random values

func WeightedOperations added in v0.48.84

WeightedOperations returns all the operations from the module with their respective weights

Types

This section is empty.

Jump to

Keyboard shortcuts

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