pub trait ExecutableTxTuple:
Into<(Self::IntoIter, Self::Convert)>
+ Send
+ 'static {
type RawTx: Send + Sync + 'static;
type Tx: Clone + Send + Sync + 'static;
type Error: Error + Send + Sync + 'static;
type IntoIter: IntoParallelIterator<Item = Self::RawTx, Iter: IndexedParallelIterator> + Send + 'static;
type Convert: Fn(Self::RawTx) -> Result<Self::Tx, Self::Error> + Send + Sync + 'static;
}Available on crate feature
std only.Expand description
A helper trait representing a pair of a “raw” transactions iterator and a closure that can be used to convert them to an executable transaction. This tuple is used in the engine to parallelize heavy work like decoding or recovery.
Required Associated Types§
Sourcetype RawTx: Send + Sync + 'static
type RawTx: Send + Sync + 'static
Raw transaction that can be converted to an ExecutableTxTuple::Tx
This can be any type that can be converted to an ExecutableTxTuple::Tx. For example,
an unrecovered transaction or just the transaction bytes.
Sourcetype Error: Error + Send + Sync + 'static
type Error: Error + Send + Sync + 'static
Errors that may occur while recovering or decoding transactions.
Sourcetype IntoIter: IntoParallelIterator<Item = Self::RawTx, Iter: IndexedParallelIterator> + Send + 'static
type IntoIter: IntoParallelIterator<Item = Self::RawTx, Iter: IndexedParallelIterator> + Send + 'static
Iterator over ExecutableTxTuple::Tx.
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.