proto

package
v0.1.1 Latest Latest
Warning

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

Go to latest
Published: Feb 7, 2020 License: Apache-2.0, BSD-2-Clause Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type MType

type MType uint

MType is the type of message type enum.

const (
	MTransaction MType = 20 + iota
	MTransactionRequest
)

An enum for the different message types.

type Message

type Message interface {
	proto.Message

	// Name returns the name of the corresponding message type for debugging.
	Name() string
	// Type returns the type of the corresponding message as an enum.
	Type() MType
}

Message extends the proto.Message interface with additional util functions.

type Transaction

type Transaction struct {
	// transaction data
	Data                 []byte   `protobuf:"bytes,1,opt,name=data,proto3" json:"data,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*Transaction) Descriptor

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

func (*Transaction) GetData

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

func (*Transaction) Name

func (m *Transaction) Name() string

func (*Transaction) ProtoMessage

func (*Transaction) ProtoMessage()

func (*Transaction) Reset

func (m *Transaction) Reset()

func (*Transaction) String

func (m *Transaction) String() string

func (*Transaction) Type

func (m *Transaction) Type() MType

func (*Transaction) XXX_DiscardUnknown

func (m *Transaction) XXX_DiscardUnknown()

func (*Transaction) XXX_Marshal

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

func (*Transaction) XXX_Merge

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

func (*Transaction) XXX_Size

func (m *Transaction) XXX_Size() int

func (*Transaction) XXX_Unmarshal

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

type TransactionRequest

type TransactionRequest struct {
	// transaction hash
	Hash                 []byte   `protobuf:"bytes,1,opt,name=hash,proto3" json:"hash,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*TransactionRequest) Descriptor

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

func (*TransactionRequest) GetHash

func (m *TransactionRequest) GetHash() []byte

func (*TransactionRequest) Name

func (m *TransactionRequest) Name() string

func (*TransactionRequest) ProtoMessage

func (*TransactionRequest) ProtoMessage()

func (*TransactionRequest) Reset

func (m *TransactionRequest) Reset()

func (*TransactionRequest) String

func (m *TransactionRequest) String() string

func (*TransactionRequest) Type

func (m *TransactionRequest) Type() MType

func (*TransactionRequest) XXX_DiscardUnknown

func (m *TransactionRequest) XXX_DiscardUnknown()

func (*TransactionRequest) XXX_Marshal

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

func (*TransactionRequest) XXX_Merge

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

func (*TransactionRequest) XXX_Size

func (m *TransactionRequest) XXX_Size() int

func (*TransactionRequest) XXX_Unmarshal

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

Jump to

Keyboard shortcuts

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