Struct ethcore::encoded::Block
[−]
[src]
pub struct Block(_);
Owning block view.
Methods
impl Block
[src]
fn new(raw: Vec<u8>) -> Self
Create a new owning block view. The raw bytes passed in must be an rlp-encoded block.
fn view(&self) -> BlockView
Get a borrowed view of the whole block.
fn header_view(&self) -> HeaderView
Get a borrowed view of the block header.
fn decode(&self) -> FullBlock
Decode to a full block.
fn rlp(&self) -> Rlp
Get the rlp of this block.
fn into_inner(self) -> Vec<u8>
Consume the view and return the raw bytes.
impl Block
[src]
fn hash(&self) -> H256
Returns the header hash.
fn parent_hash(&self) -> H256
Returns the parent hash.
fn uncles_hash(&self) -> H256
Returns the uncles hash.
Returns the author.
fn state_root(&self) -> H256
Returns the state root.
fn transactions_root(&self) -> H256
Returns the transaction trie root.
fn receipts_root(&self) -> H256
Returns the receipts trie root
fn log_bloom(&self) -> H2048
Returns the block log bloom
fn difficulty(&self) -> U256
Difficulty of this block
fn number(&self) -> BlockNumber
Number of this block.
fn timestamp(&self) -> u64
Time this block was produced.
fn gas_limit(&self) -> U256
Gas limit of this block.
fn gas_used(&self) -> U256
Total gas used in this block.
fn extra_data(&self) -> Vec<u8>
Block extra data.
fn seal(&self) -> Vec<Vec<u8>>
Engine-specific seal fields.
impl Block
[src]
fn transactions(&self) -> Vec<UnverifiedTransaction>
Get a vector of all transactions.
fn transactions_count(&self) -> usize
Number of transactions in the block.
fn transaction_views(&self) -> Vec<TransactionView>
A view over each transaction in the block.
fn transaction_hashes(&self) -> Vec<H256>
The hash of each transaction in the block.
fn uncles(&self) -> Vec<FullHeader>
Decode uncle headers.
fn uncles_count(&self) -> usize
Number of uncles.
fn uncle_views(&self) -> Vec<HeaderView>
Borrowed view over each uncle.
fn uncle_hashes(&self) -> Vec<H256>
Hash of each uncle.
Trait Implementations
impl Debug for Block
[src]
impl Clone for Block
[src]
fn clone(&self) -> Block
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0
Performs copy-assignment from source
. Read more
impl PartialEq for Block
[src]
fn eq(&self, __arg_0: &Block) -> bool
This method tests for self
and other
values to be equal, and is used by ==
. Read more
fn ne(&self, __arg_0: &Block) -> bool
This method tests for !=
.