keeper

package
v4.1.0-rc0 Latest Latest
Warning

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

Go to latest
Published: May 12, 2023 License: Apache-2.0 Imports: 9 Imported by: ? modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

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