Documentation ¶
Index ¶
- Constants
- func GetRandomExistingOperator(r *rand.Rand, ctx context.Context, k *keeper.Keeper, ...) (types.Operator, bool)
- func NewDecodeStore(keeper *keeper.Keeper) func(kvA kv.Pair, kvB kv.Pair) string
- func ProposalMsgs(stakingKeeper *stakingkeeper.Keeper) []simtypes.WeightedProposalMsg
- func RandomOperator(r *rand.Rand, accounts []simtypes.Account) types.Operator
- func RandomOperatorParams(r *rand.Rand) types.OperatorParams
- func RandomParams(r *rand.Rand, stakeDenom string) types.Params
- func RandomizedGenState(simState *module.SimulationState)
- func SimulateDeactivateOperator(ak authkeeper.AccountKeeper, bk bankkeeper.Keeper, k *keeper.Keeper) simtypes.Operation
- func SimulateDeleteOperator(ak authkeeper.AccountKeeper, bk bankkeeper.Keeper, k *keeper.Keeper) simtypes.Operation
- func SimulateMsgRegisterOperator(ak authkeeper.AccountKeeper, bk bankkeeper.Keeper, k *keeper.Keeper) simtypes.Operation
- func SimulateMsgUpdateParams(stakingKeeper *stakingkeeper.Keeper) func(r *rand.Rand, _ sdk.Context, _ []simtypes.Account) sdk.Msg
- func SimulateReactivateOperator(ak authkeeper.AccountKeeper, bk bankkeeper.Keeper, k *keeper.Keeper) simtypes.Operation
- func SimulateSetOperatorParams(ak authkeeper.AccountKeeper, bk bankkeeper.Keeper, k *keeper.Keeper) simtypes.Operation
- func SimulateTransferOperatorOwnership(ak authkeeper.AccountKeeper, bk bankkeeper.Keeper, k *keeper.Keeper) simtypes.Operation
- func SimulateUpdateOperator(ak authkeeper.AccountKeeper, bk bankkeeper.Keeper, k *keeper.Keeper) simtypes.Operation
- func WeightedOperations(appParams simtypes.AppParams, ak authkeeper.AccountKeeper, ...) simulation.WeightedOperations
Constants ¶
View Source
const ( DefaultWeightMsgRegisterOperator int = 80 DefaultWeightMsgUpdateOperator int = 40 DefaultWeightMsgDeactivateOperator int = 20 DefaultWeightMsgReactivateOperator int = 30 DefaultWeightMsgTransferOperatorOwnership int = 10 DefaultWeightMsgDeleteOperator int = 25 DefaultWeightMsgSetOperatorParams int = 10 OperationWeightMsgRegisterOperator = "op_weight_msg_register_operator" OperationWeightMsgDeactivateOperator = "op_weight_msg_deactivate_operator" OperationWeightMsgUpdateOperator = "op_weight_msg_update_operator" OperationWeightMsgReactivateOperator = "op_weight_msg_reactivate_operator" OperationWeightMsgTransferOperatorOwnership = "op_weight_msg_transfer_operator_ownership" OperationWeightMsgDeleteOperator = "op_weight_msg_delete_operator" OperationWeightMsgSetOperatorParams = "op_weight_msg_set_operator_params" )
Simulation operation weights constants
View Source
const ( DefaultWeightMsgUpdateParams = 30 OperationWeightMsgUpdateParams = "op_weight_msg_update_params" )
Variables ¶
This section is empty.
Functions ¶
func GetRandomExistingOperator ¶
func GetRandomExistingOperator(r *rand.Rand, ctx context.Context, k *keeper.Keeper, filter func(operator types.Operator) bool) (types.Operator, bool)
GetRandomExistingOperator returns a random existing operator
func NewDecodeStore ¶
NewDecodeStore returns a decoder function closure that unmarshals the KVPair's Value to the corresponding operators type.
func ProposalMsgs ¶
func ProposalMsgs(stakingKeeper *stakingkeeper.Keeper) []simtypes.WeightedProposalMsg
func RandomOperator ¶
RandomOperator returns a random operator
func RandomOperatorParams ¶
func RandomOperatorParams(r *rand.Rand) types.OperatorParams
RandomOperatorParams returns random operator params
func RandomParams ¶
RandomParams returns random params
func RandomizedGenState ¶
func RandomizedGenState(simState *module.SimulationState)
RandomizedGenState generates a random GenesisState for the operators module
func SimulateDeactivateOperator ¶
func SimulateDeactivateOperator(ak authkeeper.AccountKeeper, bk bankkeeper.Keeper, k *keeper.Keeper) simtypes.Operation
func SimulateDeleteOperator ¶
func SimulateDeleteOperator(ak authkeeper.AccountKeeper, bk bankkeeper.Keeper, k *keeper.Keeper) simtypes.Operation
func SimulateMsgRegisterOperator ¶
func SimulateMsgRegisterOperator(ak authkeeper.AccountKeeper, bk bankkeeper.Keeper, k *keeper.Keeper) simtypes.Operation
func SimulateMsgUpdateParams ¶
func SimulateMsgUpdateParams(stakingKeeper *stakingkeeper.Keeper) func(r *rand.Rand, _ sdk.Context, _ []simtypes.Account) sdk.Msg
SimulateMsgUpdateParams returns a random MsgUpdateParams
func SimulateReactivateOperator ¶
func SimulateReactivateOperator(ak authkeeper.AccountKeeper, bk bankkeeper.Keeper, k *keeper.Keeper) simtypes.Operation
func SimulateSetOperatorParams ¶
func SimulateSetOperatorParams(ak authkeeper.AccountKeeper, bk bankkeeper.Keeper, k *keeper.Keeper) simtypes.Operation
func SimulateTransferOperatorOwnership ¶
func SimulateTransferOperatorOwnership(ak authkeeper.AccountKeeper, bk bankkeeper.Keeper, k *keeper.Keeper) simtypes.Operation
func SimulateUpdateOperator ¶
func SimulateUpdateOperator(ak authkeeper.AccountKeeper, bk bankkeeper.Keeper, k *keeper.Keeper) simtypes.Operation
func WeightedOperations ¶
func WeightedOperations( appParams simtypes.AppParams, ak authkeeper.AccountKeeper, bk bankkeeper.Keeper, k *keeper.Keeper, ) simulation.WeightedOperations
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.