reth_provider

Trait ChainSpecProvider

pub trait ChainSpecProvider: Send + Sync {
    type ChainSpec: EthChainSpec + 'static;

    // Required method
    fn chain_spec(&self) -> Arc<Self::ChainSpec>;
}
Expand description

A trait for reading the current chainspec.

Required Associated Types§

type ChainSpec: EthChainSpec + 'static

The chain spec type.

Required Methods§

fn chain_spec(&self) -> Arc<Self::ChainSpec>

Get an Arc to the chainspec.

Implementations on Foreign Types§

§

impl<'a, T> ChainSpecProvider for &'a T
where T: 'a + ChainSpecProvider + ?Sized, &'a T: Send + Sync,

§

impl<T> ChainSpecProvider for Arc<T>
where T: ChainSpecProvider + ?Sized, Arc<T>: Send + Sync,

Implementors§

Source§

impl ChainSpecProvider for MockEthProvider

Available on crate feature test-utils only.
Source§

type ChainSpec = ChainSpec

Source§

impl ChainSpecProvider for NoopProvider

Available on crate feature test-utils only.
Source§

type ChainSpec = ChainSpec

§

impl<ChainSpec> ChainSpecProvider for NoopBlockReader<ChainSpec>
where ChainSpec: EthChainSpec + 'static,

§

type ChainSpec = ChainSpec

Source§

impl<N: ProviderNodeTypes> ChainSpecProvider for BlockchainProvider<N>

Source§

type ChainSpec = <N as NodeTypes>::ChainSpec

Source§

impl<N: ProviderNodeTypes> ChainSpecProvider for ConsistentProvider<N>

Source§

type ChainSpec = <N as NodeTypes>::ChainSpec

Source§

impl<N: NodeTypesWithDB> ChainSpecProvider for BlockchainProvider2<N>

Source§

type ChainSpec = <N as NodeTypes>::ChainSpec

Source§

impl<N: NodeTypesWithDB> ChainSpecProvider for ProviderFactory<N>

Source§

type ChainSpec = <N as NodeTypes>::ChainSpec

Source§

impl<TX: Send + Sync, N: NodeTypes<ChainSpec: EthChainSpec + 'static>> ChainSpecProvider for DatabaseProvider<TX, N>

Source§

type ChainSpec = <N as NodeTypes>::ChainSpec