Documentation ¶
Index ¶
- func PubKeyRegistrationInvariant(k *Keeper) sdk.Invariant
- func RegisterInvariants(ir sdk.InvariantRegistry, k *Keeper)
- type Keeper
- func (k *Keeper) SetHooks(sh sdktypes.StakingHooks)
- func (k *Keeper) SetPubKeyKeeper(pubKeyKeeper types.PubKeyKeeper)
- func (k Keeper) TransferDelegation(ctx context.Context, fromAddr, toAddr sdk.AccAddress, valAddr sdk.ValAddress, ...) (sdkmath.LegacyDec, error)
- func (k Keeper) TransferUnbonding(ctx context.Context, fromAddr, toAddr sdk.AccAddress, valAddr sdk.ValAddress, ...) (sdkmath.Int, error)
- type StakingMsgServer
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func PubKeyRegistrationInvariant ¶
PubKeyRegistrationInvariant checks for the invariant that once the secp256k1 proving scheme is enabled, all validators have registered their public keys.
func RegisterInvariants ¶
func RegisterInvariants(ir sdk.InvariantRegistry, k *Keeper)
RegisterInvariants registers all staking invariants.
Types ¶
type Keeper ¶ added in v0.0.6
func NewKeeper ¶ added in v0.0.6
func NewKeeper(sdkStakingKeeper *sdkkeeper.Keeper, valAddrCdc addresscodec.Codec) *Keeper
func (*Keeper) SetHooks ¶ added in v0.0.6
func (k *Keeper) SetHooks(sh sdktypes.StakingHooks)
func (*Keeper) SetPubKeyKeeper ¶
func (k *Keeper) SetPubKeyKeeper(pubKeyKeeper types.PubKeyKeeper)
func (Keeper) TransferDelegation ¶ added in v0.0.6
func (k Keeper) TransferDelegation(ctx context.Context, fromAddr, toAddr sdk.AccAddress, valAddr sdk.ValAddress, wantShares sdkmath.LegacyDec) (sdkmath.LegacyDec, error)
NOTE: This code was taken from https://github.com/agoric-labs/cosmos-sdk/blob/f42d86980ddfc07869846c391a03622cbd7e9188/x/staking/keeper/delegation.go#L701 with slight modifications.
TransferDelegation changes the ownership of at most the desired number of shares. Returns the actual number of shares transferred. Will also transfer redelegation entries to ensure that all redelegations are matched by sufficient shares. Note that no tokens are transferred to or from any pool or account, since no delegation is actually changing state.
func (Keeper) TransferUnbonding ¶ added in v0.0.6
func (k Keeper) TransferUnbonding(ctx context.Context, fromAddr, toAddr sdk.AccAddress, valAddr sdk.ValAddress, wantAmt sdkmath.Int) (sdkmath.Int, error)
NOTE: This code was taken from https://github.com/agoric-labs/cosmos-sdk/blob/f42d86980ddfc07869846c391a03622cbd7e9188/x/staking/keeper/delegation.go#L979 with slight modifications.
TransferUnbonding changes the ownership of UnbondingDelegation entries until the desired number of tokens have changed hands. Returns the actual number of tokens transferred.
type StakingMsgServer ¶
type StakingMsgServer interface { stakingtypes.MsgServer types.MsgServer }
StakingMsgServer is the full staking module msg server that combines SDK and SEDA msg servers.
func NewMsgServerImpl ¶
func NewMsgServerImpl(sdkMsgServer stakingtypes.MsgServer, keeper *Keeper) StakingMsgServer