Type Alias moonbeam_service::lazy_loading::TLazyLoadingBackend
source · pub type TLazyLoadingBackend<TBl> = Backend<TBl>;
Expand description
Lazy loading client backend type.
Aliased Type§
struct TLazyLoadingBackend<TBl> { /* private fields */ }
Trait Implementations
source§impl<Block: BlockT + DeserializeOwned> AuxStore for Backend<Block>
impl<Block: BlockT + DeserializeOwned> AuxStore for Backend<Block>
source§fn insert_aux<'a, 'b: 'a, 'c: 'a, I: IntoIterator<Item = &'a (&'c [u8], &'c [u8])>, D: IntoIterator<Item = &'a &'b [u8]>>(
&self,
_insert: I,
_delete: D,
) -> Result<()>
fn insert_aux<'a, 'b: 'a, 'c: 'a, I: IntoIterator<Item = &'a (&'c [u8], &'c [u8])>, D: IntoIterator<Item = &'a &'b [u8]>>( &self, _insert: I, _delete: D, ) -> Result<()>
Insert auxiliary data into key-value store. Read more
source§impl<Block: BlockT + DeserializeOwned> Backend<Block> for Backend<Block>
impl<Block: BlockT + DeserializeOwned> Backend<Block> for Backend<Block>
§type BlockImportOperation = BlockImportOperation<Block>
type BlockImportOperation = BlockImportOperation<Block>
Associated block insertion operation type.
§type Blockchain = Blockchain<Block>
type Blockchain = Blockchain<Block>
Associated blockchain backend type.
§type State = ForkedLazyBackend<Block>
type State = ForkedLazyBackend<Block>
Associated state backend type.
§type OffchainStorage = InMemOffchainStorage
type OffchainStorage = InMemOffchainStorage
Offchain workers local storage.
source§fn begin_operation(&self) -> Result<Self::BlockImportOperation>
fn begin_operation(&self) -> Result<Self::BlockImportOperation>
Begin a new block insertion transaction with given parent block id. Read more
source§fn begin_state_operation(
&self,
operation: &mut Self::BlockImportOperation,
block: Block::Hash,
) -> Result<()>
fn begin_state_operation( &self, operation: &mut Self::BlockImportOperation, block: Block::Hash, ) -> Result<()>
Note an operation to contain state transition.
source§fn commit_operation(&self, operation: Self::BlockImportOperation) -> Result<()>
fn commit_operation(&self, operation: Self::BlockImportOperation) -> Result<()>
Commit block insertion.
source§fn finalize_block(
&self,
hash: Block::Hash,
justification: Option<Justification>,
) -> Result<()>
fn finalize_block( &self, hash: Block::Hash, justification: Option<Justification>, ) -> Result<()>
Finalize block with given
hash
. Read moresource§fn append_justification(
&self,
hash: Block::Hash,
justification: Justification,
) -> Result<()>
fn append_justification( &self, hash: Block::Hash, justification: Justification, ) -> Result<()>
Append justification to the block with the given
hash
. Read moresource§fn blockchain(&self) -> &Self::Blockchain
fn blockchain(&self) -> &Self::Blockchain
Returns reference to blockchain backend.
source§fn usage_info(&self) -> Option<UsageInfo>
fn usage_info(&self) -> Option<UsageInfo>
Returns current usage statistics.
source§fn offchain_storage(&self) -> Option<Self::OffchainStorage>
fn offchain_storage(&self) -> Option<Self::OffchainStorage>
Returns a handle to offchain storage.
source§fn state_at(&self, hash: Block::Hash) -> Result<Self::State>
fn state_at(&self, hash: Block::Hash) -> Result<Self::State>
Returns state backend with post-state of given block.
source§fn revert(
&self,
_n: NumberFor<Block>,
_revert_finalized: bool,
) -> Result<(NumberFor<Block>, HashSet<Block::Hash>)>
fn revert( &self, _n: NumberFor<Block>, _revert_finalized: bool, ) -> Result<(NumberFor<Block>, HashSet<Block::Hash>)>
Attempts to revert the chain by
n
blocks. If revert_finalized
is set it will attempt to
revert past any finalized block, this is unsafe and can potentially leave the node in an
inconsistent state. All blocks higher than the best block are also reverted and not counting
towards n
. Read moresource§fn remove_leaf_block(&self, _hash: Block::Hash) -> Result<()>
fn remove_leaf_block(&self, _hash: Block::Hash) -> Result<()>
Discard non-best, unfinalized leaf block.
source§fn get_import_lock(&self) -> &RwLock<()>
fn get_import_lock(&self) -> &RwLock<()>
Gain access to the import lock around this backend. Read more
source§fn requires_full_sync(&self) -> bool
fn requires_full_sync(&self) -> bool
Tells whether the backend requires full-sync mode.
source§fn pin_block(&self, hash: <Block as BlockT>::Hash) -> Result<()>
fn pin_block(&self, hash: <Block as BlockT>::Hash) -> Result<()>
Pin the block to keep body, justification and state available after pruning.
Number of pins are reference counted. Users need to make sure to perform
one call to [
Self::unpin_block
] per call to [Self::pin_block
].source§fn unpin_block(&self, hash: <Block as BlockT>::Hash)
fn unpin_block(&self, hash: <Block as BlockT>::Hash)
Unpin the block to allow pruning.
§fn have_state_at(
&self,
hash: <Block as Block>::Hash,
_number: <<Block as Block>::Header as Header>::Number,
) -> bool
fn have_state_at( &self, hash: <Block as Block>::Hash, _number: <<Block as Block>::Header as Header>::Number, ) -> bool
Returns true if state for given block is available.
§fn insert_aux<'a, 'b, 'c, I, D>(
&self,
insert: I,
delete: D,
) -> Result<(), Error>where
'b: 'a,
'c: 'a,
I: IntoIterator<Item = &'a (&'c [u8], &'c [u8])>,
D: IntoIterator<Item = &'a &'b [u8]>,
fn insert_aux<'a, 'b, 'c, I, D>(
&self,
insert: I,
delete: D,
) -> Result<(), Error>where
'b: 'a,
'c: 'a,
I: IntoIterator<Item = &'a (&'c [u8], &'c [u8])>,
D: IntoIterator<Item = &'a &'b [u8]>,
Insert auxiliary data into key-value store.