keeper

package
v4.2.1 Latest Latest
Warning

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

Go to latest
Published: Jun 9, 2023 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Keeper

type Keeper struct {
	stakingkeeper.Keeper
	// contains filtered or unexported fields
}

func NewKeeper

func NewKeeper(k stakingkeeper.Keeper, storeKey storetypes.StoreKey) Keeper

NewKeeper creates a new staking Keeper instance

func (Keeper) ExportGenesis

func (k Keeper) ExportGenesis(ctx sdk.Context) *types.GenesisState

func (Keeper) GetAllowance

func (k Keeper) GetAllowance(ctx sdk.Context, valAddr sdk.ValAddress, owner, spender sdk.AccAddress) *big.Int

GetAllowance returns the allowance of a spender for a delegator.

func (Keeper) InitGenesis

func (k Keeper) InitGenesis(ctx sdk.Context, data *types.GenesisState) (res []abci.ValidatorUpdate)

func (Keeper) IterateAllAllowance

func (k Keeper) IterateAllAllowance(ctx sdk.Context, handler func(valAddr sdk.ValAddress, owner, spender sdk.AccAddress, allowance *big.Int) (stop bool))

IterateAllAllowance iterates over the allowances and performs a callback function.

func (Keeper) SetAllowance

func (k Keeper) SetAllowance(ctx sdk.Context, valAddr sdk.ValAddress, owner, spender sdk.AccAddress, shares *big.Int)

SetAllowance sets the allowance of a spender for a delegator. shares must be non-negative.

Jump to

Keyboard shortcuts

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