jellyflow-runtime 0.2.0

Headless store, rules, schema, profile, and change pipeline for Jellyflow.
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
use jellyflow_core::core::{Edge, EdgeId};
use jellyflow_core::ops::GraphOp;

pub(super) fn visit_removed_edges(op: &GraphOp, mut visit: impl FnMut(EdgeId, &Edge)) -> bool {
    match op {
        GraphOp::RemoveNode { edges, .. } | GraphOp::RemovePort { edges, .. } => {
            for (id, edge) in edges {
                visit(*id, edge);
            }
            true
        }
        GraphOp::RemoveEdge { id, edge, .. } => {
            visit(*id, edge);
            true
        }
        _ => false,
    }
}