keeper

package
v0.1.2 Latest Latest
Warning

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

Go to latest
Published: Jan 18, 2024 License: Apache-2.0 Imports: 14 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
}

func NewKeeper

func NewKeeper(
	cdc codec.BinaryCodec,
	storeKey,
	memKey storetypes.StoreKey,
	ps paramtypes.Subspace,
) *Keeper

func (Keeper) AfterEpochEnd

func (k Keeper) AfterEpochEnd(ctx sdk.Context, identifier string, epochNumber int64)

AfterEpochEnd epoch hook

func (Keeper) BeforeEpochStart

func (k Keeper) BeforeEpochStart(ctx sdk.Context, identifier string, epochNumber int64)

BeforeEpochStart epoch hook

func (Keeper) BeginBlocker

func (k Keeper) BeginBlocker(ctx sdk.Context)

BeginBlocker of epochs module.

func (Keeper) EndBlocker added in v0.1.0

func (k Keeper) EndBlocker(ctx sdk.Context)

func (Keeper) GetAllEpochInfo

func (k Keeper) GetAllEpochInfo(ctx sdk.Context) (list []types.EpochInfo)

GetAllEpochInfo returns all epochInfo

func (Keeper) GetEpochInfo

func (k Keeper) GetEpochInfo(
	ctx sdk.Context,
	identifier string,
) (val types.EpochInfo, found bool)

GetEpochInfo returns a epochInfo from its index

func (Keeper) GetParams

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

GetParams get all parameters as types.Params

func (Keeper) IterateEpochInfo

func (k Keeper) IterateEpochInfo(ctx sdk.Context, fn func(index int64, epochInfo types.EpochInfo) (stop bool))

Iterate though epochs

func (Keeper) Logger

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

func (Keeper) Params

func (Keeper) RemoveEpochInfo

func (k Keeper) RemoveEpochInfo(
	ctx sdk.Context,
	identifier string,
)

RemoveEpochInfo removes a epochInfo from the store

func (*Keeper) RemoveHooks added in v0.1.0

func (k *Keeper) RemoveHooks() *Keeper

Remove all hooks. Only used for testing.

func (Keeper) SetEpochInfo

func (k Keeper) SetEpochInfo(ctx sdk.Context, epochInfo types.EpochInfo)

SetEpochInfo set a specific epochInfo in the store from its index

func (*Keeper) SetHooks

func (k *Keeper) SetHooks(eh types.EpochHooks) *Keeper

func (Keeper) SetParams

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

SetParams set the params

Jump to

Keyboard shortcuts

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