public interface MutableGraph<V extends Vertex,E extends Edge> extends Graph<V,E>
| Modifier and Type | Method and Description |
|---|---|
void |
addEdge(E edge)
Adds the specified edge to this graph.
|
void |
addVertex(V vertex)
Adds the specified vertex to this graph.
|
void |
removeEdge(E edge)
Removes the specified edge from the graph.
|
void |
removeVertex(V vertex)
Removes the specified vertex from the graph.
|
Graph<V,E> |
toImmutable()
Returns an immutable copy of this graph.
|
getEdges, getEdgesFrom, getEdgesTo, getVertexesvoid addVertex(V vertex)
vertex - new vertexvoid removeVertex(V vertex)
vertex - vertex to be removedvoid addEdge(E edge)
edge - new edgevoid removeEdge(E edge)
edge - edge to be removed