Rename self:addEdge to self:connectNodes

This commit is contained in:
Robert Machmer 2016-01-09 03:35:51 +01:00
parent 436ec9f78f
commit 732037bd04

View File

@ -95,7 +95,7 @@ function Graph.new()
-- @param origin - The node from which the edge originates.
-- @param target - The node to which the edge is pointing to.
--
function self:addEdge( origin, target )
function self:connectNodes( origin, target )
for _, edge in pairs(edges) do
if edge.origin == origin and edge.target == target then
error "Trying to connect nodes which are already connected.";