keeper

package
v0.0.0-...-837776e Latest Latest
Warning

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

Go to latest
Published: Dec 21, 2024 License: Apache-2.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewQuerier

func NewQuerier(k Keeper, legacyQuerierCdc *codec.LegacyAmino) sdk.Querier

Types

type Keeper

type Keeper struct {
	PushAction vm.ActionPusher
	// contains filtered or unexported fields
}

Keeper maintains the link to data storage and exposes getter/setter methods for the various parts of the state machine

func NewKeeper

func NewKeeper(
	cdc codec.Codec, key storetypes.StoreKey, paramSpace paramtypes.Subspace,
	accountKeeper types.AccountKeeper, bankKeeper types.BankKeeper,
	rewardDistributorName string,
	pushAction vm.ActionPusher,
) Keeper

NewKeeper creates a new vbank Keeper instance

func (Keeper) DistributeRewards

func (k Keeper) DistributeRewards(ctx sdk.Context) error

DistributeRewards drives the rewards state machine.

func (Keeper) GetAllBalances

func (k Keeper) GetAllBalances(ctx sdk.Context, addr sdk.AccAddress) sdk.Coins

func (Keeper) GetBalance

func (k Keeper) GetBalance(ctx sdk.Context, addr sdk.AccAddress, denom string) sdk.Coin

func (Keeper) GetModuleAccountAddress

func (k Keeper) GetModuleAccountAddress(ctx sdk.Context, name string) sdk.AccAddress

func (Keeper) GetNextSequence

func (k Keeper) GetNextSequence(ctx sdk.Context) uint64

func (Keeper) GetParams

func (k Keeper) GetParams(ctx sdk.Context) (params types.Params)

func (Keeper) GetState

func (k Keeper) GetState(ctx sdk.Context) types.State

func (Keeper) GrabCoins

func (k Keeper) GrabCoins(ctx sdk.Context, addr sdk.AccAddress, amt sdk.Coins) error

func (Keeper) IsAllowedMonitoringAccount

func (k Keeper) IsAllowedMonitoringAccount(ctx sdk.Context, addr sdk.AccAddress) bool

func (Keeper) Params

Params queries params of distribution module

func (Keeper) SendCoins

func (k Keeper) SendCoins(ctx sdk.Context, addr sdk.AccAddress, amt sdk.Coins) error

func (Keeper) SendCoinsToRewardDistributor

func (k Keeper) SendCoinsToRewardDistributor(ctx sdk.Context, amt sdk.Coins) error

func (Keeper) SetParams

func (k Keeper) SetParams(ctx sdk.Context, params types.Params)

func (Keeper) SetState

func (k Keeper) SetState(ctx sdk.Context, state types.State)

func (Keeper) State

State queries state of distribution module

func (Keeper) StoreRewardCoins

func (k Keeper) StoreRewardCoins(ctx sdk.Context, amt sdk.Coins) error

type Migrator

type Migrator struct {
	// contains filtered or unexported fields
}

Migrator handles in-place store migrations.

func NewMigrator

func NewMigrator(keeper Keeper) Migrator

NewMigrator creates a new Migrator based on the keeper.

func (Migrator) Migrate1to2

func (m Migrator) Migrate1to2(ctx sdk.Context) error

Migrate1to2 migrates from version 1 to 2.

Jump to

Keyboard shortcuts

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