Struct ethereum_forkid::ForkFilter
source · pub struct ForkFilter { /* private fields */ }
Expand description
Filter that describes the state of blockchain and can be used to check incoming ForkId
s for compatibility.
Implementations§
source§impl ForkFilter
impl ForkFilter
sourcepub fn new<F>(head: BlockNumber, genesis: H256, forks: F) -> Selfwhere
F: IntoIterator<Item = BlockNumber>,
pub fn new<F>(head: BlockNumber, genesis: H256, forks: F) -> Selfwhere F: IntoIterator<Item = BlockNumber>,
Create the filter from provided head, genesis block hash, past forks and expected future forks.
sourcepub fn set_head(&mut self, head: BlockNumber)
pub fn set_head(&mut self, head: BlockNumber)
Set the current head
Trait Implementations§
source§impl Clone for ForkFilter
impl Clone for ForkFilter
source§fn clone(&self) -> ForkFilter
fn clone(&self) -> ForkFilter
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresource§impl Debug for ForkFilter
impl Debug for ForkFilter
source§impl PartialEq<ForkFilter> for ForkFilter
impl PartialEq<ForkFilter> for ForkFilter
source§fn eq(&self, other: &ForkFilter) -> bool
fn eq(&self, other: &ForkFilter) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.