Documentation
¶
Index ¶
- func BloomLookup(bin, topic []byte) bool
- func CreateBloom(receipts Receipts) []byte
- func DeriveSha(list DerivableList) []byte
- 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() []byte
- func (self *Block) Coinbase() []byte
- func (self *Block) DecodeRLP(s *rlp.Stream) error
- func (self *Block) Difficulty() *big.Int
- 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() []byte
- func (self *Block) HashNoNonce() []byte
- func (self *Block) Header() *Header
- func (self *Block) N() []byte
- func (self *Block) Nonce() []byte
- func (self *Block) Number() *big.Int
- func (self *Block) NumberU64() uint64
- func (self *Block) ParentHash() []byte
- func (self *Block) Receipts() Receipts
- func (self *Block) RlpData() interface{}
- func (self *Block) RlpDataForStorage() interface{}
- func (self *Block) Root() []byte
- func (self *Block) SetReceipts(receipts Receipts)
- func (self *Block) SetRoot(root []byte)
- func (self *Block) SetTransactions(transactions Transactions)
- func (self *Block) SetUncles(uncleHeaders []*Header)
- func (self *Block) Size() ethutil.StorageSize
- func (self *Block) String() string
- func (self *Block) Time() int64
- func (self *Block) Transaction(hash []byte) *Transaction
- func (self *Block) Transactions() Transactions
- func (self *Block) Uncles() []*Header
- type BlockBy
- type BlockProcessor
- type Blocks
- type DerivableList
- type Header
- type Receipt
- type Receipts
- type Transaction
- func NewContractCreationTx(Amount, gasAmount, price *big.Int, data []byte) *Transaction
- func NewTransactionFromAmount(val *ethutil.Value) *Transaction
- func NewTransactionFromBytes(data []byte) *Transaction
- func NewTransactionMessage(to []byte, Amount, gasAmount, price *big.Int, data []byte) *Transaction
- func (tx *Transaction) Curve() (v byte, r []byte, s []byte)
- func (self *Transaction) Data() []byte
- func (self *Transaction) From() []byte
- func (self *Transaction) Gas() *big.Int
- func (self *Transaction) GasPrice() *big.Int
- func (tx *Transaction) Hash() []byte
- func (self *Transaction) Nonce() uint64
- func (tx *Transaction) PublicKey() []byte
- func (tx *Transaction) RlpData() interface{}
- func (tx *Transaction) RlpDecode(data []byte)
- func (tx *Transaction) RlpEncode() []byte
- func (tx *Transaction) RlpValueDecode(decoder *ethutil.Value)
- func (self *Transaction) SetNonce(AccountNonce uint64)
- func (tx *Transaction) Sign(privk []byte) error
- func (tx *Transaction) SignECDSA(key *ecdsa.PrivateKey) error
- func (tx *Transaction) Signature(key []byte) []byte
- func (tx *Transaction) String() string
- func (self *Transaction) To() []byte
- func (self *Transaction) Value() *big.Int
- type Transactions
- type TxByNonce
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func BloomLookup ¶
func CreateBloom ¶
func DeriveSha ¶
func DeriveSha(list DerivableList) []byte
func IsContractAddr ¶
Types ¶
type Block ¶
type Block struct {
// Preset Hash for mock
HeaderHash []byte
ParentHeaderHash []byte
Td *big.Int
Reward *big.Int
// contains filtered or unexported fields
}
func NewBlockWithHeader ¶ added in v0.8.4
func (*Block) AddReceipt ¶ added in v0.8.4
func (*Block) AddTransaction ¶ added in v0.8.4
func (self *Block) AddTransaction(transaction *Transaction)
func (*Block) GetTransaction ¶
func (self *Block) GetTransaction(i int) *Transaction
func (*Block) HashNoNonce ¶
func (*Block) ParentHash ¶ added in v0.8.4
func (*Block) RlpDataForStorage ¶ added in v0.8.4
func (self *Block) RlpDataForStorage() interface{}
func (*Block) SetReceipts ¶
func (*Block) SetTransactions ¶
func (self *Block) SetTransactions(transactions Transactions)
func (*Block) Size ¶
func (self *Block) Size() ethutil.StorageSize
func (*Block) Transaction ¶ added in v0.8.4
func (self *Block) Transaction(hash []byte) *Transaction
func (*Block) Transactions ¶
func (self *Block) Transactions() Transactions
type DerivableList ¶
type Header ¶ added in v0.8.4
type Header struct {
// Hash to the previous block
ParentHash ethutil.Bytes
// Uncles of this block
UncleHash []byte
// The coin base address
Coinbase []byte
// Block Trie state
Root []byte
// Tx sha
TxHash []byte
// Receipt sha
ReceiptHash []byte
// Bloom
Bloom []byte
// 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 string
// Block Nonce for verification
Nonce ethutil.Bytes
}
func (*Header) HashNoNonce ¶ added in v0.8.4
type Receipt ¶
type Receipt struct {
PostState []byte
CumulativeGasUsed *big.Int
Bloom []byte
// contains filtered or unexported fields
}
func NewRecieptFromValue ¶
func (*Receipt) RlpValueDecode ¶
type Transaction ¶
type Transaction struct {
AccountNonce uint64
Price *big.Int
GasLimit *big.Int
Recipient []byte
Amount *big.Int
Payload []byte
V uint64
R, S []byte
}
func NewContractCreationTx ¶
func NewContractCreationTx(Amount, gasAmount, price *big.Int, data []byte) *Transaction
func NewTransactionFromAmount ¶ added in v0.8.4
func NewTransactionFromAmount(val *ethutil.Value) *Transaction
func NewTransactionFromBytes ¶
func NewTransactionFromBytes(data []byte) *Transaction
func NewTransactionMessage ¶
func NewTransactionMessage(to []byte, Amount, gasAmount, price *big.Int, data []byte) *Transaction
func (*Transaction) Data ¶
func (self *Transaction) Data() []byte
func (*Transaction) From ¶
func (self *Transaction) From() []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() []byte
func (*Transaction) Nonce ¶
func (self *Transaction) Nonce() uint64
func (*Transaction) PublicKey ¶
func (tx *Transaction) PublicKey() []byte
func (*Transaction) RlpData ¶
func (tx *Transaction) RlpData() interface{}
func (*Transaction) RlpDecode ¶
func (tx *Transaction) RlpDecode(data []byte)
func (*Transaction) RlpEncode ¶
func (tx *Transaction) RlpEncode() []byte
func (*Transaction) RlpValueDecode ¶
func (tx *Transaction) RlpValueDecode(decoder *ethutil.Value)
func (*Transaction) SetNonce ¶
func (self *Transaction) SetNonce(AccountNonce uint64)
func (*Transaction) Sign ¶
func (tx *Transaction) Sign(privk []byte) error
func (*Transaction) SignECDSA ¶ added in v0.8.4
func (tx *Transaction) SignECDSA(key *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 (self *Transaction) To() []byte
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) RlpData ¶
func (self Transactions) RlpData() interface{}
func (Transactions) Swap ¶
func (s Transactions) Swap(i, j int)
Click to show internal directories.
Click to hide internal directories.