keeper

package
v0.1.429-bweng-test-1 Latest Latest
Warning

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

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

Documentation

Index

Constants

View Source
const (
	HeaderSizeTotalCount = 8
	HeaderSizePerTx      = 8
)
View Source
const (
	RightSibling = 1
	LeftSibling  = -1
)

Variables

This section is empty.

Functions

func AccountToValue

func AccountToValue(account types.Account) ([]byte, error)

func DecodeTransactionData

func DecodeTransactionData(encoded []byte) ([][]byte, error)

func EncodeTransactionData

func EncodeTransactionData(data [][]byte) []byte

First 8 bytes: count (C) of transactions Next 8 * C bytes: transaction sizes The rest: transaction bodies

func Hash

func Hash(val1, val2 []byte) []byte

func NewMsgServerImpl

func NewMsgServerImpl(keeper Keeper) types.MsgServer

Types

type Keeper

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

func NewKeeper

func NewKeeper(
	cdc codec.Codec,
	storeKey sdk.StoreKey,
	paramSpace paramtypes.Subspace,
) Keeper

func (Keeper) ExportGenesis

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

func (Keeper) GetParams

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

GetParams returns the total set params.

func (Keeper) GetSender

func (k Keeper) GetSender(ctx sdk.Context, slot uint64) (string, bool)

func (Keeper) GetSenderStore

func (k Keeper) GetSenderStore(ctx sdk.Context) sdk.KVStore

func (Keeper) GetStateRoot

func (k Keeper) GetStateRoot(ctx sdk.Context, slot uint64) ([]byte, error)

func (Keeper) GetStateRootStore

func (k Keeper) GetStateRootStore(ctx sdk.Context) sdk.KVStore

func (Keeper) GetTransactionData

func (k Keeper) GetTransactionData(ctx sdk.Context, slot uint64) ([][]byte, error)

func (Keeper) GetTransactionDataStore

func (k Keeper) GetTransactionDataStore(ctx sdk.Context) sdk.KVStore

func (Keeper) InitGenesis

func (k Keeper) InitGenesis(ctx sdk.Context, genState types.GenesisState)

func (Keeper) IsTxSenderWhitelisted

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

func (Keeper) Logger

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

func (Keeper) Params

func (Keeper) Sender

func (Keeper) SetParams

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

SetParams sets the total set of params.

func (Keeper) SetSender

func (k Keeper) SetSender(ctx sdk.Context, slot uint64, sender string)

func (Keeper) SetStateRoot

func (k Keeper) SetStateRoot(ctx sdk.Context, slot uint64, stateRoot []byte)

func (Keeper) SetTransactionData

func (k Keeper) SetTransactionData(ctx sdk.Context, slot uint64, data [][]byte)

func (*Keeper) Validate

func (k *Keeper) Validate(root []byte, proof *types.MerkleProof) error

this function goes over all merkle proof hashes, and check if the merkle root generated is the same as the provided root

Jump to

Keyboard shortcuts

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