[][src]Trait sc_service::ServiceBuilderCommand

pub trait ServiceBuilderCommand {
    type Block: BlockT;
    type NativeDispatch: NativeExecutionDispatch + 'static;
    fn import_blocks(
        self,
        input: impl Read + Seek + Send + 'static,
        force: bool
    ) -> Pin<Box<dyn Future<Output = Result<(), Error>> + Send>>;
fn export_blocks(
        self,
        output: impl Write + 'static,
        from: NumberFor<Self::Block>,
        to: Option<NumberFor<Self::Block>>,
        json: bool
    ) -> Pin<Box<dyn Future<Output = Result<(), Error>>>>;
fn revert_chain(&self, blocks: NumberFor<Self::Block>) -> Result<(), Error>;
fn check_block(
        self,
        block: BlockId<Self::Block>
    ) -> Pin<Box<dyn Future<Output = Result<(), Error>> + Send>>; }

Implemented on ServiceBuilder. Allows running block commands, such as import/export/validate components to the builder.

Associated Types

type Block: BlockT

Block type this API operates on.

type NativeDispatch: NativeExecutionDispatch + 'static

Native execution dispatch required by some commands.

Loading content...

Required methods

fn import_blocks(
    self,
    input: impl Read + Seek + Send + 'static,
    force: bool
) -> Pin<Box<dyn Future<Output = Result<(), Error>> + Send>>

Starts the process of importing blocks.

fn export_blocks(
    self,
    output: impl Write + 'static,
    from: NumberFor<Self::Block>,
    to: Option<NumberFor<Self::Block>>,
    json: bool
) -> Pin<Box<dyn Future<Output = Result<(), Error>>>>

Performs the blocks export.

fn revert_chain(&self, blocks: NumberFor<Self::Block>) -> Result<(), Error>

Performs a revert of blocks blocks.

fn check_block(
    self,
    block: BlockId<Self::Block>
) -> Pin<Box<dyn Future<Output = Result<(), Error>> + Send>>

Re-validate known block.

Loading content...

Implementors

impl<TBl, TRtApi, TGen, TCSExt, TBackend, TExecDisp, TFchr, TSc, TImpQu, TFprb, TFpp, TExPool, TRpc, Backend> ServiceBuilderCommand for ServiceBuilder<TBl, TRtApi, TGen, TCSExt, Client<TBackend, LocalCallExecutor<TBackend, NativeExecutor<TExecDisp>>, TBl, TRtApi>, TFchr, TSc, TImpQu, TFprb, TFpp, TExPool, TRpc, Backend> where
    TBl: BlockT,
    TBackend: 'static + Backend<TBl> + Send,
    TExecDisp: 'static + NativeExecutionDispatch,
    TImpQu: 'static + ImportQueue<TBl>,
    TRtApi: 'static + Send + Sync
[src]

type Block = TBl

type NativeDispatch = TExecDisp

Loading content...