Documentation ¶
Index ¶
- Constants
- type Keeper
- func (k Keeper) AuthenticateCapability(ctx sdk.Context, c *capabilitytypes.Capability, name string) bool
- func (k Keeper) BindPort(ctx sdk.Context, portID string) error
- func (k Keeper) ClaimCapability(ctx sdk.Context, c *capabilitytypes.Capability, name string) error
- func (k Keeper) ConnectionChannelID(c context.Context, req *types.QueryGetConnectionChannelIDRequest) (*types.QueryGetConnectionChannelIDResponse, error)
- func (k Keeper) ConsumerChainID(ctx sdk.Context) (res string)
- func (k Keeper) ConsumerClientID(c context.Context, req *types.QueryGetConsumerClientIDRequest) (*types.QueryGetConsumerClientIDResponse, error)
- func (k Keeper) ConsumerConsensusState(ctx sdk.Context) (res spntypes.ConsensusState)
- func (k Keeper) ConsumerRevisionHeight(ctx sdk.Context) (res uint64)
- func (k Keeper) ConsumerUnbondingPeriod(ctx sdk.Context) (res int64)
- func (k Keeper) GetConnectionChannelID(ctx sdk.Context) (val types.ConnectionChannelID, found bool)
- func (k Keeper) GetConsumerClientID(ctx sdk.Context) (val types.ConsumerClientID, found bool)
- func (k Keeper) GetMonitoringInfo(ctx sdk.Context) (val types.MonitoringInfo, found bool)
- func (k Keeper) GetParams(ctx sdk.Context) types.Params
- func (k Keeper) GetPort(ctx sdk.Context) string
- func (k Keeper) InitializeConsumerClient(ctx sdk.Context) (string, error)
- func (k Keeper) IsBound(ctx sdk.Context, portID string) bool
- func (k Keeper) LastBlockHeight(ctx sdk.Context) (res int64)
- func (k Keeper) Logger(ctx sdk.Context) log.Logger
- func (k Keeper) MonitoringInfo(c context.Context, req *types.QueryGetMonitoringInfoRequest) (*types.QueryGetMonitoringInfoResponse, error)
- func (k Keeper) OnAcknowledgementMonitoringPacket(ctx sdk.Context, packet channeltypes.Packet, data spntypes.MonitoringPacket, ...) error
- func (k Keeper) OnRecvMonitoringPacket(_ sdk.Context, _ channeltypes.Packet, _ spntypes.MonitoringPacket) (packetAck spntypes.MonitoringPacketAck, err error)
- func (k Keeper) OnTimeoutMonitoringPacket(_ sdk.Context, _ channeltypes.Packet, _ spntypes.MonitoringPacket) error
- func (k Keeper) Params(c context.Context, req *types.QueryParamsRequest) (*types.QueryParamsResponse, error)
- func (k Keeper) RegisterConnectionChannelID(ctx sdk.Context, channelID string) error
- func (k Keeper) RemoveMonitoringInfo(ctx sdk.Context)
- func (k Keeper) ReportBlockSignatures(ctx sdk.Context, lastCommit abci.CommitInfo, blockHeight int64) error
- func (k Keeper) SetConnectionChannelID(ctx sdk.Context, connectionChannelID types.ConnectionChannelID)
- func (k Keeper) SetConsumerClientID(ctx sdk.Context, consumerClientID types.ConsumerClientID)
- func (k Keeper) SetMonitoringInfo(ctx sdk.Context, monitoringInfo types.MonitoringInfo)
- func (k Keeper) SetParams(ctx sdk.Context, params types.Params)
- func (k Keeper) SetPort(ctx sdk.Context, portID string)
- func (k Keeper) TransmitMonitoringPacket(ctx sdk.Context, packetData spntypes.MonitoringPacket, ...) (sequence uint64, err error)
- func (k Keeper) TransmitSignatures(ctx sdk.Context, blockHeight int64) (sequence uint64, err error)
- func (k Keeper) VerifyClientIDFromConnID(ctx sdk.Context, connID string) error
Constants ¶
const ( // MonitoringPacketTimeoutDelay is the delay before a monitoring packet is timed out // The timeout is set to one year // This is an arbitrarily chosen value that should never be reached in practice MonitoringPacketTimeoutDelay = time.Hour * 8760 )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
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, stakingKeeper types.StakingKeeper, clientKeeper types.ClientKeeper, connectionKeeper types.ConnectionKeeper, channelKeeper types.ChannelKeeper, portKeeper types.PortKeeper, scopedKeeper capabilitykeeper.ScopedKeeper, ) *Keeper
func (Keeper) AuthenticateCapability ¶
func (k Keeper) AuthenticateCapability(ctx sdk.Context, c *capabilitytypes.Capability, name string) bool
AuthenticateCapability wraps the scopedKeeper's AuthenticateCapability function
func (Keeper) BindPort ¶
BindPort defines a wrapper function for the ort Keeper's function in order to expose it to module's InitGenesis function
func (Keeper) ClaimCapability ¶
func (k Keeper) ClaimCapability(ctx sdk.Context, c *capabilitytypes.Capability, name string) error
ClaimCapability allows the transfer module that can claim a capability that IBC module passes to it
func (Keeper) ConnectionChannelID ¶
func (k Keeper) ConnectionChannelID(c context.Context, req *types.QueryGetConnectionChannelIDRequest) (*types.QueryGetConnectionChannelIDResponse, error)
func (Keeper) ConsumerChainID ¶
ConsumerChainID returns the consumer chain ID param
func (Keeper) ConsumerClientID ¶
func (k Keeper) ConsumerClientID(c context.Context, req *types.QueryGetConsumerClientIDRequest) (*types.QueryGetConsumerClientIDResponse, error)
func (Keeper) ConsumerConsensusState ¶
func (k Keeper) ConsumerConsensusState(ctx sdk.Context) (res spntypes.ConsensusState)
ConsumerConsensusState returns the consumer consensus state param
func (Keeper) ConsumerRevisionHeight ¶
ConsumerRevisionHeight returns the consumer revision height
func (Keeper) ConsumerUnbondingPeriod ¶
ConsumerUnbondingPeriod returns the consumer unbonding period
func (Keeper) GetConnectionChannelID ¶
GetConnectionChannelID returns connectionChannelID
func (Keeper) GetConsumerClientID ¶
GetConsumerClientID returns consumerClientID
func (Keeper) GetMonitoringInfo ¶
GetMonitoringInfo returns monitoringInfo
func (Keeper) InitializeConsumerClient ¶
InitializeConsumerClient initializes the consumer IBC client and set it in the store
func (Keeper) LastBlockHeight ¶
LastBlockHeight returns the last block height state param
func (Keeper) MonitoringInfo ¶
func (k Keeper) MonitoringInfo(c context.Context, req *types.QueryGetMonitoringInfoRequest) (*types.QueryGetMonitoringInfoResponse, error)
func (Keeper) OnAcknowledgementMonitoringPacket ¶
func (k Keeper) OnAcknowledgementMonitoringPacket( ctx sdk.Context, packet channeltypes.Packet, data spntypes.MonitoringPacket, ack channeltypes.Acknowledgement, ) error
OnAcknowledgementMonitoringPacket responds to the the success or failure of a packet acknowledgement written on the receiving chain.
func (Keeper) OnRecvMonitoringPacket ¶
func (k Keeper) OnRecvMonitoringPacket( _ sdk.Context, _ channeltypes.Packet, _ spntypes.MonitoringPacket, ) (packetAck spntypes.MonitoringPacketAck, err error)
OnRecvMonitoringPacket processes packet reception
func (Keeper) OnTimeoutMonitoringPacket ¶
func (k Keeper) OnTimeoutMonitoringPacket( _ sdk.Context, _ channeltypes.Packet, _ spntypes.MonitoringPacket, ) error
OnTimeoutMonitoringPacket responds to the case where a packet has not been transmitted because of a timeout
func (Keeper) Params ¶
func (k Keeper) Params(c context.Context, req *types.QueryParamsRequest) (*types.QueryParamsResponse, error)
func (Keeper) RegisterConnectionChannelID ¶
RegisterConnectionChannelID registers the channel ID for the connection used with the consumer chain
func (Keeper) RemoveMonitoringInfo ¶
RemoveMonitoringInfo removes monitoringInfo from the store
func (Keeper) ReportBlockSignatures ¶
func (k Keeper) ReportBlockSignatures(ctx sdk.Context, lastCommit abci.CommitInfo, blockHeight int64) error
ReportBlockSignatures gets signatures from blocks and update monitoring info
func (Keeper) SetConnectionChannelID ¶
func (k Keeper) SetConnectionChannelID(ctx sdk.Context, connectionChannelID types.ConnectionChannelID)
SetConnectionChannelID set connectionChannelID in the store
func (Keeper) SetConsumerClientID ¶
func (k Keeper) SetConsumerClientID(ctx sdk.Context, consumerClientID types.ConsumerClientID)
SetConsumerClientID set consumerClientID in the store
func (Keeper) SetMonitoringInfo ¶
func (k Keeper) SetMonitoringInfo(ctx sdk.Context, monitoringInfo types.MonitoringInfo)
SetMonitoringInfo set monitoringInfo in the store
func (Keeper) TransmitMonitoringPacket ¶
func (k Keeper) TransmitMonitoringPacket( ctx sdk.Context, packetData spntypes.MonitoringPacket, sourcePort, sourceChannel string, timeoutHeight clienttypes.Height, timeoutTimestamp uint64, ) (sequence uint64, err error)
TransmitMonitoringPacket transmits the packet over IBC with the specified source port and source channel
func (Keeper) TransmitSignatures ¶
TransmitSignatures transmits over IBC the signatures to consumer if height is reached and signatures are not yet transmitted
func (Keeper) VerifyClientIDFromConnID ¶ added in v0.3.0
VerifyClientIDFromConnID verifies if the client ID associated with the provided connection ID is the consumer client ID and if no connection is yet established with the consumer chain this operation should be performed at OnChanOpenTry handshake phase