keeper

package
v1.14.0 Latest Latest
Warning

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

Go to latest
Published: Oct 19, 2026 License: Apache-2.0 Imports: 16 Imported by: 1 module, 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

func CalculateAllocatedAmount

func CalculateAllocatedAmount(gross sdkmath.Int, rate sdkmath.LegacyDec) (sdkmath.Int, error)

CalculateAllocatedAmount applies a deterministic decimal multiplication and truncates toward zero.

func CalculateSettlement

func CalculateSettlement(gross, allocated, min, max sdkmath.Int) (burn, community sdkmath.Int, err error)

CalculateSettlement returns burn and community amounts while preserving burn+community=allocated.

func NewMsgServerImpl

func NewMsgServerImpl(k Keeper) types.MsgServer

Types

type Keeper

type Keeper struct {
	ParamsStore        collections.Item[types.Params]
	CurrentPeriodStore collections.Item[types.CurrentPeriod]
	Schema             collections.Schema
	// contains filtered or unexported fields
}

func NewKeeper

func NewKeeper(
	c codec.Codec,
	storeService store.KVStoreService,
	accountKeeper types.AccountKeeper,
	bankKeeper types.BankKeeper,
	distKeeper types.DistributionKeeper,
	authority string,
) Keeper

func (Keeper) Authority

func (k Keeper) Authority() string

func (Keeper) BeginBlock

func (k Keeper) BeginBlock(ctx context.Context) error

BeginBlock atomically routes the FeeCollector balance and, at the period boundary, settles it.

func (Keeper) ExportGenesis

func (k Keeper) ExportGenesis(ctx context.Context) (*types.GenesisState, error)

func (Keeper) GetParams

func (k Keeper) GetParams(ctx context.Context) (types.Params, error)

func (Keeper) InitGenesis

func (k Keeper) InitGenesis(ctx context.Context, state *types.GenesisState) error

func (Keeper) Logger

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

func (Keeper) Params

func (Keeper) SetParams

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

func (Keeper) Status

Jump to

Keyboard shortcuts

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