blockpb

package
v3.0.0-rc1+incompatible Latest Latest
Warning

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

Go to latest
Published: Feb 11, 2019 License: LGPL-3.0 Imports: 5 Imported by: 2

Documentation

Index

Constants

This section is empty.

Variables

View Source
var BlockType_name = map[int32]string{
	0: "NORMAL",
	1: "ONLYHASH",
}
View Source
var BlockType_value = map[string]int32{
	"NORMAL":   0,
	"ONLYHASH": 1,
}

Functions

This section is empty.

Types

type Block

type Block struct {
	Head                 *BlockHead       `protobuf:"bytes,1,opt,name=head,proto3" json:"head,omitempty"`
	Sign                 *pb.Signature    `protobuf:"bytes,2,opt,name=sign,proto3" json:"sign,omitempty"`
	Txs                  []*pb1.Tx        `protobuf:"bytes,3,rep,name=txs,proto3" json:"txs,omitempty"`
	Receipts             []*pb1.TxReceipt `protobuf:"bytes,4,rep,name=receipts,proto3" json:"receipts,omitempty"`
	TxHashes             [][]byte         `protobuf:"bytes,5,rep,name=txHashes,proto3" json:"txHashes,omitempty"`
	ReceiptHashes        [][]byte         `protobuf:"bytes,6,rep,name=receiptHashes,proto3" json:"receiptHashes,omitempty"`
	BlockType            BlockType        `protobuf:"varint,7,opt,name=blockType,proto3,enum=blockpb.BlockType" json:"blockType,omitempty"`
	XXX_NoUnkeyedLiteral struct{}         `json:"-"`
	XXX_unrecognized     []byte           `json:"-"`
	XXX_sizecache        int32            `json:"-"`
}

func (*Block) Descriptor

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

func (*Block) GetBlockType

func (m *Block) GetBlockType() BlockType

func (*Block) GetHead

func (m *Block) GetHead() *BlockHead

func (*Block) GetReceiptHashes

func (m *Block) GetReceiptHashes() [][]byte

func (*Block) GetReceipts

func (m *Block) GetReceipts() []*pb1.TxReceipt

func (*Block) GetSign

func (m *Block) GetSign() *pb.Signature

func (*Block) GetTxHashes

func (m *Block) GetTxHashes() [][]byte

func (*Block) GetTxs

func (m *Block) GetTxs() []*pb1.Tx

func (*Block) ProtoMessage

func (*Block) ProtoMessage()

func (*Block) Reset

func (m *Block) Reset()

func (*Block) String

func (m *Block) String() string

func (*Block) XXX_DiscardUnknown

func (m *Block) XXX_DiscardUnknown()

func (*Block) XXX_Marshal

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

func (*Block) XXX_Merge

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

func (*Block) XXX_Size

func (m *Block) XXX_Size() int

func (*Block) XXX_Unmarshal

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

type BlockHead

type BlockHead struct {
	Version              int64    `protobuf:"varint,1,opt,name=version,proto3" json:"version,omitempty"`
	ParentHash           []byte   `protobuf:"bytes,2,opt,name=parentHash,proto3" json:"parentHash,omitempty"`
	TxMerkleHash         []byte   `protobuf:"bytes,3,opt,name=txMerkleHash,proto3" json:"txMerkleHash,omitempty"`
	TxReceiptMerkleHash  []byte   `protobuf:"bytes,4,opt,name=txReceiptMerkleHash,proto3" json:"txReceiptMerkleHash,omitempty"`
	Info                 []byte   `protobuf:"bytes,5,opt,name=info,proto3" json:"info,omitempty"`
	Number               int64    `protobuf:"varint,6,opt,name=number,proto3" json:"number,omitempty"`
	Witness              string   `protobuf:"bytes,7,opt,name=witness,proto3" json:"witness,omitempty"`
	Time                 int64    `protobuf:"varint,8,opt,name=time,proto3" json:"time,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*BlockHead) Descriptor

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

func (*BlockHead) GetInfo

func (m *BlockHead) GetInfo() []byte

func (*BlockHead) GetNumber

func (m *BlockHead) GetNumber() int64

func (*BlockHead) GetParentHash

func (m *BlockHead) GetParentHash() []byte

func (*BlockHead) GetTime

func (m *BlockHead) GetTime() int64

func (*BlockHead) GetTxMerkleHash

func (m *BlockHead) GetTxMerkleHash() []byte

func (*BlockHead) GetTxReceiptMerkleHash

func (m *BlockHead) GetTxReceiptMerkleHash() []byte

func (*BlockHead) GetVersion

func (m *BlockHead) GetVersion() int64

func (*BlockHead) GetWitness

func (m *BlockHead) GetWitness() string

func (*BlockHead) ProtoMessage

func (*BlockHead) ProtoMessage()

func (*BlockHead) Reset

func (m *BlockHead) Reset()

func (*BlockHead) String

func (m *BlockHead) String() string

func (*BlockHead) XXX_DiscardUnknown

func (m *BlockHead) XXX_DiscardUnknown()

func (*BlockHead) XXX_Marshal

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

func (*BlockHead) XXX_Merge

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

func (*BlockHead) XXX_Size

func (m *BlockHead) XXX_Size() int

func (*BlockHead) XXX_Unmarshal

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

type BlockType

type BlockType int32
const (
	BlockType_NORMAL   BlockType = 0
	BlockType_ONLYHASH BlockType = 1
)

func (BlockType) EnumDescriptor

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

func (BlockType) String

func (x BlockType) String() string

Jump to

Keyboard shortcuts

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