keeper

package
v0.7.12 Latest Latest
Warning

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

Go to latest
Published: Apr 9, 2024 License: GPL-3.0 Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewMsgServerImpl

func NewMsgServerImpl(keeper Keeper) minttypes.MsgServer

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

Types

type Keeper

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

Keeper of the mint store

func NewKeeper

func NewKeeper(
	cdc codec.BinaryCodec,
	key storetypes.StoreKey,
	sk minttypes.StakingKeeper,
	ak minttypes.AccountKeeper,
	bk minttypes.BankKeeper,
	feeCollectorName string,
	authority string,
) Keeper

NewKeeper creates a new mint Keeper instance

func (Keeper) AddCollectedFees

func (k Keeper) AddCollectedFees(ctx sdk.Context, fees sdk.Coins) error

AddCollectedFees implements an alias call to the underlying supply keeper's AddCollectedFees to be used in BeginBlocker.

func (Keeper) AnnualProvisions

AnnualProvisions returns minter.AnnualProvisions of the mint module.

func (Keeper) BondedRatio

func (k Keeper) BondedRatio(ctx sdk.Context) sdk.Dec

BondedRatio implements an alias call to the underlying staking keeper's BondedRatio to be used in BeginBlocker.

func (Keeper) CurrentMintVolume

CurrentMintVolume returns current mint volume

func (Keeper) ExportGenesis added in v0.7.5

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

ExportGenesis returns a GenesisState for a given context and keeper.

func (Keeper) GetAuthority added in v0.7.5

func (k Keeper) GetAuthority() string

GetAuthority returns the x/mint module's authority.

func (Keeper) GetMintAccount

func (k Keeper) GetMintAccount(ctx sdk.Context) authtypes.ModuleAccountI

GetMintAccount returns the mint ModuleAccount

func (Keeper) GetMintModuleCoinsAccount

func (k Keeper) GetMintModuleCoinsAccount(ctx sdk.Context) (account sdk.AccAddress)

get the module coins account

func (Keeper) GetMintPool

func (k Keeper) GetMintPool(ctx sdk.Context) (mintPool minttypes.MintPool)

GetMintPool returns the mint pool info

func (Keeper) GetMinter

func (k Keeper) GetMinter(ctx sdk.Context) (minter minttypes.Minter)

get the minter

func (Keeper) GetParams

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

GetParams returns the total set of minting parameters.

func (Keeper) Inflation

Inflation returns minter.Inflation of the mint module.

func (Keeper) InitGenesis added in v0.7.5

func (k Keeper) InitGenesis(ctx sdk.Context, ak minttypes.AccountKeeper, data *minttypes.GenesisState)

InitGenesis new mint genesis

func (Keeper) IntegrationAddress

IntegrationAddress returns ethereum integration address

func (Keeper) IsAllowedMintDenom

func (k Keeper) IsAllowedMintDenom(ctx sdk.Context, coin sdk.Coin) bool

IsAllowedMintDenom checks if denom exists in the allowed mint denoms list

func (Keeper) IsAllowedMinter

func (k Keeper) IsAllowedMinter(ctx sdk.Context, addr string) bool

IsAllowedMinter checks if address exists in the allowed minters list

func (Keeper) IsEligibleAccount

func (k Keeper) IsEligibleAccount(ctx sdk.Context, addr string) bool

IsEligibleAccount checks if addr exists in the eligible to withdraw account pool

func (Keeper) LimitExceeded

func (k Keeper) LimitExceeded(ctx sdk.Context, amt sdk.Coins) bool

LimitExceeded checks if withdrawal amount exceeds the limit

func (Keeper) Logger

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

Logger returns a module-specific logger.

func (Keeper) MintCoins

func (k Keeper) MintCoins(ctx sdk.Context, newCoins sdk.Coins) error

MintCoins implements an alias call to the underlying supply keeper's MintCoins to be used in BeginBlocker.

func (Keeper) MintNewCoins

func (k Keeper) MintNewCoins(ctx sdk.Context, amount sdk.Coins) error

MintNewCoins issue new coins

func (Keeper) MintVolumeExceeded

func (k Keeper) MintVolumeExceeded(ctx sdk.Context, amt sdk.Coins) bool

MintVolumeExceeded checks if minting volume exceeds the limit

func (Keeper) Params

Params returns params of the mint module.

func (Keeper) SetMintAccount

func (k Keeper) SetMintAccount(ctx sdk.Context, moduleAcc authtypes.ModuleAccountI)

SetMintAccount sets the module account

func (Keeper) SetMintModuleCoinsAccount

func (k Keeper) SetMintModuleCoinsAccount(ctx sdk.Context, account sdk.AccAddress)

set the module coins account

func (Keeper) SetMintPool

func (k Keeper) SetMintPool(ctx sdk.Context, mintPool minttypes.MintPool)

SetMintPool sets mint pool to the store

func (Keeper) SetMinter

func (k Keeper) SetMinter(ctx sdk.Context, minter minttypes.Minter)

set the minter

func (Keeper) SetParams

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

SetParams sets the total set of minting parameters.

func (Keeper) StakingTokenSupply

func (k Keeper) StakingTokenSupply(ctx sdk.Context) sdk.Int

StakingTokenSupply implements an alias call to the underlying staking keeper's StakingTokenSupply to be used in BeginBlocker.

func (Keeper) TreasuryPool

TreasuryPool returns current treasury pool

func (Keeper) WithdrawCoinsFromTreasury

func (k Keeper) WithdrawCoinsFromTreasury(ctx sdk.Context, receiver sdk.AccAddress, amount sdk.Coins) error

WithdrawCoinsFromTreasury transfers coins from treasury pool to receiver account

type Migrator added in v0.7.5

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

Migrator is a struct for handling in-place state migrations.

func NewMigrator added in v0.7.5

func NewMigrator(k Keeper, ss exported.Subspace) Migrator

NewMigrator returns Migrator instance for the state migration.

func (Migrator) Migrate1to2 added in v0.7.5

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

Migrate1to2 migrates the x/mint module state from the consensus version 1 to version 2. Specifically, it takes the parameters that are currently stored and managed by the x/params modules and stores them directly into the x/mint module state.

Jump to

Keyboard shortcuts

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