Function bicoro::routed

source ·
pub fn routed<'a, IA, IB, O, RA, RB>(
    first: Coroutine<'a, IA, UnicastSelect<IB, O>, RA>,
    second: Coroutine<'a, IB, UnicastSelect<IA, O>, RB>
) -> Coroutine<'a, UnicastSelect<IA, IB>, O, RoutedResult<'a, IA, IB, O, RA, RB>>where
    IA: Send,
    IB: Send,
    O: Send,
    RA: Send,
    RB: Send,
Expand description

Chain and dispatch combined.

This allows first and second corotines to ‘talk to’ each other. It also allows inputs to be routed to either if needed. first and second won’t care whether inputs are fed from above or from each other. Outputs would be in a common language, e.g they must both emit the same outputs