equal
deleted
inserted
replaced
188 (((rep - x) /: preds)(del_adjacent(false, x)) /: succs)(del_adjacent(true, x))) |
188 (((rep - x) /: preds)(del_adjacent(false, x)) /: succs)(del_adjacent(true, x))) |
189 } |
189 } |
190 |
190 |
191 def restrict(pred: Key => Boolean): Graph[Key, A] = |
191 def restrict(pred: Key => Boolean): Graph[Key, A] = |
192 (this /: iterator){ case (graph, (x, _)) => if (!pred(x)) graph.del_node(x) else graph } |
192 (this /: iterator){ case (graph, (x, _)) => if (!pred(x)) graph.del_node(x) else graph } |
|
193 |
|
194 def exclude(pred: Key => Boolean): Graph[Key, A] = restrict(name => !pred(name)) |
193 |
195 |
194 |
196 |
195 /* edge operations */ |
197 /* edge operations */ |
196 |
198 |
197 def edges_iterator: Iterator[(Key, Key)] = |
199 def edges_iterator: Iterator[(Key, Key)] = |