pub trait BlockHashRef {
    type Error;

    // Required method
    fn block_hash(
        &self,
        number: Uint<256, 4>
    ) -> Result<FixedBytes<32>, Self::Error>;
}

Required Associated Types§

Required Methods§

source

fn block_hash( &self, number: Uint<256, 4> ) -> Result<FixedBytes<32>, Self::Error>

Get block hash by block number

Implementations on Foreign Types§

source§

impl<'a, T> BlockHashRef for &'a T
where T: 'a + BlockHashRef + ?Sized,

§

type Error = <T as BlockHashRef>::Error

source§

fn block_hash( &self, number: Uint<256, 4> ) -> Result<FixedBytes<32>, <&'a T as BlockHashRef>::Error>

source§

impl<'a, T> BlockHashRef for &'a mut T
where T: 'a + BlockHashRef + ?Sized,

§

type Error = <T as BlockHashRef>::Error

source§

fn block_hash( &self, number: Uint<256, 4> ) -> Result<FixedBytes<32>, <&'a mut T as BlockHashRef>::Error>

source§

impl<T> BlockHashRef for Box<T>
where T: BlockHashRef + ?Sized,

§

type Error = <T as BlockHashRef>::Error

source§

fn block_hash( &self, number: Uint<256, 4> ) -> Result<FixedBytes<32>, <Box<T> as BlockHashRef>::Error>

source§

impl<T> BlockHashRef for Rc<T>
where T: BlockHashRef + ?Sized,

§

type Error = <T as BlockHashRef>::Error

source§

fn block_hash( &self, number: Uint<256, 4> ) -> Result<FixedBytes<32>, <Rc<T> as BlockHashRef>::Error>

source§

impl<T> BlockHashRef for Arc<T>
where T: BlockHashRef + ?Sized,

§

type Error = <T as BlockHashRef>::Error

source§

fn block_hash( &self, number: Uint<256, 4> ) -> Result<FixedBytes<32>, <Arc<T> as BlockHashRef>::Error>

Implementors§