Package diva.graph.toolbox
Class GraphLogger
- java.lang.Object
-
- diva.graph.toolbox.GraphLogger
-
- All Implemented Interfaces:
GraphListener,java.util.EventListener
public class GraphLogger extends java.lang.Object implements GraphListener
A logger of graph events. Every event that is sent to this logger is stored in a log which can then be printed out or otherwise analyzed.- Version:
- $Id$
- Author:
- Michael Shilman
- Pt.AcceptedRating:
- Red
-
-
Constructor Summary
Constructors Constructor Description GraphLogger()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidedgeHeadChanged(GraphEvent e)Add this event to the log.voidedgeTailChanged(GraphEvent e)Add this event to the log.java.util.Iteratoriterator()Return a sequentially-sorted iterator over the GraphEvent objects contained by the log.voidnodeAdded(GraphEvent e)Add this event to the log.voidnodeRemoved(GraphEvent e)Add this event to the log.voidstructureChanged(GraphEvent e)Add this event to the log.java.lang.StringtoString()Print the contents of the log into a string.
-
-
-
Method Detail
-
edgeHeadChanged
public void edgeHeadChanged(GraphEvent e)
Add this event to the log.- Specified by:
edgeHeadChangedin interfaceGraphListener
-
edgeTailChanged
public void edgeTailChanged(GraphEvent e)
Add this event to the log.- Specified by:
edgeTailChangedin interfaceGraphListener
-
nodeAdded
public void nodeAdded(GraphEvent e)
Add this event to the log.- Specified by:
nodeAddedin interfaceGraphListener
-
nodeRemoved
public void nodeRemoved(GraphEvent e)
Add this event to the log.- Specified by:
nodeRemovedin interfaceGraphListener
-
structureChanged
public void structureChanged(GraphEvent e)
Add this event to the log.- Specified by:
structureChangedin interfaceGraphListener
-
iterator
public java.util.Iterator iterator()
Return a sequentially-sorted iterator over the GraphEvent objects contained by the log.
-
toString
public java.lang.String toString()
Print the contents of the log into a string.- Overrides:
toStringin classjava.lang.Object
-
-