penumbra_app::app

Trait StateWriteExt

Source
pub trait StateWriteExt: StateWrite {
    // Provided methods
    fn put_chain_id(&mut self, chain_id: String) { ... }
    fn put_block_transaction<'life0, 'async_trait>(
        &'life0 mut self,
        height: u64,
        transaction: Transaction,
    ) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>
       where Self: Send + 'async_trait,
             'life0: 'async_trait { ... }
    fn put_app_params(&mut self, params: AppParameters) { ... }
}

Provided Methods§

Source

fn put_chain_id(&mut self, chain_id: String)

Sets the chain ID.

Source

fn put_block_transaction<'life0, 'async_trait>( &'life0 mut self, height: u64, transaction: Transaction, ) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>
where Self: Send + 'async_trait, 'life0: 'async_trait,

Stores the transactions that occurred during a CometBFT block. This is used to create a durable transaction log for clients to retrieve; the CometBFT get_block_by_height RPC call will only return data for blocks since the last checkpoint, so we need to store the transactions separately.

Source

fn put_app_params(&mut self, params: AppParameters)

Writes the app parameters to the state.

Each component stores its own parameters separately, so this method splits up the provided parameters structure and writes it out to each component.

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§