Documentation
¶
Index ¶
- Variables
- func BloomLookup(bin Bloom, topic bytesBacked) bool
- func DeriveSha(list DerivableList) common.Hash
- func IsContractAddr(addr []byte) bool
- func LogsBloom(logs state.Logs) *big.Int
- func Number(b1, b2 *Block) bool
- type Block
- func (self *Block) AddReceipt(receipt *Receipt)
- func (self *Block) AddTransaction(transaction *Transaction)
- func (self *Block) Bloom() Bloom
- func (self *Block) CalculateUnclesHash() common.Hash
- func (self *Block) Coinbase() common.Address
- func (self *Block) Copy() *Block
- func (self *Block) DecodeRLP(s *rlp.Stream) error
- func (self *Block) Difficulty() *big.Int
- func (self Block) EncodeRLP(w io.Writer) error
- func (self *Block) GasLimit() *big.Int
- func (self *Block) GasUsed() *big.Int
- func (self *Block) GetTransaction(i int) *Transaction
- func (self *Block) GetUncle(i int) *Header
- func (self *Block) Hash() common.Hash
- func (self *Block) HashNoNonce() common.Hash
- func (self *Block) Header() *Header
- func (self *Block) MixDigest() common.Hash
- func (self *Block) Nonce() uint64
- func (self *Block) Number() *big.Int
- func (self *Block) NumberU64() uint64
- func (self *Block) ParentHash() common.Hash
- func (self *Block) Queued() bool
- func (self *Block) Receipts() Receipts
- func (self *Block) RlpData() interface{}
- func (self *Block) RlpDataForStorage() interface{}
- func (self *Block) Root() common.Hash
- func (self *Block) SetNonce(nonce uint64)
- func (self *Block) SetQueued(q bool)
- func (self *Block) SetReceipts(receipts Receipts)
- func (self *Block) SetRoot(root common.Hash)
- func (self *Block) SetTransactions(transactions Transactions)
- func (self *Block) SetUncles(uncleHeaders []*Header)
- func (self *Block) Size() common.StorageSize
- func (self *Block) String() string
- func (self *Block) Time() int64
- func (self *Block) Transaction(hash common.Hash) *Transaction
- func (self *Block) Transactions() Transactions
- func (self *Block) Uncles() []*Header
- func (self *Block) ValidateFields() error
- type BlockBy
- type BlockProcessor
- type Blocks
- type Bloom
- type DerivableList
- type Header
- type Receipt
- func (self *Receipt) Cmp(other *Receipt) bool
- func (self *Receipt) DecodeRLP(s *rlp.Stream) error
- func (self *Receipt) EncodeRLP(w io.Writer) error
- func (self *Receipt) Logs() state.Logs
- func (self *Receipt) RlpEncode() []byte
- func (self *Receipt) SetLogs(logs state.Logs)
- func (self *Receipt) String() string
- type ReceiptForStorage
- type Receipts
- type StorageBlock
- type Transaction
- func (tx *Transaction) Curve() (v byte, r []byte, s []byte)
- func (self *Transaction) Data() []byte
- func (self *Transaction) From() (common.Address, error)
- func (self *Transaction) Gas() *big.Int
- func (self *Transaction) GasPrice() *big.Int
- func (tx *Transaction) Hash() common.Hash
- func (self *Transaction) Nonce() uint64
- func (tx *Transaction) PublicKey() []byte
- func (tx *Transaction) RlpData() interface{}
- func (self *Transaction) SetNonce(AccountNonce uint64)
- func (tx *Transaction) SetSignatureValues(sig []byte) error
- func (tx *Transaction) SignECDSA(prv *ecdsa.PrivateKey) error
- func (tx *Transaction) Signature(key []byte) []byte
- func (tx *Transaction) String() string
- func (tx *Transaction) To() *common.Address
- func (self *Transaction) Value() *big.Int
- type Transactions
- type TxByNonce
Constants ¶
This section is empty.
Variables ¶
View Source
var Bloom9 = bloom9
Functions ¶
func BloomLookup ¶
func DeriveSha ¶
func DeriveSha(list DerivableList) common.Hash
func IsContractAddr ¶
Types ¶
type Block ¶
type Block struct { // Preset Hash for mock (Tests) HeaderHash common.Hash ParentHeaderHash common.Hash Td *big.Int ReceivedAt time.Time // contains filtered or unexported fields }
func NewBlockWithHeader ¶ added in v0.8.5
func (*Block) AddReceipt ¶ added in v0.8.5
func (*Block) AddTransaction ¶ added in v0.8.5
func (self *Block) AddTransaction(transaction *Transaction)
func (*Block) CalculateUnclesHash ¶ added in v0.9.17
func (*Block) GetTransaction ¶
func (self *Block) GetTransaction(i int) *Transaction
func (*Block) HashNoNonce ¶
func (*Block) ParentHash ¶ added in v0.8.5
func (*Block) RlpDataForStorage ¶ added in v0.8.5
func (self *Block) RlpDataForStorage() interface{}
func (*Block) SetReceipts ¶
func (*Block) SetTransactions ¶
func (self *Block) SetTransactions(transactions Transactions)
func (*Block) Size ¶
func (self *Block) Size() common.StorageSize
func (*Block) Transaction ¶ added in v0.8.5
func (self *Block) Transaction(hash common.Hash) *Transaction
func (*Block) Transactions ¶
func (self *Block) Transactions() Transactions
func (*Block) ValidateFields ¶ added in v0.9.17
type Bloom ¶ added in v0.9.17
type Bloom [bloomLength]byte
func BytesToBloom ¶ added in v0.9.17
func CreateBloom ¶
type DerivableList ¶
type Header ¶ added in v0.8.5
type Header struct { // Hash to the previous block ParentHash common.Hash // Uncles of this block UncleHash common.Hash // The coin base address Coinbase common.Address // Block Trie state Root common.Hash // Tx sha TxHash common.Hash // Receipt sha ReceiptHash common.Hash // Bloom Bloom Bloom // Difficulty for the current block Difficulty *big.Int // The block number Number *big.Int // Gas limit GasLimit *big.Int // Gas used GasUsed *big.Int // Creation time Time uint64 // Extra data Extra []byte // Mix digest for quick checking to prevent DOS MixDigest common.Hash // Nonce Nonce [8]byte }
func (*Header) HashNoNonce ¶ added in v0.8.5
type Receipt ¶
type ReceiptForStorage ¶ added in v0.9.26
type ReceiptForStorage Receipt
type StorageBlock ¶ added in v0.9.17
type StorageBlock Block
StorageBlock defines the RLP encoding of a Block stored in the state database. The StorageBlock encoding contains fields that would otherwise need to be recomputed.
type Transaction ¶
type Transaction struct { AccountNonce uint64 Price *big.Int GasLimit *big.Int Recipient *common.Address `rlp:"nil"` // nil means contract creation Amount *big.Int Payload []byte V byte R, S *big.Int }
func NewContractCreationTx ¶
func NewContractCreationTx(amount, gasLimit, gasPrice *big.Int, data []byte) *Transaction
func NewTransactionFromBytes ¶
func NewTransactionFromBytes(data []byte) *Transaction
func NewTransactionMessage ¶
func (*Transaction) Data ¶
func (self *Transaction) Data() []byte
func (*Transaction) Gas ¶
func (self *Transaction) Gas() *big.Int
func (*Transaction) GasPrice ¶
func (self *Transaction) GasPrice() *big.Int
func (*Transaction) Hash ¶
func (tx *Transaction) Hash() common.Hash
func (*Transaction) Nonce ¶
func (self *Transaction) Nonce() uint64
func (*Transaction) PublicKey ¶
func (tx *Transaction) PublicKey() []byte
func (*Transaction) SetNonce ¶
func (self *Transaction) SetNonce(AccountNonce uint64)
func (*Transaction) SetSignatureValues ¶ added in v0.9.17
func (tx *Transaction) SetSignatureValues(sig []byte) error
func (*Transaction) SignECDSA ¶ added in v0.8.5
func (tx *Transaction) SignECDSA(prv *ecdsa.PrivateKey) error
func (*Transaction) Signature ¶
func (tx *Transaction) Signature(key []byte) []byte
func (*Transaction) String ¶
func (tx *Transaction) String() string
func (*Transaction) To ¶
func (tx *Transaction) To() *common.Address
To returns the recipient of the transaction. If transaction is a contract creation (with no recipient address) To returns nil.
func (*Transaction) Value ¶
func (self *Transaction) Value() *big.Int
type Transactions ¶
type Transactions []*Transaction
Transaction slice type for basic sorting
func (Transactions) GetRlp ¶
func (s Transactions) GetRlp(i int) []byte
func (Transactions) Len ¶
func (s Transactions) Len() int
func (Transactions) Swap ¶
func (s Transactions) Swap(i, j int)
Click to show internal directories.
Click to hide internal directories.