gonum/graph — pull request #8 by Jragonmiris (2014-03-23 06:47:19+00:00)
Title: Edge

I made sweeping changed incorporating a new interface that treats edges as a more important part of the graph.

Changelog:

1. New Graph, DirectedGraph, and Mutable interface (see graph.go for details)
2. Renamed concrete.GonumGraph, concrete.GonumNode, and concrete.GonumEdge to concrete.Graph concrete.Node and concrete.Edge
3. Moved search.WeightedEdge to the concrete package; concrete.Graph now uses a WeightedEdge internally to keep track of edges passed in
4. MutableGraphs are now required to keep track of user-provided edges
5. CostFunc now takes an Edge rather than a pair of nodes
6. A new function type called HeuristicCostFunc was defined that has the old CostFunc signature, this is because there is not necessarily an edge between two nodes you want the heuristic distance between
7. Fixed EdgeList in concrete.Graph to only return undirected edges.
8. The setupFuncs methods now returns EdgeTo and EdgeBetween in addition to the other functions
9. IsSuccessor, IsPredecessor, and IsNeighbor are closures generated in setupFuncs that wrap a conditional check around EdgeTo and EdgeBetween
10. The MutableGraph interface now has clearer documentation -- no more undefined behavior and methods no longer have order requirements
11. Removed a bajillion lines of code due to the new interfaces being much better