org.apache.maven.diagrams.connector_api
Class GraphBuilderListener

java.lang.Object
  extended by org.apache.maven.diagrams.connector_api.GraphBuilderListener
All Implemented Interfaces:
GraphListener

public class GraphBuilderListener
extends java.lang.Object
implements GraphListener

Example/simple implementation of GraphListener thats just builds the graph from the events.

Author:
Piotr Tabor

Constructor Summary
GraphBuilderListener()
           
 
Method Summary
 void addEdge(org.apache.maven.diagrams.graph_api.Edge edge)
           
 void addNode(org.apache.maven.diagrams.graph_api.Node node)
           
 void delEdge(org.apache.maven.diagrams.graph_api.Node node)
           
 void delNode(org.apache.maven.diagrams.graph_api.Node node)
           
 void finish()
          Marks that the graph is finished (no more changes are allowed)
 org.apache.maven.diagrams.graph_api.Graph getGraph()
          Returns the current (builded) graph.
 void init(org.apache.maven.diagrams.graph_api.GraphMetadata metadata)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

GraphBuilderListener

public GraphBuilderListener()
Method Detail

addEdge

public void addEdge(org.apache.maven.diagrams.graph_api.Edge edge)
Specified by:
addEdge in interface GraphListener

addNode

public void addNode(org.apache.maven.diagrams.graph_api.Node node)
Specified by:
addNode in interface GraphListener

finish

public void finish()
Description copied from interface: GraphListener
Marks that the graph is finished (no more changes are allowed)

Specified by:
finish in interface GraphListener

init

public void init(org.apache.maven.diagrams.graph_api.GraphMetadata metadata)
Specified by:
init in interface GraphListener

getGraph

public org.apache.maven.diagrams.graph_api.Graph getGraph()
Returns the current (builded) graph.


delEdge

public void delEdge(org.apache.maven.diagrams.graph_api.Node node)
Specified by:
delEdge in interface GraphListener

delNode

public void delNode(org.apache.maven.diagrams.graph_api.Node node)
Specified by:
delNode in interface GraphListener


Copyright © 2002-2009 Apache Software Foundation. All Rights Reserved.