pub trait PreprocessingBundler<C: Curve>: Send {
// Required method
fn fetch_for(
&mut self,
circuit: &Circuit<C>,
) -> CerberusPreprocessingIterator<C>;
}Expand description
Bundles all preprocessing sources for an MPC protocol session.
Implementations are responsible for fetching all preprocessing required for a circuit
concurrently and packaging the results into a CerberusPreprocessingIterator. Because
each implementation owns its sources as disjoint struct fields, it can issue all network
requests in a single try_join! and return after a single await, rather than making
one sequential round-trip per source type.
Required Methods§
Sourcefn fetch_for(
&mut self,
circuit: &Circuit<C>,
) -> CerberusPreprocessingIterator<C>
fn fetch_for( &mut self, circuit: &Circuit<C>, ) -> CerberusPreprocessingIterator<C>
Fetches all preprocessing required by circuit and returns a ready-to-use iterator.
Implementations should issue all source requests concurrently (e.g. via
tokio::try_join!) so that this resolves after a single network barrier rather
than N sequential ones.