types

package
v8.5.2 Latest Latest
Warning

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

Go to latest
Published: Nov 5, 2024 License: MIT Imports: 41 Imported by: 423

Documentation

Overview

Package types is a reverse proxy.

It translates gRPC into RESTful JSON APIs.

Index

Constants

View Source
const (
	AttributeKeyConnectionID   = "connection_id"
	AttributeKeyPortID         = "port_id"
	AttributeKeyChannelID      = "channel_id"
	AttributeKeyChannelState   = "channel_state"
	AttributeVersion           = "version"
	AttributeKeyConnectionHops = "connection_hops"
	AttributeKeyOrdering       = "ordering"

	// upgrade specific keys
	AttributeKeyUpgradeTimeoutHeight    = "timeout_height"
	AttributeKeyUpgradeTimeoutTimestamp = "timeout_timestamp"
	AttributeKeyUpgradeSequence         = "upgrade_sequence"
	AttributeKeyErrorReceipt            = "error_receipt"

	AttributeCounterpartyPortID    = "counterparty_port_id"
	AttributeCounterpartyChannelID = "counterparty_channel_id"

	EventTypeSendPacket        = "send_packet"
	EventTypeRecvPacket        = "recv_packet"
	EventTypeWriteAck          = "write_acknowledgement"
	EventTypeAcknowledgePacket = "acknowledge_packet"
	EventTypeTimeoutPacket     = "timeout_packet"

	// Deprecated: in favor of AttributeKeyDataHex
	AttributeKeyData = "packet_data"
	// Deprecated: in favor of AttributeKeyAckHex
	AttributeKeyAck = "packet_ack"

	AttributeKeyDataHex          = "packet_data_hex"
	AttributeKeyAckHex           = "packet_ack_hex"
	AttributeKeyTimeoutHeight    = "packet_timeout_height"
	AttributeKeyTimeoutTimestamp = "packet_timeout_timestamp"
	AttributeKeySequence         = "packet_sequence"
	AttributeKeySrcPort          = "packet_src_port"
	AttributeKeySrcChannel       = "packet_src_channel"
	AttributeKeyDstPort          = "packet_dst_port"
	AttributeKeyDstChannel       = "packet_dst_channel"
	AttributeKeyChannelOrdering  = "packet_channel_ordering"
	AttributeKeyConnection       = "packet_connection"
)

IBC channel events

View Source
const (
	// SubModuleName defines the IBC channels name
	SubModuleName = "channel"

	// StoreKey is the store key string for IBC channels
	StoreKey = SubModuleName

	// RouterKey is the message route for IBC channels
	RouterKey = SubModuleName

	// QuerierRoute is the querier route for IBC channels
	QuerierRoute = SubModuleName

	// KeyNextChannelSequence is the key used to store the next channel sequence in
	// the keeper.
	KeyNextChannelSequence = "nextChannelSequence"

	// ChannelPrefix is the prefix used when creating a channel identifier
	ChannelPrefix = "channel-"

	// ParamsKey defines the key to store the params in the keeper.
	ParamsKey = "channelParams"
)

Variables

View Source
var (
	ErrInvalidLengthChannel        = fmt.Errorf("proto: negative length found during unmarshaling")
	ErrIntOverflowChannel          = fmt.Errorf("proto: integer overflow")
	ErrUnexpectedEndOfGroupChannel = fmt.Errorf("proto: unexpected end of group")
)
View Source
var (
	ErrChannelExists             = errorsmod.Register(SubModuleName, 2, "channel already exists")
	ErrChannelNotFound           = errorsmod.Register(SubModuleName, 3, "channel not found")
	ErrInvalidChannel            = errorsmod.Register(SubModuleName, 4, "invalid channel")
	ErrInvalidChannelState       = errorsmod.Register(SubModuleName, 5, "invalid channel state")
	ErrInvalidChannelOrdering    = errorsmod.Register(SubModuleName, 6, "invalid channel ordering")
	ErrInvalidCounterparty       = errorsmod.Register(SubModuleName, 7, "invalid counterparty channel")
	ErrInvalidChannelCapability  = errorsmod.Register(SubModuleName, 8, "invalid channel capability")
	ErrChannelCapabilityNotFound = errorsmod.Register(SubModuleName, 9, "channel capability not found")
	ErrSequenceSendNotFound      = errorsmod.Register(SubModuleName, 10, "sequence send not found")
	ErrSequenceReceiveNotFound   = errorsmod.Register(SubModuleName, 11, "sequence receive not found")
	ErrSequenceAckNotFound       = errorsmod.Register(SubModuleName, 12, "sequence acknowledgement not found")
	ErrInvalidPacket             = errorsmod.Register(SubModuleName, 13, "invalid packet")
	ErrPacketTimeout             = errorsmod.Register(SubModuleName, 14, "packet timeout")
	ErrTooManyConnectionHops     = errorsmod.Register(SubModuleName, 15, "too many connection hops")
	ErrInvalidAcknowledgement    = errorsmod.Register(SubModuleName, 16, "invalid acknowledgement")
	ErrAcknowledgementExists     = errorsmod.Register(SubModuleName, 17, "acknowledgement for packet already exists")
	ErrInvalidChannelIdentifier  = errorsmod.Register(SubModuleName, 18, "invalid channel identifier")

	// packets already relayed errors
	ErrPacketReceived           = errorsmod.Register(SubModuleName, 19, "packet already received")
	ErrPacketCommitmentNotFound = errorsmod.Register(SubModuleName, 20, "packet commitment not found") // may occur for already received acknowledgements or timeouts and in rare cases for packets never sent

	// ORDERED channel error
	ErrPacketSequenceOutOfOrder = errorsmod.Register(SubModuleName, 21, "packet sequence is out of order")

	// Antehandler error
	ErrRedundantTx = errorsmod.Register(SubModuleName, 22, "packet messages are redundant")

	// Perform a no-op on the current Msg
	ErrNoOpMsg = errorsmod.Register(SubModuleName, 23, "message is redundant, no-op will be performed")

	ErrInvalidChannelVersion           = errorsmod.Register(SubModuleName, 24, "invalid channel version")
	ErrPacketNotSent                   = errorsmod.Register(SubModuleName, 25, "packet has not been sent")
	ErrInvalidTimeout                  = errorsmod.Register(SubModuleName, 26, "invalid packet timeout")
	ErrUpgradeErrorNotFound            = errorsmod.Register(SubModuleName, 27, "upgrade error receipt not found")
	ErrInvalidUpgrade                  = errorsmod.Register(SubModuleName, 28, "invalid upgrade")
	ErrInvalidUpgradeSequence          = errorsmod.Register(SubModuleName, 29, "invalid upgrade sequence")
	ErrUpgradeNotFound                 = errorsmod.Register(SubModuleName, 30, "upgrade not found")
	ErrIncompatibleCounterpartyUpgrade = errorsmod.Register(SubModuleName, 31, "incompatible counterparty upgrade")
	ErrInvalidUpgradeError             = errorsmod.Register(SubModuleName, 32, "invalid upgrade error")
	ErrUpgradeRestoreFailed            = errorsmod.Register(SubModuleName, 33, "restore failed")
	ErrUpgradeTimeout                  = errorsmod.Register(SubModuleName, 34, "upgrade timed-out")
	ErrInvalidUpgradeTimeout           = errorsmod.Register(SubModuleName, 35, "upgrade timeout is invalid")
	ErrPendingInflightPackets          = errorsmod.Register(SubModuleName, 36, "pending inflight packets exist")
	ErrUpgradeTimeoutFailed            = errorsmod.Register(SubModuleName, 37, "upgrade timeout failed")
	ErrInvalidPruningLimit             = errorsmod.Register(SubModuleName, 38, "invalid pruning limit")
	ErrTimeoutNotReached               = errorsmod.Register(SubModuleName, 39, "timeout not reached")
	ErrTimeoutElapsed                  = errorsmod.Register(SubModuleName, 40, "timeout elapsed")
	ErrPruningSequenceStartNotFound    = errorsmod.Register(SubModuleName, 41, "pruning sequence start not found")
	ErrRecvStartSequenceNotFound       = errorsmod.Register(SubModuleName, 42, "recv start sequence not found")
)

IBC channel sentinel errors

