org.graphstream.stream.file
Class FileSourceDGS

java.lang.Object
  extended by org.graphstream.stream.SourceBase
      extended by org.graphstream.stream.file.FileSourceParser
          extended by org.graphstream.stream.file.FileSourceDGS
All Implemented Interfaces:
FileSource, Source

public class FileSourceDGS
extends FileSourceParser

Class responsible for parsing files in the DGS format.

The DGS file format is especially designed for storing dynamic graph definitions into a file. More information about the DGS file format will be found on the GraphStream web site: http://graphstream-project.org/

The usual file name extension used for this format is ".dgs".

See Also:
FileSource

Nested Class Summary
 
Nested classes/interfaces inherited from class org.graphstream.stream.SourceBase
SourceBase.ElementType
 
Constructor Summary
FileSourceDGS()
           
 
Method Summary
 ParserFactory getNewParserFactory()
          Get a new parser factory.
 boolean nextStep()
          Since there is no step in DOT, this does the same action than FileSourceParser.nextEvents().
 
Methods inherited from class org.graphstream.stream.file.FileSourceParser
begin, begin, begin, begin, end, nextEvents, readAll, readAll, readAll, readAll
 
Methods inherited from class org.graphstream.stream.SourceBase
addAttributeSink, addElementSink, addSink, attributeSinks, clearAttributeSinks, clearElementSinks, clearSinks, elementSinks, removeAttributeSink, removeElementSink, removeSink, sendAttributeChangedEvent, sendAttributeChangedEvent, sendEdgeAdded, sendEdgeAdded, sendEdgeRemoved, sendEdgeRemoved, sendGraphCleared, sendGraphCleared, sendNodeAdded, sendNodeAdded, sendNodeRemoved, sendNodeRemoved, sendStepBegins, sendStepBegins
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.graphstream.stream.Source
addAttributeSink, addElementSink, addSink, clearAttributeSinks, clearElementSinks, clearSinks, removeAttributeSink, removeElementSink, removeSink
 

Constructor Detail

FileSourceDGS

public FileSourceDGS()
Method Detail

getNewParserFactory

public ParserFactory getNewParserFactory()
Description copied from class: FileSourceParser
Get a new parser factory.

Specified by:
getNewParserFactory in class FileSourceParser
Returns:
a parser factory

nextStep

public boolean nextStep()
                 throws IOException
Description copied from class: FileSourceParser
Since there is no step in DOT, this does the same action than FileSourceParser.nextEvents().

Specified by:
nextStep in interface FileSource
Overrides:
nextStep in class FileSourceParser
Returns:
true if there are still events to read, false as soon as the file is finished.
Throws:
IOException - If an I/O error occurs while reading.


Copyright © 2011. All Rights Reserved.