reth::providers

Trait StateWriter

Source
pub trait StateWriter {
    // Required method
    fn write_to_storage(
        &mut self,
        execution_outcome: ExecutionOutcome,
        is_value_known: OriginalValuesKnown,
    ) -> Result<(), ProviderError>;
}
Expand description

A helper trait for ExecutionOutcome to write state and receipts to storage.

Required Methods§

Source

fn write_to_storage( &mut self, execution_outcome: ExecutionOutcome, is_value_known: OriginalValuesKnown, ) -> Result<(), ProviderError>

Write the data and receipts to the database or static files if static_file_producer is Some. It should be None if there is any kind of pruning/filtering over the receipts.

Implementors§

Source§

impl<ProviderDB> StateWriter for UnifiedStorageWriter<'_, ProviderDB, StaticFileProviderRWRefMut<'_, <ProviderDB as StaticFileProviderFactory>::Primitives>>
where ProviderDB: DBProvider + StateChangeWriter + HeaderProvider + StaticFileProviderFactory, <ProviderDB as DBProvider>::Tx: DbTxMut + DbTx,