contractToKeptNodes

fun contractToKeptNodes(graph: Vista, keptIds: Set<String>, overKinds: Set<EdgeKind>, outKind: EdgeKind): Vista

Contracts the graph down to the keptIds code-construct set — the shared engine behind the SUMMARIZED + SOURCE_CODE / IR levels. Keeps only those views (flattened: a parentConstructId pointing at a dropped box is cleared), drops element / interface-point views (these levels are instruction-level and flat), and replaces the wire with reachability over overKinds: from each kept node, one outKind edge to the first kept node reached on each forward path (non-kept intermediates are contracted away). One arrow per reachable pair even when many concrete paths exist — which is exactly the "1 line even if multiple DAG paths" rule for the summarized data-flow view.

Generated with STIG