connection

package
v0.0.0-...-2897c99 Latest Latest
Warning

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

Go to latest
Published: Oct 19, 2022 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrInvalidLengthConnection        = fmt.Errorf("proto: negative length found during unmarshaling")
	ErrIntOverflowConnection          = fmt.Errorf("proto: integer overflow")
	ErrUnexpectedEndOfGroupConnection = fmt.Errorf("proto: unexpected end of group")
)
View Source
var ConnectionEnd_State_name = map[int32]string{
	0: "STATE_UNINITIALIZED_UNSPECIFIED",
	1: "STATE_INIT",
	2: "STATE_TRYOPEN",
	3: "STATE_OPEN",
}
View Source
var ConnectionEnd_State_value = map[string]int32{
	"STATE_UNINITIALIZED_UNSPECIFIED": 0,
	"STATE_INIT":                      1,
	"STATE_TRYOPEN":                   2,
	"STATE_OPEN":                      3,
}

Functions

This section is empty.

Types

type ConnectionEnd

type ConnectionEnd struct {
	// client associated with this connection.
	ClientId string `protobuf:"bytes,1,opt,name=client_id,json=clientId,proto3" json:"client_id,omitempty" yaml:"client_id"`
	// IBC version which can be utilised to determine encodings or protocols for
	// channels or packets utilising this connection.
	Versions []*Version `protobuf:"bytes,2,rep,name=versions,proto3" json:"versions,omitempty"`
	// current state of the connection end.
	State ConnectionEnd_State `protobuf:"varint,3,opt,name=state,proto3,enum=ConnectionEnd_State" json:"state,omitempty"`
	// counterparty chain associated with this connection.
	Counterparty Counterparty `protobuf:"bytes,4,opt,name=counterparty,proto3" json:"counterparty"`
	// delay period that must pass before a consensus state can be used for
	// packet-verification NOTE: delay period logic is only implemented by some
	// clients.
	DelayPeriod uint64 `protobuf:"varint,5,opt,name=delay_period,json=delayPeriod,proto3" json:"delay_period,omitempty" yaml:"delay_period"`
}

ConnectionEnd defines a stateful object on a chain connected to another separate one. NOTE: there must only be 2 defined ConnectionEnds to establish a connection between two chains.

func (*ConnectionEnd) Descriptor

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

func (*ConnectionEnd) Marshal

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

func (*ConnectionEnd) MarshalTo

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

func (*ConnectionEnd) MarshalToSizedBuffer

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

func (*ConnectionEnd) ProtoMessage

func (*ConnectionEnd) ProtoMessage()

func (*ConnectionEnd) Reset

func (m *ConnectionEnd) Reset()

func (*ConnectionEnd) Size

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

func (*ConnectionEnd) String

func (m *ConnectionEnd) String() string

func (*ConnectionEnd) Unmarshal

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

func (*ConnectionEnd) XXX_DiscardUnknown

func (m *ConnectionEnd) XXX_DiscardUnknown()

func (*ConnectionEnd) XXX_Marshal

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

func (*ConnectionEnd) XXX_Merge

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

func (*ConnectionEnd) XXX_Size

func (m *ConnectionEnd) XXX_Size() int

func (*ConnectionEnd) XXX_Unmarshal

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

type ConnectionEnd_State

type ConnectionEnd_State int32

State defines if a connection is in one of the following states: INIT, TRYOPEN, OPEN or UNINITIALIZED.

const (
	// Default State
	UNINITIALIZED ConnectionEnd_State = 0
	// A connection end has just started the opening handshake.
	INIT ConnectionEnd_State = 1
	// A connection end has acknowledged the handshake step on the counterparty
	// chain.
	TRYOPEN ConnectionEnd_State = 2
	// A connection end has completed the handshake.
	OPEN ConnectionEnd_State = 3
)

func (ConnectionEnd_State) EnumDescriptor

func (ConnectionEnd_State) EnumDescriptor() ([]byte, []int)

func (ConnectionEnd_State) String

func (x ConnectionEnd_State) String() string

type Counterparty

type Counterparty struct {
	// identifies the client on the counterparty chain associated with a given
	// connection.
	ClientId string `protobuf:"bytes,1,opt,name=client_id,json=clientId,proto3" json:"client_id,omitempty" yaml:"client_id"`
	// identifies the connection end on the counterparty chain associated with a
	// given connection.
	ConnectionId string `protobuf:"bytes,2,opt,name=connection_id,json=connectionId,proto3" json:"connection_id,omitempty" yaml:"connection_id"`
	// commitment merkle prefix of the counterparty chain.
	Prefix commitment.MerklePrefix `protobuf:"bytes,3,opt,name=prefix,proto3" json:"prefix"`
}

Counterparty defines the counterparty chain associated with a connection end.

func (*Counterparty) Descriptor

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

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) 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 Version

type Version struct {
	// unique version identifier
	Identifier string `protobuf:"bytes,1,opt,name=identifier,proto3" json:"identifier,omitempty"`
	// list of features compatible with the specified identifier
	Features []string `protobuf:"bytes,2,rep,name=features,proto3" json:"features,omitempty"`
}

Version defines the versioning scheme used to negotiate the IBC verison in the connection handshake.

func (*Version) Descriptor

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

func (*Version) Marshal

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

func (*Version) MarshalTo

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

func (*Version) MarshalToSizedBuffer

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

func (*Version) ProtoMessage

func (*Version) ProtoMessage()

func (*Version) Reset

func (m *Version) Reset()

func (*Version) Size

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

func (*Version) String

func (m *Version) String() string

func (*Version) Unmarshal

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

func (*Version) XXX_DiscardUnknown

func (m *Version) XXX_DiscardUnknown()

func (*Version) XXX_Marshal

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

func (*Version) XXX_Merge

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

func (*Version) XXX_Size

func (m *Version) XXX_Size() int

func (*Version) XXX_Unmarshal

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

Jump to

Keyboard shortcuts

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