print ""
forI (sortStrings (map showEdge es)) (\i s -> print "* e\(i): \(s)")
+"""
+Get a set of vertices that acts as break points between network branches.
+"""
+branchPoints :: Resource -> <ReadGraph> [Resource]
+branchPoints networkDiagram = runProc let
+ in
+ filter isBranchPoint vertices
+ where
+ all = if isInstanceOf networkDiagram DIA.Diagram
+ then networkDiagram # L0.ConsistsOf
+ else singleObject networkDiagram MOD.CompositeToDiagram # L0.ConsistsOf
+ vertices = filter (flip isInstanceOf DN.Vertex) all
+ isBranchPoint v = length (v # DN.HasEndVertex_Inverse) != 1 || length (v # DN.HasStartVertex_Inverse) != 1
+
"""
Get a set of the edges that are at the middle points of each span between branch points.
"""