Sequence Filter

std/filter/vector/u128::Filter


Inputs

value: Stream<Vec<u128>>
decision: Stream<bool>

Outputs

↦ accepted: Stream<Vec<u128>>
↦ rejected: Stream<Vec<u128>>


Filter an input Vec<u128> stream according to bool stream.

ℹ️ If both streams are not the same size nothing is sent through accepted nor rejected.

graph LR
    T("Filter()")
    V["…[🟦 🟦][🟧][🟪 🟪 🟪][🟫 🟫][🟨]…"] -->|value| T
    D["… 🟩 🟥 🟥 🟩 🟥 …"] -->|decision|T
    
    T -->|accepted| A["… [🟦 🟦][🟫 🟫]…"]
    T -->|rejected| R["… [🟧][🟪 🟪 🟪][🟨]…"]

    style V fill:#ffff,stroke:#ffff
    style D fill:#ffff,stroke:#ffff
    style A fill:#ffff,stroke:#ffff
    style R fill:#ffff,stroke:#ffff