Trait ExecutableTxTuple
pub trait ExecutableTxTuple: 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> + IntoIterator<Item = Self::RawTx> + Send + 'static
where <Self::IntoIter as IntoParallelIterator>::Iter: IndexedParallelIterator;
type Convert: ConvertTx<Self::RawTx, Tx = Self::Tx, Error = Self::Error>;
// Required method
fn into_parts(self) -> (Self::IntoIter, Self::Convert);
}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§
Required Methods§
Implementations on Foreign Types§
Source§impl<A, B> ExecutableTxTuple for Either<A, B>
impl<A, B> ExecutableTxTuple for Either<A, B>
type RawTx = Either<<A as ExecutableTxTuple>::RawTx, <B as ExecutableTxTuple>::RawTx>
type Tx = Either<<A as ExecutableTxTuple>::Tx, <B as ExecutableTxTuple>::Tx>
type Error = Either<<A as ExecutableTxTuple>::Error, <B as ExecutableTxTuple>::Error>
type IntoIter = EitherIter<<A as ExecutableTxTuple>::IntoIter, <B as ExecutableTxTuple>::IntoIter>
type Convert = Either<<A as ExecutableTxTuple>::Convert, <B as ExecutableTxTuple>::Convert>
fn into_parts( self, ) -> (<Either<A, B> as ExecutableTxTuple>::IntoIter, <Either<A, B> as ExecutableTxTuple>::Convert)
Source§impl<RawTx, Tx, Err, I, F> ExecutableTxTuple for (I, F)
where
RawTx: Send + Sync + 'static,
Tx: Clone + Send + Sync + 'static,
Err: Error + Send + Sync + 'static,
I: IntoParallelIterator<Item = RawTx> + IntoIterator<Item = RawTx> + Send + 'static,
<I as IntoParallelIterator>::Iter: IndexedParallelIterator,
F: Fn(RawTx) -> Result<Tx, Err> + Send + Sync + 'static,
impl<RawTx, Tx, Err, I, F> ExecutableTxTuple for (I, F)
where RawTx: Send + Sync + 'static, Tx: Clone + Send + Sync + 'static, Err: Error + Send + Sync + 'static, I: IntoParallelIterator<Item = RawTx> + IntoIterator<Item = RawTx> + Send + 'static, <I as IntoParallelIterator>::Iter: IndexedParallelIterator, F: Fn(RawTx) -> Result<Tx, Err> + Send + Sync + 'static,