Documentation ¶
Index ¶
- func AllInvariants(k Keeper) sdk.Invariant
- func BlockHeightToFinalizationQueueInvariant(k Keeper) sdk.Invariant
- func NewMsgServerImpl(keeper Keeper) types.MsgServer
- func RegisterInvariants(ir sdk.InvariantRegistry, k Keeper)
- func RollappByEIP155KeyInvariant(k Keeper) sdk.Invariant
- func RollappCountInvariant(k Keeper) sdk.Invariant
- func RollappFinalizedStateInvariant(k Keeper) sdk.Invariant
- func RollappLatestStateIndexInvariant(k Keeper) sdk.Invariant
- type Keeper
- func (k Keeper) DeployerWhitelist(ctx sdk.Context) (res []types.DeployerParams)
- func (k Keeper) DisputePeriodInBlocks(ctx sdk.Context) (res uint64)
- func (k Keeper) FinalizeQueue(ctx sdk.Context) error
- func (k Keeper) FindStateInfoByHeight(ctx sdk.Context, rollappId string, height uint64) (*types.StateInfo, error)
- func (k Keeper) GetAllBlockHeightToFinalizationQueue(ctx sdk.Context) (list []types.BlockHeightToFinalizationQueue)
- func (k Keeper) GetAllFinalizationQueueUntilHeight(ctx sdk.Context, height uint64) (list []types.BlockHeightToFinalizationQueue)
- func (k Keeper) GetAllLatestFinalizedStateIndex(ctx sdk.Context) (list []types.StateInfoIndex)
- func (k Keeper) GetAllLatestStateInfoIndex(ctx sdk.Context) (list []types.StateInfoIndex)
- func (k Keeper) GetAllRollapps(ctx sdk.Context) (list []types.Rollapp)
- func (k Keeper) GetAllStateInfo(ctx sdk.Context) (list []types.StateInfo)
- func (k Keeper) GetBlockHeightToFinalizationQueue(ctx sdk.Context, creationHeight uint64) (val types.BlockHeightToFinalizationQueue, found bool)
- func (k *Keeper) GetHooks() types.MultiRollappHooks
- func (k Keeper) GetLatestFinalizedStateIndex(ctx sdk.Context, rollappId string) (val types.StateInfoIndex, found bool)
- func (k Keeper) GetLatestStateInfoIndex(ctx sdk.Context, rollappId string) (val types.StateInfoIndex, found bool)
- func (k Keeper) GetParams(ctx sdk.Context) types.Params
- func (k Keeper) GetRollapp(ctx sdk.Context, rollappId string) (val types.Rollapp, found bool)
- func (k Keeper) GetRollappByEIP155(ctx sdk.Context, eip155 uint64) (val types.Rollapp, found bool)
- func (k Keeper) GetStateInfo(ctx sdk.Context, rollappId string, index uint64) (val types.StateInfo, found bool)
- func (k Keeper) HandleFraud(ctx sdk.Context, rollappID, clientId string, fraudHeight uint64, ...) error
- func (k Keeper) IsAddressInDeployerWhiteList(ctx sdk.Context, address string) bool
- func (k Keeper) IsRollappStarted(ctx sdk.Context, rollappId string) bool
- func (k Keeper) LatestHeight(c context.Context, req *types.QueryGetLatestHeightRequest) (*types.QueryGetLatestHeightResponse, error)
- func (k Keeper) LatestStateIndex(c context.Context, req *types.QueryGetLatestStateIndexRequest) (*types.QueryGetLatestStateIndexResponse, error)
- func (k Keeper) Logger(ctx sdk.Context) log.Logger
- func (k Keeper) MustGetStateInfo(ctx sdk.Context, rollappId string, index uint64) (val types.StateInfo)
- func (k Keeper) Params(c context.Context, req *types.QueryParamsRequest) (*types.QueryParamsResponse, error)
- func (k Keeper) RemoveBlockHeightToFinalizationQueue(ctx sdk.Context, creationHeight uint64)
- func (k Keeper) RemoveLatestFinalizedStateIndex(ctx sdk.Context, rollappId string)
- func (k Keeper) RemoveLatestStateInfoIndex(ctx sdk.Context, rollappId string)
- func (k Keeper) RemoveRollapp(ctx sdk.Context, rollappId string)
- func (k Keeper) RemoveStateInfo(ctx sdk.Context, rollappId string, index uint64)
- func (k Keeper) RevertPendingStates(ctx sdk.Context, rollappID string)
- func (k Keeper) Rollapp(c context.Context, req *types.QueryGetRollappRequest) (*types.QueryGetRollappResponse, error)
- func (k Keeper) RollappAll(c context.Context, req *types.QueryAllRollappRequest) (*types.QueryAllRollappResponse, error)
- func (k Keeper) RollappByEIP155(c context.Context, req *types.QueryGetRollappByEIP155Request) (*types.QueryGetRollappResponse, error)
- func (k Keeper) RollappsEnabled(ctx sdk.Context) (res bool)
- func (k Keeper) SetBlockHeightToFinalizationQueue(ctx sdk.Context, ...)
- func (k *Keeper) SetHooks(sh types.MultiRollappHooks)
- func (k Keeper) SetLatestFinalizedStateIndex(ctx sdk.Context, latestFinalizedStateIndex types.StateInfoIndex)
- func (k Keeper) SetLatestStateInfoIndex(ctx sdk.Context, latestStateInfoIndex types.StateInfoIndex)
- func (k Keeper) SetParams(ctx sdk.Context, params types.Params)
- func (k Keeper) SetRollapp(ctx sdk.Context, rollapp types.Rollapp)
- func (k Keeper) SetStateInfo(ctx sdk.Context, stateInfo types.StateInfo)
- func (k Keeper) StateInfo(c context.Context, req *types.QueryGetStateInfoRequest) (*types.QueryGetStateInfoResponse, error)
- func (k Keeper) TriggerRollappGenesisEvent(ctx sdk.Context, rollapp types.Rollapp) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AllInvariants ¶ added in v3.1.0
AllInvariants runs all invariants of the X/bank module.
func BlockHeightToFinalizationQueueInvariant ¶ added in v3.1.0
BlockHeightToFinalizationQueueInvariant checks that all unfinalized states are in the finalization queue
func NewMsgServerImpl ¶
NewMsgServerImpl returns an implementation of the MsgServer interface for the provided Keeper.
func RegisterInvariants ¶ added in v3.1.0
func RegisterInvariants(ir sdk.InvariantRegistry, k Keeper)
RegisterInvariants registers the bank module invariants
func RollappByEIP155KeyInvariant ¶ added in v3.1.0
RollappByEIP155KeyInvariant checks that assuming rollapp id is registered with eip155 chain id then it should be retrievable by eip155 key
func RollappCountInvariant ¶ added in v3.1.0
RollappCountInvariant checks that the number of rollapps is equal to the number of latestStateInfoIndex
func RollappFinalizedStateInvariant ¶ added in v3.1.0
RollappFinalizedStateInvariant checks that all the states until latest finalized state are finalized
func RollappLatestStateIndexInvariant ¶ added in v3.1.0
RollappLatestStateIndexInvariant checks the following invariants per each rollapp that latest state index >= finalized state index
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, ibcclientKeeper types.IBCClientKeeper, transferKeeper types.TransferKeeper, channelKeeper types.ChannelKeeper, bankKeeper types.BankKeeper, denommetadataKeeper types.DenomMetadataKeeper, ) *Keeper
func (Keeper) DeployerWhitelist ¶
func (k Keeper) DeployerWhitelist(ctx sdk.Context) (res []types.DeployerParams)
DeployerWhitelist returns the DeployerWhitelist param
func (Keeper) DisputePeriodInBlocks ¶
DisputePeriodInBlocks returns the DisputePeriodInBlocks param
func (Keeper) FinalizeQueue ¶ added in v3.1.0
FinalizeQueue is called every block to finalize states when their dispute period over.
func (Keeper) FindStateInfoByHeight ¶
func (Keeper) GetAllBlockHeightToFinalizationQueue ¶
func (k Keeper) GetAllBlockHeightToFinalizationQueue(ctx sdk.Context) (list []types.BlockHeightToFinalizationQueue)
GetAllBlockHeightToFinalizationQueue returns all blockHeightToFinalizationQueue
func (Keeper) GetAllFinalizationQueueUntilHeight ¶ added in v3.1.0
func (k Keeper) GetAllFinalizationQueueUntilHeight(ctx sdk.Context, height uint64) (list []types.BlockHeightToFinalizationQueue)
GetAllFinalizationQueueUntilHeight returns all the blockHeightToFinalizationQueues with creation height equal or less to the input height
func (Keeper) GetAllLatestFinalizedStateIndex ¶
func (k Keeper) GetAllLatestFinalizedStateIndex(ctx sdk.Context) (list []types.StateInfoIndex)
GetAllLatestFinalizedStateIndex returns all latestFinalizedStateIndex
func (Keeper) GetAllLatestStateInfoIndex ¶
func (k Keeper) GetAllLatestStateInfoIndex(ctx sdk.Context) (list []types.StateInfoIndex)
GetAllLatestStateInfoIndex returns all latestStateInfoIndex
func (Keeper) GetAllRollapps ¶ added in v3.1.0
GetAllRollapp returns all rollapp
func (Keeper) GetAllStateInfo ¶
GetAllStateInfo returns all stateInfo
func (Keeper) GetBlockHeightToFinalizationQueue ¶
func (k Keeper) GetBlockHeightToFinalizationQueue( ctx sdk.Context, creationHeight uint64, ) (val types.BlockHeightToFinalizationQueue, found bool)
GetBlockHeightToFinalizationQueue returns a blockHeightToFinalizationQueue from its index
func (*Keeper) GetHooks ¶
func (k *Keeper) GetHooks() types.MultiRollappHooks
func (Keeper) GetLatestFinalizedStateIndex ¶
func (k Keeper) GetLatestFinalizedStateIndex( ctx sdk.Context, rollappId string, ) (val types.StateInfoIndex, found bool)
GetLatestFinalizedStateIndex returns a latestFinalizedStateIndex from its index
func (Keeper) GetLatestStateInfoIndex ¶
func (k Keeper) GetLatestStateInfoIndex( ctx sdk.Context, rollappId string, ) (val types.StateInfoIndex, found bool)
GetLatestStateInfoIndex returns a latestStateInfoIndex from its index
func (Keeper) GetRollapp ¶
GetRollapp returns a rollapp from its chain name
func (Keeper) GetRollappByEIP155 ¶
func (k Keeper) GetRollappByEIP155( ctx sdk.Context, eip155 uint64, ) (val types.Rollapp, found bool)
GetRollappByEIP155 returns a rollapp from its EIP155 id (https://github.com/ethereum/EIPs/blob/master/EIPS/eip-155.md) for EVM compatible rollapps
func (Keeper) GetStateInfo ¶
func (k Keeper) GetStateInfo( ctx sdk.Context, rollappId string, index uint64, ) (val types.StateInfo, found bool)
GetStateInfo returns a stateInfo from its index
func (Keeper) HandleFraud ¶ added in v3.1.0
func (k Keeper) HandleFraud(ctx sdk.Context, rollappID, clientId string, fraudHeight uint64, seqAddr string) error
HandleFraud handles the fraud evidence submitted by the user.
func (Keeper) IsAddressInDeployerWhiteList ¶ added in v3.1.0
func (Keeper) IsRollappStarted ¶ added in v3.1.0
IsRollappStarted returns true if the rollapp is started
func (Keeper) LatestHeight ¶ added in v3.1.0
func (k Keeper) LatestHeight(c context.Context, req *types.QueryGetLatestHeightRequest) (*types.QueryGetLatestHeightResponse, error)
func (Keeper) LatestStateIndex ¶
func (k Keeper) LatestStateIndex(c context.Context, req *types.QueryGetLatestStateIndexRequest) (*types.QueryGetLatestStateIndexResponse, error)
func (Keeper) MustGetStateInfo ¶ added in v3.1.0
func (Keeper) Params ¶
func (k Keeper) Params(c context.Context, req *types.QueryParamsRequest) (*types.QueryParamsResponse, error)
func (Keeper) RemoveBlockHeightToFinalizationQueue ¶
RemoveBlockHeightToFinalizationQueue removes a blockHeightToFinalizationQueue from the store
func (Keeper) RemoveLatestFinalizedStateIndex ¶
RemoveLatestFinalizedStateIndex removes a latestFinalizedStateIndex from the store
func (Keeper) RemoveLatestStateInfoIndex ¶
RemoveLatestStateInfoIndex removes a latestStateInfoIndex from the store
func (Keeper) RemoveRollapp ¶
RemoveRollapp removes a rollapp from the store using rollapp name
func (Keeper) RemoveStateInfo ¶
RemoveStateInfo removes a stateInfo from the store
func (Keeper) RevertPendingStates ¶ added in v3.1.0
revert all pending states of a rollapp
func (Keeper) Rollapp ¶
func (k Keeper) Rollapp(c context.Context, req *types.QueryGetRollappRequest) (*types.QueryGetRollappResponse, error)
func (Keeper) RollappAll ¶
func (k Keeper) RollappAll(c context.Context, req *types.QueryAllRollappRequest) (*types.QueryAllRollappResponse, error)
func (Keeper) RollappByEIP155 ¶
func (k Keeper) RollappByEIP155(c context.Context, req *types.QueryGetRollappByEIP155Request) (*types.QueryGetRollappResponse, error)
func (Keeper) SetBlockHeightToFinalizationQueue ¶
func (k Keeper) SetBlockHeightToFinalizationQueue(ctx sdk.Context, blockHeightToFinalizationQueue types.BlockHeightToFinalizationQueue)
SetBlockHeightToFinalizationQueue set a specific blockHeightToFinalizationQueue in the store from its index
func (*Keeper) SetHooks ¶
func (k *Keeper) SetHooks(sh types.MultiRollappHooks)
Set the rollapp hooks
func (Keeper) SetLatestFinalizedStateIndex ¶
func (k Keeper) SetLatestFinalizedStateIndex(ctx sdk.Context, latestFinalizedStateIndex types.StateInfoIndex)
SetLatestFinalizedStateIndex set a specific latestFinalizedStateIndex in the store from its index
func (Keeper) SetLatestStateInfoIndex ¶
func (k Keeper) SetLatestStateInfoIndex(ctx sdk.Context, latestStateInfoIndex types.StateInfoIndex)
SetLatestStateInfoIndex set a specific latestStateInfoIndex in the store from its index
func (Keeper) SetRollapp ¶
SetRollapp set a specific rollapp in the store from its index
func (Keeper) SetStateInfo ¶
SetStateInfo set a specific stateInfo in the store from its index
func (Keeper) StateInfo ¶
func (k Keeper) StateInfo(c context.Context, req *types.QueryGetStateInfoRequest) (*types.QueryGetStateInfoResponse, error)
Source Files ¶
- block_height_to_finalization_queue.go
- fraud_handler.go
- grpc_query.go
- grpc_query_latest_height.go
- grpc_query_latest_state_index.go
- grpc_query_params.go
- grpc_query_rollapp.go
- grpc_query_state_info.go
- invariants.go
- keeper.go
- latest_finalized_state_index.go
- latest_state_info_index.go
- msg_server.go
- msg_server_create_rollapp.go
- msg_server_update_state.go
- params.go
- rollapp.go
- state_info.go