Join GitHub today
GitHub is home to over 20 million developers working together to host and review code, manage projects, and build software together.
Add ability to rename vertices and edges #8
As more automated names get created, we may want to be able to rename the unique identifier known as the name of our vertices and edges.
graph = Graph.new graph.add_vertex "MyVertex" graph.change_vertex_name "MyVertex", "MyNewName" graph.has_vertex? "MyNewName" # => true
Note that the name has to be unique with the other names and the old name must be able to be reused.