keeper

package
v12.2.0 Latest Latest
Warning

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

Go to latest
Published: Jan 10, 2024 License: Apache-2.0 Imports: 16 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 Hooks

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

Hooks wrapper struct for slashing keeper

func (Hooks) AfterDelegationModified

func (h Hooks) AfterDelegationModified(ctx sdk.Context, delAddr sdk.AccAddress, valAddr sdk.ValAddress)

func (Hooks) AfterProposalActive

func (h Hooks) AfterProposalActive(_ sdk.Context, _ uint64)

func (Hooks) AfterProposalDeposit

func (h Hooks) AfterProposalDeposit(_ sdk.Context, _ uint64, _ sdk.AccAddress)

func (Hooks) AfterProposalFailedMinDeposit

func (h Hooks) AfterProposalFailedMinDeposit(_ sdk.Context, _ uint64)

func (Hooks) AfterProposalInactive

func (h Hooks) AfterProposalInactive(_ sdk.Context, _ uint64)

func (Hooks) AfterProposalSubmission

func (h Hooks) AfterProposalSubmission(_ sdk.Context, _ uint64)

governance hooks

func (Hooks) AfterProposalVote

func (h Hooks) AfterProposalVote(ctx sdk.Context, proposalID uint64, voterAddr sdk.AccAddress)

func (Hooks) AfterProposalVotingPeriodEnded

func (h Hooks) AfterProposalVotingPeriodEnded(_ sdk.Context, _ uint64)

func (Hooks) AfterValidatorBeginUnbonding

func (h Hooks) AfterValidatorBeginUnbonding(_ sdk.Context, _ sdk.ConsAddress, _ sdk.ValAddress)

func (Hooks) AfterValidatorBonded

func (h Hooks) AfterValidatorBonded(_ sdk.Context, _ sdk.ConsAddress, _ sdk.ValAddress)

func (Hooks) AfterValidatorCreated

func (h Hooks) AfterValidatorCreated(_ sdk.Context, _ sdk.ValAddress)

staking hooks

func (Hooks) AfterValidatorRemoved

func (h Hooks) AfterValidatorRemoved(_ sdk.Context, _ sdk.ConsAddress, _ sdk.ValAddress)

func (Hooks) BeforeDelegationCreated

func (h Hooks) BeforeDelegationCreated(_ sdk.Context, _ sdk.AccAddress, _ sdk.ValAddress)

func (Hooks) BeforeDelegationRemoved

func (h Hooks) BeforeDelegationRemoved(_ sdk.Context, _ sdk.AccAddress, _ sdk.ValAddress)

func (Hooks) BeforeDelegationSharesModified

func (h Hooks) BeforeDelegationSharesModified(_ sdk.Context, _ sdk.AccAddress, _ sdk.ValAddress)

func (Hooks) BeforeValidatorModified

func (h Hooks) BeforeValidatorModified(_ sdk.Context, _ sdk.ValAddress)

func (Hooks) BeforeValidatorSlashed

func (h Hooks) BeforeValidatorSlashed(_ sdk.Context, _ sdk.ValAddress, _ sdk.Dec)

type Keeper

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

func NewKeeper

func NewKeeper(
	cdc codec.Codec,
	storeKey,
	memKey sdk.StoreKey,
	accountKeeper types.AccountKeeper, bankKeeper types.BankKeeper,
	stakingKeeper types.StakingKeeper, distrKeeper types.DistrKeeper,
	ps paramtypes.Subspace,
) *Keeper

func (Keeper) AfterDelegationModified

func (k Keeper) AfterDelegationModified(ctx sdk.Context, delAddr sdk.AccAddress, _ sdk.ValAddress)

func (Keeper) AfterProposalVote

func (k Keeper) AfterProposalVote(ctx sdk.Context, _ uint64, voterAddr sdk.AccAddress)

func (Keeper) ClaimCoinsForAction

func (k Keeper) ClaimCoinsForAction(ctx sdk.Context, addr sdk.AccAddress, action types.Action) (sdk.Coins, error)

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

func (Keeper) ClaimRecord

Claimable returns claimable amount per user

func (Keeper) ClaimRecords

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

ClaimRecords get claimables for genesis export

func (Keeper) ClaimableForAction

Activities returns activities

func (Keeper) CreateModuleAccount

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

CreateModuleAccount creates module account of airdrop module

func (Keeper) EndAirdrop

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

func (Keeper) ExportGenesis

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

func (Keeper) GetClaimRecord

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

ClaimRecord returns the claim record for a specific address

func (Keeper) GetClaimableAmountForAction

func (k Keeper) GetClaimableAmountForAction(ctx sdk.Context, addr sdk.AccAddress, action types.Action) (sdk.Coins, error)

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

func (Keeper) GetModuleAccountAddress

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

GetModuleAccountBalance gets the airdrop coin balance of module account

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 returns the total set of claim parameters.

func (Keeper) GetUserTotalClaimable

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

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

func (Keeper) Hooks

func (k Keeper) Hooks() Hooks

Return the wrapper struct

func (Keeper) InitGenesis

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

func (Keeper) Logger

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

func (Keeper) ModuleAccountBalance

Params returns params of the mint module.

func (Keeper) Params

Params returns params of the mint 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

SetClaimables 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.

func (Keeper) TotalClaimable

Activities returns activities

Jump to

Keyboard shortcuts

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