ccvisu
Class ReaderDataGraph

java.lang.Object
  extended byccvisu.ReaderData
      extended byccvisu.ReaderDataGraph
Direct Known Subclasses:
ReaderDataGraphCVS, ReaderDataGraphRSF

public abstract class ReaderDataGraph
extends ReaderData

Reader for input graphs. Different concrete graph readers return what they read in String format (list of edges of type GraphEdgeString) when readEdges() is called. One single transformation method (readGraph() of this class) transforms the string representation into the final format (GraphData object with edges of type GraphEdgeInt).

Version:
$Revision: 1.2 $; $Date: 2005/08/22 12:42:46 $
Author:
Dirk Beyer

Nested Class Summary
protected  class ReaderDataGraph.GraphEdgeString
          Represents a graph edge in String format.
 
Field Summary
protected static java.lang.String endl
          End of line.
 
Fields inherited from class ccvisu.ReaderData
in
 
Constructor Summary
ReaderDataGraph(java.io.BufferedReader in)
          Constructor.
 
Method Summary
 GraphData read()
          Reads the graph data from stream reader in.
protected abstract  java.util.Vector readEdges()
          Reads the edges of a graph from stream reader in, and stores them in a list (of GraphEdgeString elements).
protected  GraphData readGraph()
          Reads the graph data from list of string edges (see class comment).
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

endl

protected static final java.lang.String endl
End of line.

Constructor Detail

ReaderDataGraph

public ReaderDataGraph(java.io.BufferedReader in)
Constructor.

Parameters:
in - Stream reader object.
Method Detail

read

public GraphData read()
Reads the graph data from stream reader in.

Specified by:
read in class ReaderData
Returns:
Graph data, stored in a GraphData object.

readGraph

protected GraphData readGraph()
Reads the graph data from list of string edges (see class comment).

Returns:
Graph data, stored in a GraphData object.

readEdges

protected abstract java.util.Vector readEdges()
Reads the edges of a graph from stream reader in, and stores them in a list (of GraphEdgeString elements).

Returns:
List of string edges.