Struct ethers_providers::admin::EthProtocolInfo
source · pub struct EthProtocolInfo {
pub network: u64,
pub difficulty: U256,
pub genesis: H256,
pub config: ChainConfig,
pub head: H256,
}
Expand description
Represents a short summary of the eth
sub-protocol metadata known about the host peer.
See geth’s NodeInfo
struct
for how these fields are determined.
Fields§
§network: u64
The eth network version.
difficulty: U256
The total difficulty of the host’s blockchain.
genesis: H256
The Keccak hash of the host’s genesis block.
config: ChainConfig
The chain configuration for the host’s fork rules.
head: H256
The hash of the host’s best known block.
Trait Implementations§
source§impl Clone for EthProtocolInfo
impl Clone for EthProtocolInfo
source§fn clone(&self) -> EthProtocolInfo
fn clone(&self) -> EthProtocolInfo
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 EthProtocolInfo
impl Debug for EthProtocolInfo
source§impl<'de> Deserialize<'de> for EthProtocolInfo
impl<'de> Deserialize<'de> for EthProtocolInfo
source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl RefUnwindSafe for EthProtocolInfo
impl Send for EthProtocolInfo
impl Sync for EthProtocolInfo
impl Unpin for EthProtocolInfo
impl UnwindSafe for EthProtocolInfo
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more