pub trait EngineMessageStreamExt<T: PayloadTypes>: Stream<Item = BeaconEngineMessage<T>> {
// Provided methods
fn skip_fcu(self, count: usize) -> EngineSkipFcu<Self>
where Self: Sized { ... }
fn maybe_skip_fcu(
self,
maybe_count: Option<usize>,
) -> Either<EngineSkipFcu<Self>, Self>
where Self: Sized { ... }
fn skip_new_payload(self, count: usize) -> EngineSkipNewPayload<Self>
where Self: Sized { ... }
fn maybe_skip_new_payload(
self,
maybe_count: Option<usize>,
) -> Either<EngineSkipNewPayload<Self>, Self>
where Self: Sized { ... }
fn store_messages(self, path: PathBuf) -> EngineStoreStream<Self>
where Self: Sized { ... }
fn maybe_store_messages(
self,
maybe_path: Option<PathBuf>,
) -> Either<EngineStoreStream<Self>, Self>
where Self: Sized { ... }
fn reorg<Provider, Evm, Validator>(
self,
provider: Provider,
evm_config: Evm,
payload_validator: Validator,
frequency: usize,
depth: Option<usize>,
) -> EngineReorg<Self, T, Provider, Evm, Validator>
where Self: Sized { ... }
fn maybe_reorg<Provider, Evm, Validator, E, F, Fut>(
self,
provider: Provider,
evm_config: Evm,
payload_validator_fn: F,
frequency: Option<usize>,
depth: Option<usize>,
) -> impl Future<Output = Result<Either<EngineReorg<Self, T, Provider, Evm, Validator>, Self>, E>> + Send
where Self: Sized + Send,
Provider: Send,
Evm: Send,
F: FnOnce() -> Fut + Send,
Fut: Future<Output = Result<Validator, E>> + Send { ... }
}Expand description
The collection of stream extensions for engine API message stream.
Provided Methods§
Sourcefn skip_fcu(self, count: usize) -> EngineSkipFcu<Self>where
Self: Sized,
fn skip_fcu(self, count: usize) -> EngineSkipFcu<Self>where
Self: Sized,
Skips the specified number of BeaconEngineMessage::ForkchoiceUpdated messages from the
engine message stream.
Sourcefn maybe_skip_fcu(
self,
maybe_count: Option<usize>,
) -> Either<EngineSkipFcu<Self>, Self>where
Self: Sized,
fn maybe_skip_fcu(
self,
maybe_count: Option<usize>,
) -> Either<EngineSkipFcu<Self>, Self>where
Self: Sized,
If the count is Some, returns the stream that skips the specified number of
BeaconEngineMessage::ForkchoiceUpdated messages. Otherwise, returns Self.
Sourcefn skip_new_payload(self, count: usize) -> EngineSkipNewPayload<Self>where
Self: Sized,
fn skip_new_payload(self, count: usize) -> EngineSkipNewPayload<Self>where
Self: Sized,
Skips the specified number of BeaconEngineMessage::NewPayload messages from the
engine message stream.
Sourcefn maybe_skip_new_payload(
self,
maybe_count: Option<usize>,
) -> Either<EngineSkipNewPayload<Self>, Self>where
Self: Sized,
fn maybe_skip_new_payload(
self,
maybe_count: Option<usize>,
) -> Either<EngineSkipNewPayload<Self>, Self>where
Self: Sized,
If the count is Some, returns the stream that skips the specified number of
BeaconEngineMessage::NewPayload messages. Otherwise, returns Self.
Sourcefn store_messages(self, path: PathBuf) -> EngineStoreStream<Self>where
Self: Sized,
fn store_messages(self, path: PathBuf) -> EngineStoreStream<Self>where
Self: Sized,
Stores engine messages at the specified location.
Sourcefn maybe_store_messages(
self,
maybe_path: Option<PathBuf>,
) -> Either<EngineStoreStream<Self>, Self>where
Self: Sized,
fn maybe_store_messages(
self,
maybe_path: Option<PathBuf>,
) -> Either<EngineStoreStream<Self>, Self>where
Self: Sized,
If the path is Some, returns the stream that stores engine messages at the specified
location. Otherwise, returns Self.
Sourcefn reorg<Provider, Evm, Validator>(
self,
provider: Provider,
evm_config: Evm,
payload_validator: Validator,
frequency: usize,
depth: Option<usize>,
) -> EngineReorg<Self, T, Provider, Evm, Validator>where
Self: Sized,
fn reorg<Provider, Evm, Validator>(
self,
provider: Provider,
evm_config: Evm,
payload_validator: Validator,
frequency: usize,
depth: Option<usize>,
) -> EngineReorg<Self, T, Provider, Evm, Validator>where
Self: Sized,
Creates reorgs with specified frequency.
Sourcefn maybe_reorg<Provider, Evm, Validator, E, F, Fut>(
self,
provider: Provider,
evm_config: Evm,
payload_validator_fn: F,
frequency: Option<usize>,
depth: Option<usize>,
) -> impl Future<Output = Result<Either<EngineReorg<Self, T, Provider, Evm, Validator>, Self>, E>> + Send
fn maybe_reorg<Provider, Evm, Validator, E, F, Fut>( self, provider: Provider, evm_config: Evm, payload_validator_fn: F, frequency: Option<usize>, depth: Option<usize>, ) -> impl Future<Output = Result<Either<EngineReorg<Self, T, Provider, Evm, Validator>, Self>, E>> + Send
If frequency is Some, returns the stream that creates reorgs with
specified frequency. Otherwise, returns Self.
The payload_validator_fn closure is only called if frequency is Some,
allowing for lazy initialization of the validator.
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".