View Source
var (
	EventTypeChannelOpenInit       = "channel_open_init"
	EventTypeChannelOpenTry        = "channel_open_try"
	EventTypeChannelOpenAck        = "channel_open_ack"
	EventTypeChannelOpenConfirm    = "channel_open_confirm"
	EventTypeChannelCloseInit      = "channel_close_init"
	EventTypeChannelCloseConfirm   = "channel_close_confirm"
	EventTypeChannelClosed         = "channel_close"
	EventTypeChannelUpgradeInit    = "channel_upgrade_init"
	EventTypeChannelUpgradeTry     = "channel_upgrade_try"
	EventTypeChannelUpgradeAck     = "channel_upgrade_ack"
	EventTypeChannelUpgradeConfirm = "channel_upgrade_confirm"
	EventTypeChannelUpgradeOpen    = "channel_upgrade_open"
	EventTypeChannelUpgradeTimeout = "channel_upgrade_timeout"
	EventTypeChannelUpgradeCancel  = "channel_upgrade_cancelled"
	EventTypeChannelUpgradeError   = "channel_upgrade_error"
	EventTypeChannelFlushComplete  = "channel_flush_complete"

	AttributeValueCategory = fmt.Sprintf("%s_%s", ibcexported.ModuleName, SubModuleName)
)

IBC channel events vars

View Source
var (
	ErrInvalidLengthGenesis        = fmt.Errorf("proto: negative length found during unmarshaling")
	ErrIntOverflowGenesis          = fmt.Errorf("proto: integer overflow")
	ErrUnexpectedEndOfGroupGenesis = fmt.Errorf("proto: unexpected end of group")
)
View Source
var (
	ErrInvalidLengthQuery        = fmt.Errorf("proto: negative length found during unmarshaling")
	ErrIntOverflowQuery          = fmt.Errorf("proto: integer overflow")
	ErrUnexpectedEndOfGroupQuery = fmt.Errorf("proto: unexpected end of group")
)
View Source
var (
	ErrInvalidLengthTx        = fmt.Errorf("proto: negative length found during unmarshaling")
	ErrIntOverflowTx          = fmt.Errorf("proto: integer overflow")
	ErrUnexpectedEndOfGroupTx = fmt.Errorf("proto: unexpected end of group")
)
View Source
var (
	ErrInvalidLengthUpgrade        = fmt.Errorf("proto: negative length found during unmarshaling")
	ErrIntOverflowUpgrade          = fmt.Errorf("proto: integer overflow")
	ErrUnexpectedEndOfGroupUpgrade = fmt.Errorf("proto: unexpected end of group")
)
View Source
var DefaultTimeout = NewTimeout(clienttypes.ZeroHeight(), uint64(10*time.Minute.Nanoseconds()))

DefaultTimeout defines a default parameter for the channel upgrade protocol. It allows relayers a window in which they can flush all in-flight packets on a channel before completing the upgrade handshake. This parameter can be overridden by a valid authority using the UpdateChannelParams rpc.

View Source
var IsChannelIDFormat = regexp.MustCompile(`^channel-[0-9]{1,20}$`).MatchString

