org.grinvin
Interface GraphListener
- EventListener
- GraphPanel, GraphPanel3D, GraphViewPanel, MutableGraphPanel
public interface GraphListener
extends EventListener
Listens to changes in a graph model.
Note: It is the responsibility of
the listener to keep track of the graph being listened
to. This graph is not handed to the listener as a parameter
of the various methods.
void | edgeAdded(Edge edge) - Called after an edge was added to the graph.
|
void | edgeChanged(Edge edge) - Called when the annotation of an edge changes.
|
void | edgeRemoved(Edge edge) - Called when an edge was removed from the graph.
|
void | edgeRestored(Edge edge) - Called when an edge that was previously removed
was restored to the graph.
|
void | graphChanged() - Called when the graph was changed in a major way.
|
void | vertexAdded(Vertex vertex) - Called after a vertex was added to the graph.
|
void | vertexChanged(Vertex vertex) - Called when the annotation of a vertex changes.
|
void | vertexRemoved(Vertex vertex) - Called when a vertex was removed from the graph.
|
void | vertexRestored(Vertex vertex) - Called when a vertex that was previously removed
was restored to the graph.
|
edgeAdded
public void edgeAdded(Edge edge)
Called after an edge was added to the graph.
edge
- Edge that was added to the graph.
edgeChanged
public void edgeChanged(Edge edge)
Called when the annotation of an edge changes.
edgeRemoved
public void edgeRemoved(Edge edge)
Called when an edge was removed from the graph.
edgeRestored
public void edgeRestored(Edge edge)
Called when an edge that was previously removed
was restored to the graph.
graphChanged
public void graphChanged()
Called when the graph was changed in a major way. For instance, when all
vertices and edges were removed in one go or when the graph was
reinitialized from a file.
vertexAdded
public void vertexAdded(Vertex vertex)
Called after a vertex was added to the graph.
vertex
- Vertex that was added to the graph
vertexChanged
public void vertexChanged(Vertex vertex)
Called when the annotation of a vertex changes.
vertexRemoved
public void vertexRemoved(Vertex vertex)
Called when a vertex was removed from the graph. Implies that
all edges through this vertex were also removed. These removals will
not be notified separately.
vertex
- vertex that was removed
vertexRestored
public void vertexRestored(Vertex vertex)
Called when a vertex that was previously removed
was restored to the graph.