types

package
v18.1.0 Latest Latest
Warning

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

Go to latest
Published: Jul 8, 2024 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

View Source
const (
	ModuleName = "metaprotocols"
)

Variables

View Source
var (
	ErrInvalidLengthExtensions        = fmt.Errorf("proto: negative length found during unmarshaling")
	ErrIntOverflowExtensions          = fmt.Errorf("proto: integer overflow")
	ErrUnexpectedEndOfGroupExtensions = fmt.Errorf("proto: unexpected end of group")
)

Functions

func RegisterInterfaces

func RegisterInterfaces(registry types.InterfaceRegistry)

RegisterInterfaces adds the x/metaprotocols module's interfaces to the provided InterfaceRegistry The ExtendedData interface is registered so that the TxExtensionOptionsI can be properly encoded and decoded

Types

type ExtensionData

type ExtensionData struct {
	// protocol_id is the identifier of the protocol
	// the field is not used internally but it is validated for correctness
	ProtocolId string `protobuf:"bytes,1,opt,name=protocol_id,json=protocolId,proto3" json:"protocol_id,omitempty"`
	// protocol_version is the identifier of the protocol version
	// the field is not used internally but it is validated for correctness
	ProtocolVersion string `protobuf:"bytes,2,opt,name=protocol_version,json=protocolVersion,proto3" json:"protocol_version,omitempty"`
	// arbitrary bytes data that can be used to store any data
	// the field is not used internally but it is validated and must be provided
	Data []byte `protobuf:"bytes,3,opt,name=data,proto3" json:"data,omitempty"`
}

ExtensionData is a data structure that can be used in transaction extensions.

func (*ExtensionData) Descriptor

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

func (*ExtensionData) GetData

func (m *ExtensionData) GetData() []byte

func (*ExtensionData) GetProtocolId

func (m *ExtensionData) GetProtocolId() string

func (*ExtensionData) GetProtocolVersion

func (m *ExtensionData) GetProtocolVersion() string

func (*ExtensionData) Marshal

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

func (*ExtensionData) MarshalTo

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

func (*ExtensionData) MarshalToSizedBuffer

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

func (*ExtensionData) ProtoMessage

func (*ExtensionData) ProtoMessage()

func (*ExtensionData) Reset

func (m *ExtensionData) Reset()

func (*ExtensionData) Size

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

func (*ExtensionData) String

func (m *ExtensionData) String() string

func (*ExtensionData) Unmarshal

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

func (*ExtensionData) XXX_DiscardUnknown

func (m *ExtensionData) XXX_DiscardUnknown()

func (*ExtensionData) XXX_Marshal

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

func (*ExtensionData) XXX_Merge

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

func (*ExtensionData) XXX_Size

func (m *ExtensionData) XXX_Size() int

func (*ExtensionData) XXX_Unmarshal

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

Jump to

Keyboard shortcuts

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