Documentation ¶
Index ¶
- Constants
- Variables
- func RegisterCodec(cdc *codec.Codec)
- func SetSubModuleCodec(cdc *codec.Codec)
- type ClientState
- func (cs ClientState) ClientType() clientexported.ClientType
- func (cs ClientState) GetChainID() string
- func (cs ClientState) GetID() string
- func (cs ClientState) GetLatestHeight() uint64
- func (cs ClientState) IsFrozen() bool
- func (cs ClientState) Validate() error
- func (cs ClientState) VerifyChannelState(store sdk.KVStore, cdc codec.Marshaler, _ uint64, ...) error
- func (cs ClientState) VerifyClientConsensusState(store sdk.KVStore, cdc *codec.Codec, _ commitmentexported.Root, height uint64, ...) error
- func (cs ClientState) VerifyConnectionState(store sdk.KVStore, cdc codec.Marshaler, _ uint64, ...) error
- func (cs ClientState) VerifyNextSequenceRecv(store sdk.KVStore, _ uint64, prefix commitmentexported.Prefix, ...) error
- func (cs ClientState) VerifyPacketAcknowledgement(store sdk.KVStore, _ uint64, prefix commitmentexported.Prefix, ...) error
- func (cs ClientState) VerifyPacketAcknowledgementAbsence(store sdk.KVStore, _ uint64, prefix commitmentexported.Prefix, ...) error
- func (cs ClientState) VerifyPacketCommitment(store sdk.KVStore, _ uint64, prefix commitmentexported.Prefix, ...) error
- type MsgCreateClient
- func (msg MsgCreateClient) GetClientID() string
- func (msg MsgCreateClient) GetClientType() string
- func (msg MsgCreateClient) GetConsensusState() clientexported.ConsensusState
- func (msg MsgCreateClient) GetSignBytes() []byte
- func (msg MsgCreateClient) GetSigners() []sdk.AccAddress
- func (msg MsgCreateClient) Route() string
- func (msg MsgCreateClient) Type() string
- func (msg MsgCreateClient) ValidateBasic() error
Constants ¶
const (
// SubModuleName for the localhost (loopback) client
SubModuleName = "localhost"
)
const (
TypeMsgCreateClient string = "create_client"
)
Message types for the IBC client
Variables ¶
var SubModuleCdc *codec.Codec
SubModuleCdc defines the IBC localhost client codec.
Functions ¶
func RegisterCodec ¶
RegisterCodec registers the localhost types
func SetSubModuleCodec ¶
SetSubModuleCodec sets the ibc localhost client codec
Types ¶
type ClientState ¶
type ClientState struct { ID string `json:"id" yaml:"id"` ChainID string `json:"chain_id" yaml:"chain_id"` Height int64 `json:"height" yaml:"height"` }
ClientState requires (read-only) access to keys outside the client prefix.
func NewClientState ¶
func NewClientState(chainID string, height int64) ClientState
NewClientState creates a new ClientState instance
func (ClientState) ClientType ¶
func (cs ClientState) ClientType() clientexported.ClientType
ClientType is localhost.
func (ClientState) GetChainID ¶
func (cs ClientState) GetChainID() string
GetChainID returns an empty string
func (ClientState) GetID ¶
func (cs ClientState) GetID() string
GetID returns the loop-back client state identifier.
func (ClientState) GetLatestHeight ¶
func (cs ClientState) GetLatestHeight() uint64
GetLatestHeight returns the latest height stored.
func (ClientState) Validate ¶
func (cs ClientState) Validate() error
Validate performs a basic validation of the client state fields.
func (ClientState) VerifyChannelState ¶
func (cs ClientState) VerifyChannelState( store sdk.KVStore, cdc codec.Marshaler, _ uint64, prefix commitmentexported.Prefix, _ commitmentexported.Proof, portID, channelID string, channel channelexported.ChannelI, _ clientexported.ConsensusState, ) error
VerifyChannelState verifies a proof of the channel state of the specified channel end, under the specified port, stored on the local machine.
func (ClientState) VerifyClientConsensusState ¶
func (cs ClientState) VerifyClientConsensusState( store sdk.KVStore, cdc *codec.Codec, _ commitmentexported.Root, height uint64, _ string, consensusHeight uint64, prefix commitmentexported.Prefix, _ commitmentexported.Proof, consensusState clientexported.ConsensusState, ) error
VerifyClientConsensusState verifies a proof of the consensus state of the loop-back client. VerifyClientConsensusState verifies a proof of the consensus state of the Tendermint client stored on the target machine.
func (ClientState) VerifyConnectionState ¶
func (cs ClientState) VerifyConnectionState( store sdk.KVStore, cdc codec.Marshaler, _ uint64, prefix commitmentexported.Prefix, _ commitmentexported.Proof, connectionID string, connectionEnd connectionexported.ConnectionI, _ clientexported.ConsensusState, ) error
VerifyConnectionState verifies a proof of the connection state of the specified connection end stored locally.
func (ClientState) VerifyNextSequenceRecv ¶
func (cs ClientState) VerifyNextSequenceRecv( store sdk.KVStore, _ uint64, prefix commitmentexported.Prefix, _ commitmentexported.Proof, portID, channelID string, nextSequenceRecv uint64, _ clientexported.ConsensusState, ) error
VerifyNextSequenceRecv verifies a proof of the next sequence number to be received of the specified channel at the specified port.
func (ClientState) VerifyPacketAcknowledgement ¶
func (cs ClientState) VerifyPacketAcknowledgement( store sdk.KVStore, _ uint64, prefix commitmentexported.Prefix, _ commitmentexported.Proof, portID, channelID string, sequence uint64, acknowledgement []byte, _ clientexported.ConsensusState, ) error
VerifyPacketAcknowledgement verifies a proof of an incoming packet acknowledgement at the specified port, specified channel, and specified sequence.
func (ClientState) VerifyPacketAcknowledgementAbsence ¶
func (cs ClientState) VerifyPacketAcknowledgementAbsence( store sdk.KVStore, _ uint64, prefix commitmentexported.Prefix, _ commitmentexported.Proof, portID, channelID string, sequence uint64, _ clientexported.ConsensusState, ) error
VerifyPacketAcknowledgementAbsence verifies a proof of the absence of an incoming packet acknowledgement at the specified port, specified channel, and specified sequence.
func (ClientState) VerifyPacketCommitment ¶
func (cs ClientState) VerifyPacketCommitment( store sdk.KVStore, _ uint64, prefix commitmentexported.Prefix, _ commitmentexported.Proof, portID, channelID string, sequence uint64, commitmentBytes []byte, _ clientexported.ConsensusState, ) error
VerifyPacketCommitment verifies a proof of an outgoing packet commitment at the specified port, specified channel, and specified sequence.
type MsgCreateClient ¶
type MsgCreateClient struct {
Signer sdk.AccAddress `json:"address" yaml:"address"`
}
MsgCreateClient defines a message to create an IBC client
func NewMsgCreateClient ¶
func NewMsgCreateClient(signer sdk.AccAddress) MsgCreateClient
NewMsgCreateClient creates a new MsgCreateClient instance
func (MsgCreateClient) GetClientID ¶
func (msg MsgCreateClient) GetClientID() string
GetClientID implements clientexported.MsgCreateClient
func (MsgCreateClient) GetClientType ¶
func (msg MsgCreateClient) GetClientType() string
GetClientType implements clientexported.MsgCreateClient
func (MsgCreateClient) GetConsensusState ¶
func (msg MsgCreateClient) GetConsensusState() clientexported.ConsensusState
GetConsensusState implements clientexported.MsgCreateClient
func (MsgCreateClient) GetSignBytes ¶
func (msg MsgCreateClient) GetSignBytes() []byte
GetSignBytes implements sdk.Msg
func (MsgCreateClient) GetSigners ¶
func (msg MsgCreateClient) GetSigners() []sdk.AccAddress
GetSigners implements sdk.Msg
func (MsgCreateClient) ValidateBasic ¶
func (msg MsgCreateClient) ValidateBasic() error
ValidateBasic implements sdk.Msg