Class AbstractEdgeListener
- All Implemented Interfaces:
EventListener,EdgeListener,TransactionListener
public abstract class AbstractEdgeListener extends Object implements EdgeListener
Extend this class to create a EdgeEvent listener and override
the methods for the events of interest. (If you implement the
EdgeListener interface, you have to define all of the methods in
it. This abstract class defines null methods for them all, so
you can only have to define methods for events you care about.)
Create a listener object using the extended class and then register it with a
component using the component's addEdgeEventListener method.
When the structure of the graph is changed (e.g.: an edge is added, reversed,
an edge's source or target node changes, or an edge is removed) or a
transaction of graph structure changes is started or finished, the relevant
method in the listener object is invoked and the EdgeEvent is
passed to it.
- Version:
- $Revision: 1.4 $
- See Also:
ListenerManager,EdgeEvent
-
Constructor Summary
Constructors Constructor Description AbstractEdgeListener() -
Method Summary
Modifier and Type Method Description voidpostDirectedChanged(EdgeEvent e)Called after the edge was set directed or undirected.voidpostEdgeReversed(EdgeEvent e)Called after the edge has been reversed.voidpostSourceNodeChanged(EdgeEvent e)Called after the source node of an edge has changed.voidpostTargetNodeChanged(EdgeEvent e)Called after the target node of an edge has changed.voidpreDirectedChanged(EdgeEvent e)Called before the edge is set directed or undirected.voidpreEdgeReversed(EdgeEvent e)Called before the edge is going to be reversed.voidpreSourceNodeChanged(EdgeEvent e)Called before a change of the source node of an edge takes place.voidpreTargetNodeChanged(EdgeEvent e)Called before a change of the target node of an edge takes place.voidtransactionFinished(TransactionEvent e)Called after a transaction has been finished.voidtransactionStarted(TransactionEvent e)Called after a transaction has been started.Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.graffiti.event.TransactionListener
transactionFinished
-
Constructor Details
-
AbstractEdgeListener
public AbstractEdgeListener()
-
-
Method Details
-
postDirectedChanged
Called after the edge was set directed or undirected.- Specified by:
postDirectedChangedin interfaceEdgeListener- Parameters:
e- the EdgeEvent detailing the changes.
-
postEdgeReversed
Called after the edge has been reversed.- Specified by:
postEdgeReversedin interfaceEdgeListener- Parameters:
e- the EdgeEvent detailing the changes.
-
postSourceNodeChanged
Called after the source node of an edge has changed.- Specified by:
postSourceNodeChangedin interfaceEdgeListener- Parameters:
e- the EdgeEvent detailing the changes.
-
postTargetNodeChanged
Called after the target node of an edge has changed.- Specified by:
postTargetNodeChangedin interfaceEdgeListener- Parameters:
e- the EdgeEvent detailing the changes.
-
preDirectedChanged
Called before the edge is set directed or undirected.- Specified by:
preDirectedChangedin interfaceEdgeListener- Parameters:
e- the EdgeEvent detailing the changes.
-
preEdgeReversed
Called before the edge is going to be reversed.- Specified by:
preEdgeReversedin interfaceEdgeListener- Parameters:
e- the EdgeEvent detailing the changes.
-
preSourceNodeChanged
Called before a change of the source node of an edge takes place.- Specified by:
preSourceNodeChangedin interfaceEdgeListener- Parameters:
e- the EdgeEvent detailing the changes.
-
preTargetNodeChanged
Called before a change of the target node of an edge takes place.- Specified by:
preTargetNodeChangedin interfaceEdgeListener- Parameters:
e- the EdgeEvent detailing the changes.
-
transactionFinished
Called after a transaction has been finished.- Parameters:
e- gives details about the transaction.
-
transactionStarted
Called after a transaction has been started.- Specified by:
transactionStartedin interfaceTransactionListener- Parameters:
e- gives details about the transaction.
-