dominikbraun / graph

A library for creating generic graph data structures and modifying, analyzing, and visualizing them.
https://graph.dominikbraun.io
Apache License 2.0
1.8k stars 94 forks source link

Method for adding edges from another graph #106

Closed dominikbraun closed 1 year ago

dominikbraun commented 1 year ago

There should be a method for adding edges from another graph, for example AddEdgesFrom[K comparable, T any](source Graph[K, T]) error. Maybe accepting a []Edge[K] instead of a Graph[K, T] might make sense, too. In that case, a new method for retrieving all edges as a []Edge[K] would be necessary as well.