Struct ckb_store::data_loader_wrapper::DataLoaderWrapper
source · [−]pub struct DataLoaderWrapper<'a, T>(_);Expand description
TODO(doc): @quake
Implementations
sourceimpl<'a, T: ChainStore<'a>> DataLoaderWrapper<'a, T>
impl<'a, T: ChainStore<'a>> DataLoaderWrapper<'a, T>
Trait Implementations
sourceimpl<'a, T: ChainStore<'a>> CellDataProvider for DataLoaderWrapper<'a, T>
impl<'a, T: ChainStore<'a>> CellDataProvider for DataLoaderWrapper<'a, T>
sourcefn get_cell_data(&self, out_point: &OutPoint) -> Option<Bytes>
fn get_cell_data(&self, out_point: &OutPoint) -> Option<Bytes>
fetch cell_data from storage
sourcefn get_cell_data_hash(&self, out_point: &OutPoint) -> Option<Byte32>
fn get_cell_data_hash(&self, out_point: &OutPoint) -> Option<Byte32>
fetch cell_data_hash from storage
sourcefn load_cell_data(&self, cell: &CellMeta) -> Option<Bytes>
fn load_cell_data(&self, cell: &CellMeta) -> Option<Bytes>
load cell_data from memory, fallback to storage access
sourcefn load_cell_data_hash(&self, cell: &CellMeta) -> Option<Byte32>
fn load_cell_data_hash(&self, cell: &CellMeta) -> Option<Byte32>
load cell_data_hash from memory, fallback to storage access
sourceimpl<'a, T: ChainStore<'a>> EpochProvider for DataLoaderWrapper<'a, T>
impl<'a, T: ChainStore<'a>> EpochProvider for DataLoaderWrapper<'a, T>
sourcefn get_epoch_ext(&self, header: &HeaderView) -> Option<EpochExt>
fn get_epoch_ext(&self, header: &HeaderView) -> Option<EpochExt>
Gets corresponding EpochExt by block header
sourcefn get_block_epoch(&self, header: &HeaderView) -> Option<BlockEpoch>
fn get_block_epoch(&self, header: &HeaderView) -> Option<BlockEpoch>
Gets corresponding epoch progress information by block header
sourceimpl<'a, T: ChainStore<'a>> HeaderProvider for DataLoaderWrapper<'a, T>
impl<'a, T: ChainStore<'a>> HeaderProvider for DataLoaderWrapper<'a, T>
sourcefn get_header(&self, block_hash: &Byte32) -> Option<HeaderView>
fn get_header(&self, block_hash: &Byte32) -> Option<HeaderView>
TODO(doc): @quake
sourcefn timestamp_and_parent(&self, block_hash: &Byte32) -> (u64, u64, Byte32)
fn timestamp_and_parent(&self, block_hash: &Byte32) -> (u64, u64, Byte32)
Return timestamp and block_number of the corresponding block_hash, and hash of parent block
sourcefn block_median_time(
&self,
block_hash: &Byte32,
median_block_count: usize
) -> u64
fn block_median_time(
&self,
block_hash: &Byte32,
median_block_count: usize
) -> u64
Return past block median time, including the timestamp of the given one
Auto Trait Implementations
impl<'a, T> RefUnwindSafe for DataLoaderWrapper<'a, T> where
T: RefUnwindSafe,
impl<'a, T> Send for DataLoaderWrapper<'a, T> where
T: Sync,
impl<'a, T> Sync for DataLoaderWrapper<'a, T> where
T: Sync,
impl<'a, T> Unpin for DataLoaderWrapper<'a, T>
impl<'a, T> UnwindSafe for DataLoaderWrapper<'a, T> where
T: RefUnwindSafe,
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<T> Instrument for T
impl<T> Instrument for T
sourcefn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
sourcefn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
fn vzip(self) -> V
sourceimpl<T> WithSubscriber for T
impl<T> WithSubscriber for T
sourcefn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self> where
S: Into<Dispatch>,
fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self> where
S: Into<Dispatch>,
Attaches the provided Subscriber to this type, returning a
WithDispatch wrapper. Read more
sourcefn with_current_subscriber(self) -> WithDispatch<Self>
fn with_current_subscriber(self) -> WithDispatch<Self>
Attaches the current default Subscriber to this type, returning a
WithDispatch wrapper. Read more