keeper

package
v0.5.0 Latest Latest
Warning

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

Go to latest
Published: Feb 3, 2023 License: Apache-2.0 Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type HandledHooks

type HandledHooks interface {
	etypes.EpochingHooks
	checkpointingtypes.CheckpointingHooks
}

Helper interface to be sure Hooks implement both epoching and light client hooks

type Hooks

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

func (Hooks) AfterBlsKeyRegistered

func (h Hooks) AfterBlsKeyRegistered(ctx sdk.Context, valAddr sdk.ValAddress) error

func (Hooks) AfterEpochBegins

func (h Hooks) AfterEpochBegins(ctx sdk.Context, epoch uint64)

func (Hooks) AfterEpochEnds

func (h Hooks) AfterEpochEnds(ctx sdk.Context, epoch uint64)

func (Hooks) AfterRawCheckpointBlsSigVerified

func (h Hooks) AfterRawCheckpointBlsSigVerified(ctx sdk.Context, ckpt *checkpointingtypes.RawCheckpoint) error

func (Hooks) AfterRawCheckpointConfirmed

func (h Hooks) AfterRawCheckpointConfirmed(ctx sdk.Context, epoch uint64) error

func (Hooks) AfterRawCheckpointFinalized

func (h Hooks) AfterRawCheckpointFinalized(ctx sdk.Context, epoch uint64) error

func (Hooks) AfterRawCheckpointForgotten

func (h Hooks) AfterRawCheckpointForgotten(ctx sdk.Context, ckpt *checkpointingtypes.RawCheckpoint) error

func (Hooks) BeforeSlashThreshold

func (h Hooks) BeforeSlashThreshold(ctx sdk.Context, valSet etypes.ValidatorSet)

type Keeper

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

func NewKeeper

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

func (Keeper) GetParams

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

GetParams get all parameters as types.Params

func (Keeper) Hooks

func (k Keeper) Hooks() Hooks

Create new distribution hooks

func (Keeper) LightclientHeightAtCheckpointReported

func (k Keeper) LightclientHeightAtCheckpointReported(ctx sdk.Context, hashString string) (uint64, error)

func (Keeper) LightclientHeightAtEpochEnd

func (k Keeper) LightclientHeightAtEpochEnd(ctx sdk.Context, epoch uint64) (uint64, error)

func (Keeper) Logger

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

func (Keeper) Params

func (Keeper) SetParams

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

SetParams set the params

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