keeper

package
v0.3.0-alpha Latest Latest
Warning

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

Go to latest
Published: Jul 18, 2022 License: Apache-2.0 Imports: 32 Imported by: 0

Documentation

Index

Constants

View Source
const (
	ErrChainNotFound                               = whoops.Errorf("chain with chainReferenceID '%s' was not found")
	ErrChainNotActive                              = whoops.Errorf("chain with chainReferenceID '%s' is not active")
	ErrNotEnoughValidatorsForGivenChainReferenceID = whoops.String("not enough validators in the current snapshot to form a proper valset")
	ErrUnexpectedError                             = whoops.String("unexpected error")
	ErrConsensusNotAchieved                        = whoops.String("evm: consensus not achieved")
)
View Source
const (
	ConsensusTurnstoneMessage = "evm-turnstone-message"
	SignaturePrefix           = "\x19Ethereum Signed Message:\n32"
)

Variables

View Source
var SupportedConsensusQueues = map[string]supportedChainInfo{
	ConsensusTurnstoneMessage: {
		// contains filtered or unexported fields
	},
}

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 {
	ConsensusKeeper types.ConsensusKeeper
	Valset          types.ValsetKeeper
	// contains filtered or unexported fields
}

func NewKeeper

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

func (Keeper) ActivateChainReferenceID

func (k Keeper) ActivateChainReferenceID(ctx sdk.Context, chainReferenceID string, smartContract *types.SmartContract) error

func (Keeper) AddSmartContractExecutionToConsensus

func (k Keeper) AddSmartContractExecutionToConsensus(
	ctx sdk.Context,
	chainReferenceID,
	turnstoneID string,
	logicCall *types.SubmitLogicCall,
) error

func (Keeper) AddSupportForNewChain

func (k Keeper) AddSupportForNewChain(ctx sdk.Context, addChain *types.AddChainProposal) error

func (Keeper) GetChainInfo

func (k Keeper) GetChainInfo(ctx sdk.Context, targetChainReferenceID string) (*types.ChainInfo, error)

func (Keeper) GetParams

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

GetParams get all parameters as types.Params

func (Keeper) GetValsetByID

GetValsetByID returns the valset given chain id and valset id. if the valset id is non-pozitive then it returns the latest valset existing.

func (Keeper) Logger

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

func (Keeper) OnSnapshotBuilt

func (k Keeper) OnSnapshotBuilt(ctx sdk.Context, snapshot *valsettypes.Snapshot)

func (Keeper) Params

func (Keeper) RemoveSupportForChain

func (k Keeper) RemoveSupportForChain(ctx sdk.Context, proposal *types.RemoveChainProposal) error

func (Keeper) SetParams

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

SetParams set the params

func (Keeper) SupportedQueues

func (k Keeper) SupportedQueues(ctx sdk.Context) (map[string]consensus.SupportsConsensusQueueAction, error)

func (Keeper) TryDeployingSmartContractToAllChains

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

func (Keeper) UpdateWithSmartContract

func (k Keeper) UpdateWithSmartContract(ctx sdk.Context, abiJSON string, bytecode []byte) error

func (Keeper) WasmMessengerHandler

func (k Keeper) WasmMessengerHandler() wasmutil.MessengerFnc

Jump to

Keyboard shortcuts

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