Finished event to subgraph conversion.

Wrote expander pattern for custom rules.
This commit is contained in:
Jay
2026-03-03 12:54:36 -05:00
parent e734fc77ed
commit 96f1ceb362
4 changed files with 173 additions and 2 deletions

View File

@@ -199,6 +199,16 @@ func (s *Subgraph) Rels() []*Relationship {
return s.rels
}
func (s *Subgraph) NodesByLabel(label string) []*Node {
nodes := []*Node{}
for _, node := range s.nodes {
if node.Labels.Contains(label) {
nodes = append(nodes, node)
}
}
return nodes
}
// ========================================
// Structured Subgraph
// ========================================