corepb

package
v0.5.3 Latest Latest
Warning

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

Go to latest
Published: Jun 14, 2019 License: GPL-3.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Account

type Account struct {
	// account transaction nonce start from 0
	Nonce uint64 `protobuf:"varint,1,opt,name=nonce,proto3" json:"nonce,omitempty"`
	// account balance encoded big-endian bytes with math/big/Int.Bytes()
	Balance              []byte   `protobuf:"bytes,2,opt,name=balance,proto3" json:"balance,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*Account) Descriptor

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

func (*Account) GetBalance

func (m *Account) GetBalance() []byte

func (*Account) GetNonce

func (m *Account) GetNonce() uint64

func (*Account) ProtoMessage

func (*Account) ProtoMessage()

func (*Account) Reset

func (m *Account) Reset()

func (*Account) String

func (m *Account) String() string

func (*Account) XXX_DiscardUnknown

func (m *Account) XXX_DiscardUnknown()

func (*Account) XXX_Marshal

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

func (*Account) XXX_Merge

func (dst *Account) XXX_Merge(src proto.Message)

func (*Account) XXX_Size

func (m *Account) XXX_Size() int

func (*Account) XXX_Unmarshal

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

type Block

type Block struct {
	Header               *SignedBlockHeader `protobuf:"bytes,1,opt,name=header,proto3" json:"header,omitempty"`
	Body                 *BlockBody         `protobuf:"bytes,2,opt,name=body,proto3" json:"body,omitempty"`
	XXX_NoUnkeyedLiteral struct{}           `json:"-"`
	XXX_unrecognized     []byte             `json:"-"`
	XXX_sizecache        int32              `json:"-"`
}

func (*Block) Descriptor

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

func (*Block) GetBody

func (m *Block) GetBody() *BlockBody

func (*Block) GetHeader

func (m *Block) GetHeader() *SignedBlockHeader

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 (dst *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 BlockBody

type BlockBody struct {
	// encoded transaction bytes
	RawTransactions      [][]byte `protobuf:"bytes,1,rep,name=raw_transactions,json=rawTransactions,proto3" json:"raw_transactions,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

message for

block body = block - header

func (*BlockBody) Descriptor

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

func (*BlockBody) GetRawTransactions

func (m *BlockBody) GetRawTransactions() [][]byte

func (*BlockBody) ProtoMessage

func (*BlockBody) ProtoMessage()

func (*BlockBody) Reset

func (m *BlockBody) Reset()

func (*BlockBody) String

func (m *BlockBody) String() string

func (*BlockBody) XXX_DiscardUnknown

func (m *BlockBody) XXX_DiscardUnknown()

func (*BlockBody) XXX_Marshal

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

func (*BlockBody) XXX_Merge

func (dst *BlockBody) XXX_Merge(src proto.Message)

func (*BlockBody) XXX_Size

func (m *BlockBody) XXX_Size() int

func (*BlockBody) XXX_Unmarshal

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

type Signature

type Signature struct {
	// signer address
	// may be omitted if address can be inferred from signature
	Signer []byte `protobuf:"bytes,1,opt,name=signer,proto3" json:"signer,omitempty"`
	// signature algorithm
	// may be omitted for default algorithm
	SigAlgorithm uint32 `protobuf:"varint,2,opt,name=sigAlgorithm,proto3" json:"sigAlgorithm,omitempty"`
	// encoded signature bytes
	Signature            []byte   `protobuf:"bytes,3,opt,name=signature,proto3" json:"signature,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

signature for a block header or transaction

func (*Signature) Descriptor

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

func (*Signature) GetSigAlgorithm

func (m *Signature) GetSigAlgorithm() uint32

func (*Signature) GetSignature

func (m *Signature) GetSignature() []byte

func (*Signature) GetSigner

func (m *Signature) GetSigner() []byte

func (*Signature) ProtoMessage

func (*Signature) ProtoMessage()

func (*Signature) Reset

func (m *Signature) Reset()

func (*Signature) String

func (m *Signature) String() string

func (*Signature) XXX_DiscardUnknown

func (m *Signature) XXX_DiscardUnknown()

func (*Signature) XXX_Marshal

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

func (*Signature) XXX_Merge

func (dst *Signature) XXX_Merge(src proto.Message)

func (*Signature) XXX_Size

func (m *Signature) XXX_Size() int

func (*Signature) XXX_Unmarshal

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

type SignedBlockHeader

type SignedBlockHeader struct {
	// embedded encoded block header
	Header []byte `protobuf:"bytes,1,opt,name=header,proto3" json:"header,omitempty"`
	// block tx bloom filter
	Bloom []byte `protobuf:"bytes,2,opt,name=bloom,proto3" json:"bloom,omitempty"`
	// header signature for hash(hash(header) + bloom)
	Signatures           []*Signature `protobuf:"bytes,3,rep,name=signatures,proto3" json:"signatures,omitempty"`
	XXX_NoUnkeyedLiteral struct{}     `json:"-"`
	XXX_unrecognized     []byte       `json:"-"`
	XXX_sizecache        int32        `json:"-"`
}

message for

block header
bloom filter for related addresses
multiple signatures from validator

func (*SignedBlockHeader) Descriptor

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

func (*SignedBlockHeader) GetBloom

func (m *SignedBlockHeader) GetBloom() []byte

func (*SignedBlockHeader) GetHeader

func (m *SignedBlockHeader) GetHeader() []byte

func (*SignedBlockHeader) GetSignatures

func (m *SignedBlockHeader) GetSignatures() []*Signature

func (*SignedBlockHeader) ProtoMessage

func (*SignedBlockHeader) ProtoMessage()

func (*SignedBlockHeader) Reset

func (m *SignedBlockHeader) Reset()

func (*SignedBlockHeader) String

func (m *SignedBlockHeader) String() string

func (*SignedBlockHeader) XXX_DiscardUnknown

func (m *SignedBlockHeader) XXX_DiscardUnknown()

func (*SignedBlockHeader) XXX_Marshal

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

func (*SignedBlockHeader) XXX_Merge

func (dst *SignedBlockHeader) XXX_Merge(src proto.Message)

func (*SignedBlockHeader) XXX_Size

func (m *SignedBlockHeader) XXX_Size() int

func (*SignedBlockHeader) XXX_Unmarshal

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

type Transaction

type Transaction struct {
	// chain ID
	ChainID uint32 `protobuf:"varint,1,opt,name=chainID,proto3" json:"chainID,omitempty"`
	// transaction nonce
	Nonce uint64 `protobuf:"varint,2,opt,name=nonce,proto3" json:"nonce,omitempty"`
	// transaction recipient
	Recipient []byte `protobuf:"bytes,3,opt,name=recipient,proto3" json:"recipient,omitempty"`
	// transaction amount
	Amount []byte `protobuf:"bytes,4,opt,name=amount,proto3" json:"amount,omitempty"`
	// signature with LAST MESSAGE TAG of one byte
	Signature            *Signature `protobuf:"bytes,15,opt,name=signature,proto3" json:"signature,omitempty"`
	XXX_NoUnkeyedLiteral struct{}   `json:"-"`
	XXX_unrecognized     []byte     `json:"-"`
	XXX_sizecache        int32      `json:"-"`
}

func (*Transaction) Descriptor

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

func (*Transaction) GetAmount

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

func (*Transaction) GetChainID

func (m *Transaction) GetChainID() uint32

func (*Transaction) GetNonce

func (m *Transaction) GetNonce() uint64

func (*Transaction) GetRecipient

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

func (*Transaction) GetSignature

func (m *Transaction) GetSignature() *Signature

func (*Transaction) ProtoMessage

func (*Transaction) ProtoMessage()

func (*Transaction) Reset

func (m *Transaction) Reset()

func (*Transaction) String

func (m *Transaction) String() string

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 (dst *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

Jump to

Keyboard shortcuts

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