pub trait EngineRequestHandler: Send + Sync {
    type Event: Send;
    type Request;
    type Block: Block;
    // Required methods
    fn on_event(&mut self, event: FromEngine<Self::Request, Self::Block>);
    fn poll(
        &mut self,
        cx: &mut Context<'_>,
    ) -> Poll<RequestHandlerEvent<Self::Event>>;
}Expand description
A type that processes incoming requests (e.g. requests from the consensus layer, engine API, such as newPayload).
§Control flow
Requests and certain updates, such as a change in backfill sync status, are delegated to this
type via EngineRequestHandler::on_event. This type is responsible for processing the
incoming requests and advancing the chain and emit events when it is polled.
Required Associated Types§
Sourcetype Block: Block
 
type Block: Block
Type of the block sent in FromEngine::DownloadedBlocks variant.
Required Methods§
Sourcefn on_event(&mut self, event: FromEngine<Self::Request, Self::Block>)
 
fn on_event(&mut self, event: FromEngine<Self::Request, Self::Block>)
Informs the handler about an event from the EngineHandler.