keeper

package
v1.1.0 Latest Latest
Warning

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

Go to latest
Published: Oct 17, 2022 License: Apache-2.0 Imports: 15 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewMsgServerImpl

func NewMsgServerImpl(keeper Keeper) types.MsgServer

NewMsgServerImpl returns an implementation of the MsgServer interface for the provided Keeper.

Types

type Keeper

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

Keeper struct

func NewKeeper

NewKeeper returns keeper

func (Keeper) ClaimCoinsForAction

func (k Keeper) ClaimCoinsForAction(ctx sdk.Context, addr sdk.AccAddress, action int32) (sdk.Coin, error)

ClaimCoinsForAction remove claimable amount entry and transfer it to user's account

func (Keeper) CreateModuleAccount

func (k Keeper) CreateModuleAccount(ctx sdk.Context, amount sdk.Coin)

CreateModuleAccount creates the module account with amount

func (Keeper) EndAirdrop

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

func (Keeper) GetClaimRecord

func (k Keeper) GetClaimRecord(ctx sdk.Context, addr sdk.AccAddress) (types.ClaimRecord, error)

GetClaimRecord returns the claim record for a specific address

func (Keeper) GetClaimRecords

func (k Keeper) GetClaimRecords(ctx sdk.Context) []types.ClaimRecord

GetClaimRecords get claimables for genesis export

func (Keeper) GetClaimableAmountForAction

func (k Keeper) GetClaimableAmountForAction(ctx sdk.Context, addr sdk.AccAddress, action int32) (sdk.Coin, error)

GetClaimableAmountForAction returns claimable amount for a specific action done by an address

func (Keeper) GetModuleAccountAddress

func (k Keeper) GetModuleAccountAddress(ctx sdk.Context) sdk.AccAddress

GetModuleAccountAddress gets module account address of claim module

func (Keeper) GetModuleAccountBalance

func (k Keeper) GetModuleAccountBalance(ctx sdk.Context) sdk.Coin

GetModuleAccountBalance gets the airdrop coin balance of module account

func (Keeper) GetParams

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

GetParams get params GetParams returns the total set of claim parameters.

func (Keeper) GetUserTotalClaimable

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

GetUserTotalClaimable returns total claimable amount of an address

func (Keeper) Logger

func (k Keeper) Logger(ctx sdk.Context) log.Logger

Logger returns logger

func (Keeper) ModuleAccountBalance

ModuleAccountBalance returns claim module account balance.

func (Keeper) Params

Params returns params of the claim module.

func (Keeper) SetClaimRecord

func (k Keeper) SetClaimRecord(ctx sdk.Context, claimRecord types.ClaimRecord) error

SetClaimRecord sets a claim record for an address in store

func (Keeper) SetClaimRecords

func (k Keeper) SetClaimRecords(ctx sdk.Context, claimRecords []types.ClaimRecord) error

SetClaimRecords set claimable amount from balances object

func (Keeper) SetParams

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

SetParams sets claim parameters to the param space.

type Querier

type Querier struct {
	Keeper
}

Querier is used as Keeper will have duplicate methods if used directly, and gRPC names take precedence over keeper

Jump to

Keyboard shortcuts

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