IsChannelIDFormat checks if a channelID is in the format required on the SDK for parsing channel identifiers. The channel identifier must be in the form: `channel-{N}

View Source
var Order_name = map[int32]string{
	0: "ORDER_NONE_UNSPECIFIED",
	1: "ORDER_UNORDERED",
	2: "ORDER_ORDERED",
}
View Source
var Order_value = map[string]int32{
	"ORDER_NONE_UNSPECIFIED": 0,
	"ORDER_UNORDERED":        1,
	"ORDER_ORDERED":          2,
}
View Source
var ResponseResultType_name = map[int32]string{
	0: "RESPONSE_RESULT_TYPE_UNSPECIFIED",
	1: "RESPONSE_RESULT_TYPE_NOOP",
	2: "RESPONSE_RESULT_TYPE_SUCCESS",
	3: "RESPONSE_RESULT_TYPE_FAILURE",
}
View Source
var ResponseResultType_value = map[string]int32{
	"RESPONSE_RESULT_TYPE_UNSPECIFIED": 0,
	"RESPONSE_RESULT_TYPE_NOOP":        1,
	"RESPONSE_RESULT_TYPE_SUCCESS":     2,
	"RESPONSE_RESULT_TYPE_FAILURE":     3,
}
View Source
var State_name = map[int32]string{
	0: "STATE_UNINITIALIZED_UNSPECIFIED",
	1: "STATE_INIT",
	2: "STATE_TRYOPEN",
	3: "STATE_OPEN",
	4: "STATE_CLOSED",
	5: "STATE_FLUSHING",
	6: "STATE_FLUSHCOMPLETE",
}
View Source
var State_value = map[string]int32{
	"STATE_UNINITIALIZED_UNSPECIFIED": 0,
	"STATE_INIT":                      1,
	"STATE_TRYOPEN":                   2,
	"STATE_OPEN":                      3,
	"STATE_CLOSED":                    4,
	"STATE_FLUSHING":                  5,
	"STATE_FLUSHCOMPLETE":             6,
}

SubModuleCdc references the global x/ibc/core/04-channel module codec. Note, the codec should ONLY be used in certain instances of tests and for JSON encoding.

The actual codec used for serialization should be provided to x/ibc/core/04-channel and defined at the application level.

Functions

func CommitAcknowledgement

func CommitAcknowledgement(data []byte) []byte

CommitAcknowledgement returns the hash of commitment bytes

func CommitPacket

func CommitPacket(cdc codec.BinaryCodec, packet exported.PacketI) []byte

CommitPacket returns the packet commitment bytes. The commitment consists of: sha256_hash(timeout_timestamp + timeout_height.RevisionNumber + timeout_height.RevisionHeight + sha256_hash(data)) from a given packet. This results in a fixed length preimage. NOTE: sdk.Uint64ToBigEndian sets the uint64 to a slice of length 8.

func FilteredPortPrefix

func FilteredPortPrefix(portPrefix string) []byte

FilteredPortPrefix returns the prefix key for the given port prefix.

func FormatChannelIdentifier

func FormatChannelIdentifier(sequence uint64) string

FormatChannelIdentifier returns the channel identifier with the sequence appended. This is a SDK specific format not enforced by IBC protocol.

func IsUpgradeError added in v8.1.0

func IsUpgradeError(err error) bool

IsUpgradeError returns true if err is of type UpgradeError or contained in the error chain of err and false otherwise.

func IsValidChannelID

func IsValidChannelID(channelID string) bool

IsValidChannelID checks if a channelID is valid and can be parsed to the channel identifier format.

func ParseChannelSequence

func ParseChannelSequence(channelID string) (uint64, error)

ParseChannelSequence parses the channel sequence from the channel identifier.

func RegisterInterfaces

func RegisterInterfaces(registry codectypes.InterfaceRegistry)

RegisterInterfaces register the ibc channel submodule interfaces to protobuf Any.

func RegisterMsgServer

func RegisterMsgServer(s grpc1.Server, srv MsgServer)

func RegisterQueryHandler

func RegisterQueryHandler(ctx context.Context, mux *runtime.ServeMux, conn *grpc.ClientConn) error

RegisterQueryHandler registers the http handlers for service Query to "mux". The handlers forward requests to the grpc endpoint over "conn".

func RegisterQueryHandlerClient

func RegisterQueryHandlerClient(ctx context.Context, mux *runtime.ServeMux, client QueryClient) error

RegisterQueryHandlerClient registers the http handlers for service Query to "mux". The handlers forward requests to the grpc endpoint over the given implementation of "QueryClient". Note: the gRPC framework executes interceptors within the gRPC handler. If the passed in "QueryClient" doesn't go through the normal gRPC flow (creating a gRPC client etc.) then it will be up to the passed in "QueryClient" to call the correct interceptors.

func RegisterQueryHandlerFromEndpoint

func RegisterQueryHandlerFromEndpoint(ctx context.Context, mux *runtime.ServeMux, endpoint string, opts []grpc.DialOption) (err error)

RegisterQueryHandlerFromEndpoint is same as RegisterQueryHandler but automatically dials to "endpoint" and closes the connection when "ctx" gets done.

func RegisterQueryHandlerServer

func RegisterQueryHandlerServer(ctx context.Context, mux *runtime.ServeMux, server QueryServer) error

RegisterQueryHandlerServer registers the http handlers for service Query to "mux". UnaryRPC :call QueryServer directly. StreamingRPC :currently unsupported pending https://github.com/grpc/grpc-go/issues/906. Note that using this registration option will cause many gRPC library features to stop working. Consider using RegisterQueryHandlerFromEndpoint instead.

func RegisterQueryServer

func RegisterQueryServer(s grpc1.Server, srv QueryServer)

Types

type Acknowledgement

type Acknowledgement struct {
	// response contains either a result or an error and must be non-empty
	//
	// Types that are valid to be assigned to Response:
	//	*Acknowledgement_Result
	//	*Acknowledgement_Error
	Response isAcknowledgement_Response `protobuf_oneof:"response"`
}

Acknowledgement is the recommended acknowledgement format to be used by app-specific protocols. NOTE: The field numbers 21 and 22 were explicitly chosen to avoid accidental conflicts with other protobuf message formats used for acknowledgements. The first byte of any message with this format will be the non-ASCII values `0xaa` (result) or `0xb2` (error). Implemented as defined by ICS: https://github.com/cosmos/ibc/tree/master/spec/core/ics-004-channel-and-packet-semantics#acknowledgement-envelope

func NewErrorAcknowledgement

func NewErrorAcknowledgement(err error) Acknowledgement

NewErrorAcknowledgement returns a new instance of Acknowledgement using an Acknowledgement_Error type in the Response field. NOTE: Acknowledgements are written into state and thus, changes made to error strings included in packet acknowledgements risk an app hash divergence when nodes in a network are running different patch versions of software.

func NewErrorAcknowledgementWithCodespace added in v8.3.0

func NewErrorAcknowledgementWithCodespace(err error) Acknowledgement

NewErrorAcknowledgementWithCodespace returns a new instance of Acknowledgement using an Acknowledgement_Error type in the Response field. NOTE: The error includes the ABCI codespace and code in the error string to provide more information about the module that generated the error. This is useful for debugging but can potentially introduce non-determinism if care is not taken to ensure the codespace doesn't change in non state-machine breaking versions.

func NewResultAcknowledgement

func NewResultAcknowledgement(result []byte) Acknowledgement

NewResultAcknowledgement returns a new instance of Acknowledgement using an Acknowledgement_Result type in the Response field.

func (Acknowledgement) Acknowledgement

func (ack Acknowledgement) Acknowledgement() []byte

Acknowledgement implements the Acknowledgement interface. It returns the acknowledgement serialised using JSON.

func (*Acknowledgement) Descriptor

func (*Acknowledgement) Descriptor() ([]byte, []int)

func (*Acknowledgement) GetError

func (m *Acknowledgement) GetError() string

func (*Acknowledgement) GetResponse

func (m *Acknowledgement) GetResponse() isAcknowledgement_Response

func (*Acknowledgement) GetResult

func (m *Acknowledgement) GetResult() []byte

func (*Acknowledgement) Marshal

func (m *Acknowledgement) Marshal() (dAtA []byte, err error)

func (*Acknowledgement) MarshalTo

func (m *Acknowledgement) MarshalTo(dAtA []byte) (int, error)

func (*Acknowledgement) MarshalToSizedBuffer

func (m *Acknowledgement) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*Acknowledgement) ProtoMessage

func (*Acknowledgement) ProtoMessage()

func (*Acknowledgement) Reset

func (m *Acknowledgement) Reset()

func (*Acknowledgement) Size

func (m *Acknowledgement) Size() (n int)

func (*Acknowledgement) String

func (m *Acknowledgement) String() string

func (Acknowledgement) Success

func (ack Acknowledgement) Success() bool

Success implements the Acknowledgement interface. The acknowledgement is considered successful if it is a ResultAcknowledgement. Otherwise it is considered a failed acknowledgement.

func (*Acknowledgement) Unmarshal

func (m *Acknowledgement) Unmarshal(dAtA []byte) error

func (Acknowledgement) ValidateBasic

func (ack Acknowledgement) ValidateBasic() error

ValidateBasic performs a basic validation of the acknowledgement

func (*Acknowledgement) XXX_DiscardUnknown

func (m *Acknowledgement) XXX_DiscardUnknown()

func (*Acknowledgement) XXX_Marshal

func (m *Acknowledgement) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*Acknowledgement) XXX_Merge

func (m *Acknowledgement) XXX_Merge(src proto.Message)

func (*Acknowledgement) XXX_OneofWrappers

func (*Acknowledgement) XXX_OneofWrappers() []interface{}

XXX_OneofWrappers is for the internal use of the proto package.

func (*Acknowledgement) XXX_Size

func (m *Acknowledgement) XXX_Size() int

func (*Acknowledgement) XXX_Unmarshal

func (m *Acknowledgement) XXX_Unmarshal(b []byte) error

type Acknowledgement_Error

type Acknowledgement_Error struct {
	Error string `protobuf:"bytes,22,opt,name=error,proto3,oneof" json:"error,omitempty"`
}

func (*Acknowledgement_Error) MarshalTo

func (m *Acknowledgement_Error) MarshalTo(dAtA []byte) (int, error)

func (*Acknowledgement_Error) MarshalToSizedBuffer

func (m *Acknowledgement_Error) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*Acknowledgement_Error) Size

func (m *Acknowledgement_Error) Size() (n int)

type Acknowledgement_Result

type Acknowledgement_Result struct {
	Result []byte `protobuf:"bytes,21,opt,name=result,proto3,oneof" json:"result,omitempty"`
}

func (*Acknowledgement_Result) MarshalTo

func (m *Acknowledgement_Result) MarshalTo(dAtA []byte) (int, error)

func (*Acknowledgement_Result) MarshalToSizedBuffer

func (m *Acknowledgement_Result) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*Acknowledgement_Result) Size

func (m *Acknowledgement_Result) Size() (n int)

type Channel

type Channel struct {
	// current state of the channel end
	State State `protobuf:"varint,1,opt,name=state,proto3,enum=ibc.core.channel.v1.State" json:"state,omitempty"`
	// whether the channel is ordered or unordered
	Ordering Order `protobuf:"varint,2,opt,name=ordering,proto3,enum=ibc.core.channel.v1.Order" json:"ordering,omitempty"`
	// counterparty channel end
	Counterparty Counterparty `protobuf:"bytes,3,opt,name=counterparty,proto3" json:"counterparty"`
	// list of connection identifiers, in order, along which packets sent on
	// this channel will travel
	ConnectionHops []string `protobuf:"bytes,4,rep,name=connection_hops,json=connectionHops,proto3" json:"connection_hops,omitempty"`
	// opaque channel version, which is agreed upon during the handshake
	Version string `protobuf:"bytes,5,opt,name=version,proto3" json:"version,omitempty"`
	// upgrade sequence indicates the latest upgrade attempt performed by this channel
	// the value of 0 indicates the channel has never been upgraded
	UpgradeSequence uint64 `protobuf:"varint,6,opt,name=upgrade_sequence,json=upgradeSequence,proto3" json:"upgrade_sequence,omitempty"`
}

Channel defines pipeline for exactly-once packet delivery between specific modules on separate blockchains, which has at least one end capable of sending packets and one end capable of receiving packets.

func NewChannel

func NewChannel(
	state State, ordering Order, counterparty Counterparty,
	hops []string, version string,
) Channel

NewChannel creates a new Channel instance

func (*Channel) Descriptor

func (*Channel) Descriptor() ([]byte, []int)

func (Channel) GetConnectionHops

func (ch Channel) GetConnectionHops() []string

GetConnectionHops implements Channel interface.

func (Channel) GetCounterparty

func (ch Channel) GetCounterparty() exported.CounterpartyChannelI

GetCounterparty implements Channel interface.

func (Channel) GetOrdering

func (ch Channel) GetOrdering() int32

GetOrdering implements Channel interface.

func (Channel) GetState

func (ch Channel) GetState() int32

GetState implements Channel interface.

func (Channel) GetVersion

func (ch Channel) GetVersion() string

GetVersion implements Channel interface.

func (Channel) IsClosed

func (ch Channel) IsClosed() bool

IsClosed returns true if the channel state is CLOSED

func (Channel) IsOpen

func (ch Channel) IsOpen() bool

IsOpen returns true if the channel state is OPEN

func (*Channel) Marshal

func (m *Channel) Marshal() (dAtA []byte, err error)

func (*Channel) MarshalTo

func (m *Channel) MarshalTo(dAtA []byte) (int, error)

func (*Channel) MarshalToSizedBuffer

func (m *Channel) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*Channel) ProtoMessage

func (*Channel) ProtoMessage()

func (*Channel) Reset

func (m *Channel) Reset()

func (*Channel) Size

func (m *Channel) Size() (n int)

func (*Channel) String

func (m *Channel) String() string

func (*Channel) Unmarshal

func (m *Channel) Unmarshal(dAtA []byte) error

func (Channel) ValidateBasic

func (ch Channel) ValidateBasic() error

ValidateBasic performs a basic validation of the channel fields

func (*Channel) XXX_DiscardUnknown

func (m *Channel) XXX_DiscardUnknown()

func (*Channel) XXX_Marshal

func (m *Channel) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*Channel) XXX_Merge

func (m *Channel) XXX_Merge(src proto.Message)

func (*Channel) XXX_Size

func (m *Channel) XXX_Size() int

func (*Channel) XXX_Unmarshal

func (m *Channel) XXX_Unmarshal(b []byte) error

type ClientKeeper

type ClientKeeper interface {
	GetClientStatus(ctx sdk.Context, clientState exported.ClientState, clientID string) exported.Status
	GetClientState(ctx sdk.Context, clientID string) (exported.ClientState, bool)
	GetClientConsensusState(ctx sdk.Context, clientID string, height exported.Height) (exported.ConsensusState, bool)
	ClientStore(ctx sdk.Context, clientID string) storetypes.KVStore
}

ClientKeeper expected account IBC client keeper

type ConnectionKeeper

type ConnectionKeeper interface {
	GetConnection(ctx sdk.Context, connectionID string) (connectiontypes.ConnectionEnd, bool)
	GetTimestampAtHeight(
		ctx sdk.Context,
		connection connectiontypes.ConnectionEnd,
		height exported.Height,
	) (uint64, error)
	VerifyChannelState(
		ctx sdk.Context,
		connection exported.ConnectionI,
		height exported.Height,
		proof []byte,
		portID,
		channelID string,
		channel exported.ChannelI,
	) error
	VerifyPacketCommitment(
		ctx sdk.Context,
		connection exported.ConnectionI,
		height exported.Height,
		proof []byte,
		portID,
		channelID string,
		sequence uint64,
		commitmentBytes []byte,
	) error
	VerifyPacketAcknowledgement(
		ctx sdk.Context,
		connection exported.ConnectionI,
		height exported.Height,
		proof []byte,
		portID,
		channelID string,
		sequence uint64,
		acknowledgement []byte,
	) error
	VerifyPacketReceiptAbsence(
		ctx sdk.Context,
		connection exported.ConnectionI,
		height exported.Height,
		proof []byte,
		portID,
		channelID string,
		sequence uint64,
	) error
	VerifyNextSequenceRecv(
		ctx sdk.Context,
		connection exported.ConnectionI,
		height exported.Height,
		proof []byte,
		portID,
		channelID string,
		nextSequenceRecv uint64,
	) error
	VerifyChannelUpgrade(
		ctx sdk.Context,
		connection exported.ConnectionI,
		height exported.Height,
		proof []byte,
		portID,
		channelID string,
		upgrade Upgrade,
	) error
	VerifyChannelUpgradeError(
		ctx sdk.Context,
		connection exported.ConnectionI,
		height exported.Height,
		proof []byte,
		portID,
		channelID string,
		errorReceipt ErrorReceipt,
	) error
}

ConnectionKeeper expected account IBC connection keeper

type Counterparty

type Counterparty struct {
	// port on the counterparty chain which owns the other end of the channel.
	PortId string `protobuf:"bytes,1,opt,name=port_id,json=portId,proto3" json:"port_id,omitempty"`
	// channel end on the counterparty chain
	ChannelId string `protobuf:"bytes,2,opt,name=channel_id,json=channelId,proto3" json:"channel_id,omitempty"`
}

Counterparty defines a channel end counterparty

func NewCounterparty

func NewCounterparty(portID, channelID string) Counterparty

NewCounterparty returns a new Counterparty instance

func (*Counterparty) Descriptor

func (*Counterparty) Descriptor() ([]byte, []int)

func (Counterparty) GetChannelID

func (c Counterparty) GetChannelID() string

GetChannelID implements CounterpartyChannelI interface

func (Counterparty) GetPortID

func (c Counterparty) GetPortID() string

GetPortID implements CounterpartyChannelI interface

func (*Counterparty) Marshal

func (m *Counterparty) Marshal() (dAtA []byte, err error)

func (*Counterparty) MarshalTo

func (m *Counterparty) MarshalTo(dAtA []byte) (int, error)

func (*Counterparty) MarshalToSizedBuffer

func (m *Counterparty) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*Counterparty) ProtoMessage

func (*Counterparty) ProtoMessage()

func (*Counterparty) Reset

func (m *Counterparty) Reset()

func (*Counterparty) Size

func (m *Counterparty) Size() (n int)

func (*Counterparty) String

func (m *Counterparty) String() string

func (*Counterparty) Unmarshal

func (m *Counterparty) Unmarshal(dAtA []byte) error

func (Counterparty) ValidateBasic

func (c Counterparty) ValidateBasic() error

ValidateBasic performs a basic validation check of the identifiers

func (*Counterparty) XXX_DiscardUnknown

func (m *Counterparty) XXX_DiscardUnknown()

func (*Counterparty) XXX_Marshal

func (m *Counterparty) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*Counterparty) XXX_Merge

func (m *Counterparty) XXX_Merge(src proto.Message)

func (*Counterparty) XXX_Size

func (m *Counterparty) XXX_Size() int

func (*Counterparty) XXX_Unmarshal

func (m *Counterparty) XXX_Unmarshal(b []byte) error

type ErrorReceipt added in v8.1.0

type ErrorReceipt struct {
	// the channel upgrade sequence
	Sequence uint64 `protobuf:"varint,1,opt,name=sequence,proto3" json:"sequence,omitempty"`
	// the error message detailing the cause of failure
	Message string `protobuf:"bytes,2,opt,name=message,proto3" json:"message,omitempty"`
}

ErrorReceipt defines a type which encapsulates the upgrade sequence and error associated with the upgrade handshake failure. When a channel upgrade handshake is aborted both chains are expected to increment to the next sequence.

func (*ErrorReceipt) Descriptor added in v8.1.0

func (*ErrorReceipt) Descriptor() ([]byte, []int)

func (*ErrorReceipt) Marshal added in v8.1.0

func (m *ErrorReceipt) Marshal() (dAtA []byte, err error)

func (*ErrorReceipt) MarshalTo added in v8.1.0

func (m *ErrorReceipt) MarshalTo(dAtA []byte) (int, error)

func (*ErrorReceipt) MarshalToSizedBuffer added in v8.1.0

func (m *ErrorReceipt) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*ErrorReceipt) ProtoMessage added in v8.1.0

func (*ErrorReceipt) ProtoMessage()

func (*ErrorReceipt) Reset added in v8.1.0

func (m *ErrorReceipt) Reset()

func (*ErrorReceipt) Size added in v8.1.0

func (m *ErrorReceipt) Size() (n int)

func (*ErrorReceipt) String added in v8.1.0

func (m *ErrorReceipt) String() string

func (*ErrorReceipt) Unmarshal added in v8.1.0

func (m *ErrorReceipt) Unmarshal(dAtA []byte) error

func (*ErrorReceipt) XXX_DiscardUnknown added in v8.1.0

func (m *ErrorReceipt) XXX_DiscardUnknown()

func (*ErrorReceipt) XXX_Marshal added in v8.1.0

func (m *ErrorReceipt) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*ErrorReceipt) XXX_Merge added in v8.1.0

func (m *ErrorReceipt) XXX_Merge(src proto.Message)

func (*ErrorReceipt) XXX_Size added in v8.1.0

func (m *ErrorReceipt) XXX_Size() int

func (*ErrorReceipt) XXX_Unmarshal added in v8.1.0

func (m *ErrorReceipt) XXX_Unmarshal(b []byte) error

type GenesisState

type GenesisState struct {
	Channels         []IdentifiedChannel `protobuf:"bytes,1,rep,name=channels,proto3,casttype=IdentifiedChannel" json:"channels"`
	Acknowledgements []PacketState       `protobuf:"bytes,2,rep,name=acknowledgements,proto3" json:"acknowledgements"`
	Commitments      []PacketState       `protobuf:"bytes,3,rep,name=commitments,proto3" json:"commitments"`
	Receipts         []PacketState       `protobuf:"bytes,4,rep,name=receipts,proto3" json:"receipts"`
	SendSequences    []PacketSequence    `protobuf:"bytes,5,rep,name=send_sequences,json=sendSequences,proto3" json:"send_sequences"`
	RecvSequences    []PacketSequence    `protobuf:"bytes,6,rep,name=recv_sequences,json=recvSequences,proto3" json:"recv_sequences"`
	AckSequences     []PacketSequence    `protobuf:"bytes,7,rep,name=ack_sequences,json=ackSequences,proto3" json:"ack_sequences"`
	// the sequence for the next generated channel identifier
	NextChannelSequence uint64 `protobuf:"varint,8,opt,name=next_channel_sequence,json=nextChannelSequence,proto3" json:"next_channel_sequence,omitempty"`
	Params              Params `protobuf:"bytes,9,opt,name=params,proto3" json:"params"`
}

GenesisState defines the ibc channel submodule's genesis state.

func DefaultGenesisState

func DefaultGenesisState() GenesisState

DefaultGenesisState returns the ibc channel submodule's default genesis state.

func NewGenesisState

func NewGenesisState(
	channels []IdentifiedChannel, acks, receipts, commitments []PacketState,
	sendSeqs, recvSeqs, ackSeqs []PacketSequence, nextChannelSequence uint64,
) GenesisState

NewGenesisState creates a GenesisState instance. It uses the default params. Breakage in v9.0.0 will allow the params to be provided. Please use NewGenesisStateWithParams in this version if you want to provide custom params.

func NewGenesisStateWithParams added in v8.1.0

func NewGenesisStateWithParams(
	channels []IdentifiedChannel, acks, receipts, commitments []PacketState,
	sendSeqs, recvSeqs, ackSeqs []PacketSequence, nextChannelSequence uint64,
	params Params,
) GenesisState

NewGenesisStateWithParams creates a GenesisState instance.

func (*GenesisState) Descriptor

func (*GenesisState) Descriptor() ([]byte, []int)

func (*GenesisState) GetAckSequences

func (m *GenesisState) GetAckSequences() []PacketSequence

func (*GenesisState) GetAcknowledgements

func (m *GenesisState) GetAcknowledgements() []PacketState

func (*GenesisState) GetChannels

func (m *GenesisState) GetChannels() []IdentifiedChannel

func (*GenesisState) GetCommitments

func (m *GenesisState) GetCommitments() []PacketState

func (*GenesisState) GetNextChannelSequence

func (m *GenesisState) GetNextChannelSequence() uint64

func (*GenesisState) GetParams added in v8.1.0

func (m *GenesisState) GetParams() Params

func (*GenesisState) GetReceipts

func (m *GenesisState) GetReceipts() []PacketState

func (*GenesisState) GetRecvSequences

func (m *GenesisState) GetRecvSequences() []PacketSequence

func (*GenesisState) GetSendSequences

func (m *GenesisState) GetSendSequences() []PacketSequence

func (*GenesisState) Marshal

func (m *GenesisState) Marshal() (dAtA []byte, err error)

func (*GenesisState) MarshalTo

func (m *GenesisState) MarshalTo(dAtA []byte) (int, error)

func (*GenesisState) MarshalToSizedBuffer

func (m *GenesisState) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*GenesisState) ProtoMessage

func (*GenesisState) ProtoMessage()

func (*GenesisState) Reset

func (m *GenesisState) Reset()

func (*GenesisState) Size

func (m *GenesisState) Size() (n int)

func (*GenesisState) String

func (m *GenesisState) String() string

func (*GenesisState) Unmarshal

func (m *GenesisState) Unmarshal(dAtA []byte) error

func (GenesisState) Validate

func (gs GenesisState) Validate() error

Validate performs basic genesis state validation returning an error upon any failure.

func (*GenesisState) XXX_DiscardUnknown

func (m *GenesisState) XXX_DiscardUnknown()

func (*GenesisState) XXX_Marshal

func (m *GenesisState) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*GenesisState) XXX_Merge

func (m *GenesisState) XXX_Merge(src proto.Message)

func (*GenesisState) XXX_Size

func (m *GenesisState) XXX_Size() int

func (*GenesisState) XXX_Unmarshal

func (m *GenesisState) XXX_Unmarshal(b []byte) error

type IdentifiedChannel

type IdentifiedChannel struct {
	// current state of the channel end
	State State `protobuf:"varint,1,opt,name=state,proto3,enum=ibc.core.channel.v1.State" json:"state,omitempty"`
	// whether the channel is ordered or unordered
	Ordering Order `protobuf:"varint,2,opt,name=ordering,proto3,enum=ibc.core.channel.v1.Order" json:"ordering,omitempty"`
	// counterparty channel end
	Counterparty Counterparty `protobuf:"bytes,3,opt,name=counterparty,proto3" json:"counterparty"`
	// list of connection identifiers, in order, along which packets sent on
	// this channel will travel
	ConnectionHops []string `protobuf:"bytes,4,rep,name=connection_hops,json=connectionHops,proto3" json:"connection_hops,omitempty"`
	// opaque channel version, which is agreed upon during the handshake
	Version string `protobuf:"bytes,5,opt,name=version,proto3" json:"version,omitempty"`
	// port identifier
	PortId string `protobuf:"bytes,6,opt,name=port_id,json=portId,proto3" json:"port_id,omitempty"`
	// channel identifier
	ChannelId string `protobuf:"bytes,7,opt,name=channel_id,json=channelId,proto3" json:"channel_id,omitempty"`
	// upgrade sequence indicates the latest upgrade attempt performed by this channel
	// the value of 0 indicates the channel has never been upgraded
	UpgradeSequence uint64 `protobuf:"varint,8,opt,name=upgrade_sequence,json=upgradeSequence,proto3" json:"upgrade_sequence,omitempty"`
}

IdentifiedChannel defines a channel with additional port and channel identifier fields.

func NewIdentifiedChannel

func NewIdentifiedChannel(portID, channelID string, ch Channel) IdentifiedChannel

NewIdentifiedChannel creates a new IdentifiedChannel instance

func (*IdentifiedChannel) Descriptor

func (*IdentifiedChannel) Descriptor() ([]byte, []int)

func (*IdentifiedChannel) Marshal

func (m *IdentifiedChannel) Marshal() (dAtA []byte, err error)

func (*IdentifiedChannel) MarshalTo

func (m *IdentifiedChannel) MarshalTo(dAtA []byte) (int, error)

func (*IdentifiedChannel) MarshalToSizedBuffer

func (m *IdentifiedChannel) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*IdentifiedChannel) ProtoMessage

func (*IdentifiedChannel) ProtoMessage()

func (*IdentifiedChannel) Reset

func (m *IdentifiedChannel) Reset()

func (*IdentifiedChannel) Size

func (m *IdentifiedChannel) Size() (n int)

func (*IdentifiedChannel) String

func (m *IdentifiedChannel) String() string

func (*IdentifiedChannel) Unmarshal

func (m *IdentifiedChannel) Unmarshal(dAtA []byte) error

func (IdentifiedChannel) ValidateBasic

func (ic IdentifiedChannel) ValidateBasic() error

ValidateBasic performs a basic validation of the identifiers and channel fields.

func (*IdentifiedChannel) XXX_DiscardUnknown

func (m *IdentifiedChannel) XXX_DiscardUnknown()

func (*IdentifiedChannel) XXX_Marshal

func (m *IdentifiedChannel) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*IdentifiedChannel) XXX_Merge

func (m *IdentifiedChannel) XXX_Merge(src proto.Message)

func (*IdentifiedChannel) XXX_Size

func (m *IdentifiedChannel) XXX_Size() int

func (*IdentifiedChannel) XXX_Unmarshal

func (m *IdentifiedChannel) XXX_Unmarshal(b []byte) error

type MsgAcknowledgement

type MsgAcknowledgement struct {
	Packet          Packet       `protobuf:"bytes,1,opt,name=packet,proto3" json:"packet"`
	Acknowledgement []byte       `protobuf:"bytes,2,opt,name=acknowledgement,proto3" json:"acknowledgement,omitempty"`
	ProofAcked      []byte       `protobuf:"bytes,3,opt,name=proof_acked,json=proofAcked,proto3" json:"proof_acked,omitempty"`
	ProofHeight     types.Height `protobuf:"bytes,4,opt,name=proof_height,json=proofHeight,proto3" json:"proof_height"`
	Signer          string       `protobuf:"bytes,5,opt,name=signer,proto3" json:"signer,omitempty"`
}

MsgAcknowledgement receives incoming IBC acknowledgement

func NewMsgAcknowledgement

func NewMsgAcknowledgement(
	packet Packet,
	ack, ackedProof []byte,
	proofHeight clienttypes.Height,
	signer string,
) *MsgAcknowledgement

NewMsgAcknowledgement constructs a new MsgAcknowledgement

func (*MsgAcknowledgement) Descriptor

func (*MsgAcknowledgement) Descriptor() ([]byte, []int)

func (MsgAcknowledgement) GetSigners

func (msg MsgAcknowledgement) GetSigners() []sdk.AccAddress

GetSigners implements sdk.Msg

func (*MsgAcknowledgement) Marshal

func (m *MsgAcknowledgement) Marshal() (dAtA []byte, err error)

func (*MsgAcknowledgement) MarshalTo

func (m *MsgAcknowledgement) MarshalTo(dAtA []byte) (int, error)

func (*MsgAcknowledgement) MarshalToSizedBuffer

func (m *MsgAcknowledgement) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*MsgAcknowledgement) ProtoMessage

func (*MsgAcknowledgement) ProtoMessage()

func (*MsgAcknowledgement) Reset

func (m *MsgAcknowledgement) Reset()

func (*MsgAcknowledgement) Size

func (m *MsgAcknowledgement) Size() (n int)

func (*MsgAcknowledgement) String

func (m *MsgAcknowledgement) String() string

func (*MsgAcknowledgement) Unmarshal

func (m *MsgAcknowledgement) Unmarshal(dAtA []byte) error

func (MsgAcknowledgement) ValidateBasic

func (msg MsgAcknowledgement) ValidateBasic() error

ValidateBasic implements sdk.Msg

func (*MsgAcknowledgement) XXX_DiscardUnknown

func (m *MsgAcknowledgement) XXX_DiscardUnknown()

func (*MsgAcknowledgement) XXX_Marshal

func (m *MsgAcknowledgement) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*MsgAcknowledgement) XXX_Merge

func (m *MsgAcknowledgement) XXX_Merge(src proto.Message)

func (*MsgAcknowledgement) XXX_Size

func (m *MsgAcknowledgement) XXX_Size() int

func (*MsgAcknowledgement) XXX_Unmarshal

func (m *MsgAcknowledgement) XXX_Unmarshal(b []byte) error

type MsgAcknowledgementResponse

type MsgAcknowledgementResponse struct {
	Result ResponseResultType `protobuf:"varint,1,opt,name=result,proto3,enum=ibc.core.channel.v1.ResponseResultType" json:"result,omitempty"`
}

MsgAcknowledgementResponse defines the Msg/Acknowledgement response type.

func (*MsgAcknowledgementResponse) Descriptor

func (*MsgAcknowledgementResponse) Descriptor() ([]byte, []int)

func (*MsgAcknowledgementResponse) Marshal

func (m *MsgAcknowledgementResponse) Marshal() (dAtA []byte, err error)

func (*MsgAcknowledgementResponse) MarshalTo

func (m *MsgAcknowledgementResponse) MarshalTo(dAtA []byte) (int, error)

func (*MsgAcknowledgementResponse) MarshalToSizedBuffer

func (m *MsgAcknowledgementResponse) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*MsgAcknowledgementResponse) ProtoMessage

func (*MsgAcknowledgementResponse) ProtoMessage()

func (*MsgAcknowledgementResponse) Reset

func (m *MsgAcknowledgementResponse) Reset()

func (*MsgAcknowledgementResponse) Size

func (m *MsgAcknowledgementResponse) Size() (n int)

func (*MsgAcknowledgementResponse) String

func (m *MsgAcknowledgementResponse) String() string

func (*MsgAcknowledgementResponse) Unmarshal

func (m *MsgAcknowledgementResponse) Unmarshal(dAtA []byte) error

func (*MsgAcknowledgementResponse) XXX_DiscardUnknown

func (m *MsgAcknowledgementResponse) XXX_DiscardUnknown()

func (*MsgAcknowledgementResponse) XXX_Marshal

func (m *MsgAcknowledgementResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*MsgAcknowledgementResponse) XXX_Merge

func (m *MsgAcknowledgementResponse) XXX_Merge(src proto.Message)

func (*MsgAcknowledgementResponse) XXX_Size

func (m *MsgAcknowledgementResponse) XXX_Size() int

func (*MsgAcknowledgementResponse) XXX_Unmarshal

func (m *MsgAcknowledgementResponse) XXX_Unmarshal(b []byte) error

type MsgChannelCloseConfirm

type MsgChannelCloseConfirm struct {
	PortId                      string       `protobuf:"bytes,1,opt,name=port_id,json=portId,proto3" json:"port_id,omitempty"`
	ChannelId                   string       `protobuf:"bytes,2,opt,name=channel_id,json=channelId,proto3" json:"channel_id,omitempty"`
	ProofInit                   []byte       `protobuf:"bytes,3,opt,name=proof_init,json=proofInit,proto3" json:"proof_init,omitempty"`
	ProofHeight                 types.Height `protobuf:"bytes,4,opt,name=proof_height,json=proofHeight,proto3" json:"proof_height"`
	Signer                      string       `protobuf:"bytes,5,opt,name=signer,proto3" json:"signer,omitempty"`
	CounterpartyUpgradeSequence uint64       `` /* 145-byte string literal not displayed */
}

MsgChannelCloseConfirm defines a msg sent by a Relayer to Chain B to acknowledge the change of channel state to CLOSED on Chain A.

func NewMsgChannelCloseConfirm

func NewMsgChannelCloseConfirm(
	portID, channelID string, initProof []byte, proofHeight clienttypes.Height,
	signer string,
) *MsgChannelCloseConfirm

NewMsgChannelCloseConfirm creates a new MsgChannelCloseConfirm instance Breakage in v9.0.0 will allow for the counterparty upgrade sequence to be provided. Please use NewMsgChannelCloseConfirmWithCounterpartyUpgradeSequence to provide the counterparty upgrade sequence in this version.

func NewMsgChannelCloseConfirmWithCounterpartyUpgradeSequence added in v8.1.0

func NewMsgChannelCloseConfirmWithCounterpartyUpgradeSequence(
	portID, channelID string, initProof []byte, proofHeight clienttypes.Height,
	signer string, counterpartyUpgradeSequence uint64,
) *MsgChannelCloseConfirm

NewMsgChannelCloseConfirmWithCounterpartyUpgradeSequence creates a new MsgChannelCloseConfirm instance with a non-zero counterparty upgrade sequence.

func (*MsgChannelCloseConfirm) Descriptor

func (*MsgChannelCloseConfirm) Descriptor() ([]byte, []int)

func (MsgChannelCloseConfirm) GetSigners

func (msg MsgChannelCloseConfirm) GetSigners() []sdk.AccAddress

GetSigners implements sdk.Msg

func (*MsgChannelCloseConfirm) Marshal

func (m *MsgChannelCloseConfirm) Marshal() (dAtA []byte, err error)

func (*MsgChannelCloseConfirm) MarshalTo

func (m *MsgChannelCloseConfirm) MarshalTo(dAtA []byte) (int, error)

func (*MsgChannelCloseConfirm) MarshalToSizedBuffer

func (m *MsgChannelCloseConfirm) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*MsgChannelCloseConfirm) ProtoMessage

func (*MsgChannelCloseConfirm) ProtoMessage()

func (*MsgChannelCloseConfirm) Reset

func (m *MsgChannelCloseConfirm) Reset()

func (*MsgChannelCloseConfirm) Size

func (m *MsgChannelCloseConfirm) Size() (n int)

func (*MsgChannelCloseConfirm) String

func (m *MsgChannelCloseConfirm) String() string

func (*MsgChannelCloseConfirm) Unmarshal

func (m *MsgChannelCloseConfirm) Unmarshal(dAtA []byte) error

func (MsgChannelCloseConfirm) ValidateBasic

func (msg MsgChannelCloseConfirm) ValidateBasic() error

ValidateBasic implements sdk.Msg

func (*MsgChannelCloseConfirm) XXX_DiscardUnknown

func (m *MsgChannelCloseConfirm) XXX_DiscardUnknown()

func (*MsgChannelCloseConfirm) XXX_Marshal

func (m *MsgChannelCloseConfirm) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*MsgChannelCloseConfirm) XXX_Merge

func (m *MsgChannelCloseConfirm) XXX_Merge(src proto.Message)

func (*MsgChannelCloseConfirm) XXX_Size

func (m *MsgChannelCloseConfirm) XXX_Size() int

func (*MsgChannelCloseConfirm) XXX_Unmarshal

func (m *MsgChannelCloseConfirm) XXX_Unmarshal(b []byte) error

type MsgChannelCloseConfirmResponse

type MsgChannelCloseConfirmResponse struct {
}

MsgChannelCloseConfirmResponse defines the Msg/ChannelCloseConfirm response type.

func (*MsgChannelCloseConfirmResponse) Descriptor

func (*MsgChannelCloseConfirmResponse) Descriptor() ([]byte, []int)

func (*MsgChannelCloseConfirmResponse) Marshal

func (m *MsgChannelCloseConfirmResponse) Marshal() (dAtA []byte, err error)

func (*MsgChannelCloseConfirmResponse) MarshalTo

func (m *MsgChannelCloseConfirmResponse) MarshalTo(dAtA []byte) (int, error)

func (*MsgChannelCloseConfirmResponse) MarshalToSizedBuffer

func (m *MsgChannelCloseConfirmResponse) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*MsgChannelCloseConfirmResponse) ProtoMessage

func (*MsgChannelCloseConfirmResponse) ProtoMessage()

func (*MsgChannelCloseConfirmResponse) Reset

func (m *MsgChannelCloseConfirmResponse) Reset()

func (*MsgChannelCloseConfirmResponse) Size

func (m *MsgChannelCloseConfirmResponse) Size() (n int)

func (*MsgChannelCloseConfirmResponse) String

func (*MsgChannelCloseConfirmResponse) Unmarshal

func (m *MsgChannelCloseConfirmResponse) Unmarshal(dAtA []byte) error

func (*MsgChannelCloseConfirmResponse) XXX_DiscardUnknown

func (m *MsgChannelCloseConfirmResponse) XXX_DiscardUnknown()

func (*MsgChannelCloseConfirmResponse) XXX_Marshal

func (m *MsgChannelCloseConfirmResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*MsgChannelCloseConfirmResponse) XXX_Merge

func (m *MsgChannelCloseConfirmResponse) XXX_Merge(src proto.Message)

func (*MsgChannelCloseConfirmResponse) XXX_Size

func (m *MsgChannelCloseConfirmResponse) XXX_Size() int

func (*MsgChannelCloseConfirmResponse) XXX_Unmarshal

func (m *MsgChannelCloseConfirmResponse) XXX_Unmarshal(b []byte) error

type MsgChannelCloseInit

type MsgChannelCloseInit struct {
	PortId    string `protobuf:"bytes,1,opt,name=port_id,json=portId,proto3" json:"port_id,omitempty"`
	ChannelId string `protobuf:"bytes,2,opt,name=channel_id,json=channelId,proto3" json:"channel_id,omitempty"`
	Signer    string `protobuf:"bytes,3,opt,name=signer,proto3" json:"signer,omitempty"`
}

MsgChannelCloseInit defines a msg sent by a Relayer to Chain A to close a channel with Chain B.

func NewMsgChannelCloseInit

func NewMsgChannelCloseInit(
	portID string, channelID string, signer string,
) *MsgChannelCloseInit

NewMsgChannelCloseInit creates a new MsgChannelCloseInit instance

func (*MsgChannelCloseInit) Descriptor

func (*MsgChannelCloseInit) Descriptor() ([]byte, []int)

func (MsgChannelCloseInit) GetSigners

func (msg MsgChannelCloseInit) GetSigners() []sdk.AccAddress

GetSigners implements sdk.Msg

func (*MsgChannelCloseInit) Marshal

func (m *MsgChannelCloseInit) Marshal() (dAtA []byte, err error)

func (*MsgChannelCloseInit) MarshalTo

func (m *MsgChannelCloseInit) MarshalTo(dAtA []byte) (int, error)

func (*MsgChannelCloseInit) MarshalToSizedBuffer

func (m *MsgChannelCloseInit) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*MsgChannelCloseInit) ProtoMessage

func (*MsgChannelCloseInit) ProtoMessage()

func (*MsgChannelCloseInit) Reset

func (m *MsgChannelCloseInit) Reset()

func (*MsgChannelCloseInit) Size

func (m *MsgChannelCloseInit) Size() (n int)

func (*MsgChannelCloseInit) String

func (m *MsgChannelCloseInit) String() string

func (*MsgChannelCloseInit) Unmarshal

func (m *MsgChannelCloseInit) Unmarshal(dAtA []byte) error

func (MsgChannelCloseInit) ValidateBasic

func (msg MsgChannelCloseInit) ValidateBasic() error

ValidateBasic implements sdk.Msg

func (*MsgChannelCloseInit) XXX_DiscardUnknown

func (m *MsgChannelCloseInit) XXX_DiscardUnknown()

func (*MsgChannelCloseInit) XXX_Marshal

func (m *MsgChannelCloseInit) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*MsgChannelCloseInit) XXX_Merge

func (m *MsgChannelCloseInit) XXX_Merge(src proto.Message)

func (*MsgChannelCloseInit) XXX_Size

func (m *MsgChannelCloseInit) XXX_Size() int

func (*MsgChannelCloseInit) XXX_Unmarshal

func (m *MsgChannelCloseInit) XXX_Unmarshal(b []byte) error

type MsgChannelCloseInitResponse

type MsgChannelCloseInitResponse struct {
}

MsgChannelCloseInitResponse defines the Msg/ChannelCloseInit response type.

func (*MsgChannelCloseInitResponse) Descriptor

func (*MsgChannelCloseInitResponse) Descriptor() ([]byte, []int)

func (*MsgChannelCloseInitResponse) Marshal

func (m *MsgChannelCloseInitResponse) Marshal() (dAtA []byte, err error)

func (*MsgChannelCloseInitResponse) MarshalTo

func (m *MsgChannelCloseInitResponse) MarshalTo(dAtA []byte) (int, error)

func (*MsgChannelCloseInitResponse) MarshalToSizedBuffer

func (m *MsgChannelCloseInitResponse) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*MsgChannelCloseInitResponse) ProtoMessage

func (*MsgChannelCloseInitResponse) ProtoMessage()

func (*MsgChannelCloseInitResponse) Reset

func (m *MsgChannelCloseInitResponse) Reset()

func (*MsgChannelCloseInitResponse) Size

func (m *MsgChannelCloseInitResponse) Size() (n int)

func (*MsgChannelCloseInitResponse) String

func (m *MsgChannelCloseInitResponse) String() string

func (*MsgChannelCloseInitResponse) Unmarshal

func (m *MsgChannelCloseInitResponse) Unmarshal(dAtA []byte) error

func (*MsgChannelCloseInitResponse) XXX_DiscardUnknown

func (m *MsgChannelCloseInitResponse) XXX_DiscardUnknown()

func (*MsgChannelCloseInitResponse) XXX_Marshal

func (m *MsgChannelCloseInitResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*MsgChannelCloseInitResponse) XXX_Merge

func (m *MsgChannelCloseInitResponse) XXX_Merge(src proto.Message)

func (*MsgChannelCloseInitResponse) XXX_Size

func (m *MsgChannelCloseInitResponse) XXX_Size() int

func (*MsgChannelCloseInitResponse) XXX_Unmarshal

func (m *MsgChannelCloseInitResponse) XXX_Unmarshal(b []byte) error

type MsgChannelOpenAck

type MsgChannelOpenAck struct {
	PortId                string       `protobuf:"bytes,1,opt,name=port_id,json=portId,proto3" json:"port_id,omitempty"`
	ChannelId             string       `protobuf:"bytes,2,opt,name=channel_id,json=channelId,proto3" json:"channel_id,omitempty"`
	CounterpartyChannelId string       `` /* 126-byte string literal not displayed */
	CounterpartyVersion   string       `protobuf:"bytes,4,opt,name=counterparty_version,json=counterpartyVersion,proto3" json:"counterparty_version,omitempty"`
	ProofTry              []byte       `protobuf:"bytes,5,opt,name=proof_try,json=proofTry,proto3" json:"proof_try,omitempty"`
	ProofHeight           types.Height `protobuf:"bytes,6,opt,name=proof_height,json=proofHeight,proto3" json:"proof_height"`
	Signer                string       `protobuf:"bytes,7,opt,name=signer,proto3" json:"signer,omitempty"`
}

MsgChannelOpenAck defines a msg sent by a Relayer to Chain A to acknowledge the change of channel state to TRYOPEN on Chain B. WARNING: a channel upgrade MUST NOT initialize an upgrade for this channel in the same block as executing this message otherwise the counterparty will be incapable of opening.

func NewMsgChannelOpenAck

func NewMsgChannelOpenAck(
	portID, channelID, counterpartyChannelID string, cpv string, tryProof []byte, proofHeight clienttypes.Height,
	signer string,
) *MsgChannelOpenAck

NewMsgChannelOpenAck creates a new MsgChannelOpenAck instance

func (*MsgChannelOpenAck) Descriptor

func (*MsgChannelOpenAck) Descriptor() ([]byte, []int)

func (MsgChannelOpenAck) GetSigners

func (msg MsgChannelOpenAck) GetSigners() []sdk.AccAddress

GetSigners implements sdk.Msg

func (*MsgChannelOpenAck) Marshal

func (m *MsgChannelOpenAck) Marshal() (dAtA []byte, err error)

func (*MsgChannelOpenAck) MarshalTo

func (m *MsgChannelOpenAck) MarshalTo(dAtA []byte) (int, error)

func (*MsgChannelOpenAck) MarshalToSizedBuffer

func (m *MsgChannelOpenAck) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*MsgChannelOpenAck) ProtoMessage

func (*MsgChannelOpenAck) ProtoMessage()

func (*MsgChannelOpenAck) Reset

func (m *MsgChannelOpenAck) Reset()

func (*MsgChannelOpenAck) Size

func (m *MsgChannelOpenAck) Size() (n int)

func (*MsgChannelOpenAck) String

func (m *MsgChannelOpenAck) String() string

func (*MsgChannelOpenAck) Unmarshal

func (m *MsgChannelOpenAck) Unmarshal(dAtA []byte) error

func (MsgChannelOpenAck) ValidateBasic

func (msg MsgChannelOpenAck) ValidateBasic() error

ValidateBasic implements sdk.Msg

func (*MsgChannelOpenAck) XXX_DiscardUnknown

func (m *MsgChannelOpenAck) XXX_DiscardUnknown()

func (*MsgChannelOpenAck) XXX_Marshal

func (m *MsgChannelOpenAck) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*MsgChannelOpenAck) XXX_Merge

func (m *MsgChannelOpenAck) XXX_Merge(src proto.Message)

func (*MsgChannelOpenAck) XXX_Size

func (m *MsgChannelOpenAck) XXX_Size() int

func (*MsgChannelOpenAck) XXX_Unmarshal

func (m *MsgChannelOpenAck) XXX_Unmarshal(b []byte) error

type MsgChannelOpenAckResponse

type MsgChannelOpenAckResponse struct {
}

MsgChannelOpenAckResponse defines the Msg/ChannelOpenAck response type.

func (*MsgChannelOpenAckResponse) Descriptor

func (*MsgChannelOpenAckResponse) Descriptor() ([]byte, []int)

func (*MsgChannelOpenAckResponse) Marshal

func (m *MsgChannelOpenAckResponse) Marshal() (dAtA []byte, err error)

func (*MsgChannelOpenAckResponse) MarshalTo

func (m *MsgChannelOpenAckResponse) MarshalTo(dAtA []byte) (int, error)

func (*MsgChannelOpenAckResponse) MarshalToSizedBuffer

func (m *MsgChannelOpenAckResponse) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*MsgChannelOpenAckResponse) ProtoMessage

func (*MsgChannelOpenAckResponse) ProtoMessage()

func (*MsgChannelOpenAckResponse) Reset

func (m *MsgChannelOpenAckResponse) Reset()

func (*MsgChannelOpenAckResponse) Size

func (m *MsgChannelOpenAckResponse) Size() (n int)

func (*MsgChannelOpenAckResponse) String

func (m *MsgChannelOpenAckResponse) String() string

func (*MsgChannelOpenAckResponse) Unmarshal

func (m *MsgChannelOpenAckResponse) Unmarshal(dAtA []byte) error

func (*MsgChannelOpenAckResponse) XXX_DiscardUnknown

func (m *MsgChannelOpenAckResponse) XXX_DiscardUnknown()

func (*MsgChannelOpenAckResponse) XXX_Marshal

func (m *MsgChannelOpenAckResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*MsgChannelOpenAckResponse) XXX_Merge

func (m *MsgChannelOpenAckResponse) XXX_Merge(src proto.Message)

func (*MsgChannelOpenAckResponse) XXX_Size

func (m *MsgChannelOpenAckResponse) XXX_Size() int

func (*MsgChannelOpenAckResponse) XXX_Unmarshal

func (m *MsgChannelOpenAckResponse) XXX_Unmarshal(b []byte) error

type MsgChannelOpenConfirm

type MsgChannelOpenConfirm struct {
	PortId      string       `protobuf:"bytes,1,opt,name=port_id,json=portId,proto3" json:"port_id,omitempty"`
	ChannelId   string       `protobuf:"bytes,2,opt,name=channel_id,json=channelId,proto3" json:"channel_id,omitempty"`
	ProofAck    []byte       `protobuf:"bytes,3,opt,name=proof_ack,json=proofAck,proto3" json:"proof_ack,omitempty"`
	ProofHeight types.Height `protobuf:"bytes,4,opt,name=proof_height,json=proofHeight,proto3" json:"proof_height"`
	Signer      string       `protobuf:"bytes,5,opt,name=signer,proto3" json:"signer,omitempty"`
}

MsgChannelOpenConfirm defines a msg sent by a Relayer to Chain B to acknowledge the change of channel state to OPEN on Chain A.

func NewMsgChannelOpenConfirm

func NewMsgChannelOpenConfirm(
	portID, channelID string, ackProof []byte, proofHeight clienttypes.Height,
	signer string,
) *MsgChannelOpenConfirm

NewMsgChannelOpenConfirm creates a new MsgChannelOpenConfirm instance

func (*MsgChannelOpenConfirm) Descriptor

func (*MsgChannelOpenConfirm) Descriptor() ([]byte, []int)

func (MsgChannelOpenConfirm) GetSigners

func (msg MsgChannelOpenConfirm) GetSigners() []sdk.AccAddress

GetSigners implements sdk.Msg

func (*MsgChannelOpenConfirm) Marshal

func (m *MsgChannelOpenConfirm) Marshal() (dAtA []byte, err error)

func (*MsgChannelOpenConfirm) MarshalTo

func (m *MsgChannelOpenConfirm) MarshalTo(dAtA []byte) (int, error)

func (*MsgChannelOpenConfirm) MarshalToSizedBuffer

func (m *MsgChannelOpenConfirm) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*MsgChannelOpenConfirm) ProtoMessage

func (*MsgChannelOpenConfirm) ProtoMessage()

func (*MsgChannelOpenConfirm) Reset

func (m *MsgChannelOpenConfirm) Reset()

func (*MsgChannelOpenConfirm) Size

func (m *MsgChannelOpenConfirm) Size() (n int)

func (*MsgChannelOpenConfirm) String

func (m *MsgChannelOpenConfirm) String() string

func (*MsgChannelOpenConfirm) Unmarshal

func (m *MsgChannelOpenConfirm) Unmarshal(dAtA []byte) error

func (MsgChannelOpenConfirm) ValidateBasic

func (msg MsgChannelOpenConfirm) ValidateBasic() error

ValidateBasic implements sdk.Msg

func (*MsgChannelOpenConfirm) XXX_DiscardUnknown

func (m *MsgChannelOpenConfirm) XXX_DiscardUnknown()

func (*MsgChannelOpenConfirm) XXX_Marshal

func (m *MsgChannelOpenConfirm) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*MsgChannelOpenConfirm) XXX_Merge

func (m *MsgChannelOpenConfirm) XXX_Merge(src proto.Message)

func (*MsgChannelOpenConfirm) XXX_Size

func (m *MsgChannelOpenConfirm) XXX_Size() int

func (*MsgChannelOpenConfirm) XXX_Unmarshal

func (m *MsgChannelOpenConfirm) XXX_Unmarshal(b []byte) error

type MsgChannelOpenConfirmResponse

type MsgChannelOpenConfirmResponse struct {
}

MsgChannelOpenConfirmResponse defines the Msg/ChannelOpenConfirm response type.

func (*MsgChannelOpenConfirmResponse) Descriptor

func (*MsgChannelOpenConfirmResponse) Descriptor() ([]byte, []int)

func (*MsgChannelOpenConfirmResponse) Marshal

func (m *MsgChannelOpenConfirmResponse) Marshal() (dAtA []byte, err error)

func (*MsgChannelOpenConfirmResponse) MarshalTo

func (m *MsgChannelOpenConfirmResponse) MarshalTo(dAtA []byte) (int, error)

func (*MsgChannelOpenConfirmResponse) MarshalToSizedBuffer

func (m *MsgChannelOpenConfirmResponse) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*MsgChannelOpenConfirmResponse) ProtoMessage

func (*MsgChannelOpenConfirmResponse) ProtoMessage()

func (*MsgChannelOpenConfirmResponse) Reset

func (m *MsgChannelOpenConfirmResponse) Reset()

func (*MsgChannelOpenConfirmResponse) Size

func (m *MsgChannelOpenConfirmResponse) Size() (n int)

func (*MsgChannelOpenConfirmResponse) String

func (*MsgChannelOpenConfirmResponse) Unmarshal

func (m *MsgChannelOpenConfirmResponse) Unmarshal(dAtA []byte) error

func (*MsgChannelOpenConfirmResponse) XXX_DiscardUnknown

func (m *MsgChannelOpenConfirmResponse) XXX_DiscardUnknown()

func (*MsgChannelOpenConfirmResponse) XXX_Marshal

func (m *MsgChannelOpenConfirmResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*MsgChannelOpenConfirmResponse) XXX_Merge

func (m *MsgChannelOpenConfirmResponse) XXX_Merge(src proto.Message)

func (*MsgChannelOpenConfirmResponse) XXX_Size

func (m *MsgChannelOpenConfirmResponse) XXX_Size() int

func (*MsgChannelOpenConfirmResponse) XXX_Unmarshal

func (m *MsgChannelOpenConfirmResponse) XXX_Unmarshal(b []byte) error

type MsgChannelOpenInit

type MsgChannelOpenInit struct {
	PortId  string  `protobuf:"bytes,1,opt,name=port_id,json=portId,proto3" json:"port_id,omitempty"`
	Channel Channel `protobuf:"bytes,2,opt,name=channel,proto3" json:"channel"`
	Signer  string  `protobuf:"bytes,3,opt,name=signer,proto3" json:"signer,omitempty"`
}

MsgChannelOpenInit defines an sdk.Msg to initialize a channel handshake. It is called by a relayer on Chain A.

func NewMsgChannelOpenInit

func NewMsgChannelOpenInit(
	portID, version string, channelOrder Order, connectionHops []string,
	counterpartyPortID string, signer string,
) *MsgChannelOpenInit

NewMsgChannelOpenInit creates a new MsgChannelOpenInit. It sets the counterparty channel identifier to be empty.

func (*MsgChannelOpenInit) Descriptor

func (*MsgChannelOpenInit) Descriptor() ([]byte, []int)

func (MsgChannelOpenInit) GetSigners

func (msg MsgChannelOpenInit) GetSigners() []sdk.AccAddress

GetSigners implements sdk.Msg

func (*MsgChannelOpenInit) Marshal

func (m *MsgChannelOpenInit) Marshal() (dAtA []byte, err error)

func (*MsgChannelOpenInit) MarshalTo

func (m *MsgChannelOpenInit) MarshalTo(dAtA []byte) (int, error)