info.bioinfweb.treegraph.document.io
Class AbstractDocumentReader

java.lang.Object
  extended by info.bioinfweb.treegraph.document.io.AbstractDocumentReader
All Implemented Interfaces:
DocumentReader
Direct Known Subclasses:
TextStreamReader, TGFReader, XTGReader

public abstract class AbstractDocumentReader
extends Object
implements DocumentReader


Field Summary
protected  Document document
           
 
Constructor Summary
AbstractDocumentReader()
           
 
Method Summary
 Document read(File file)
           
 Document read(File file, NodeBranchDataAdapter internalAdapter, NodeBranchDataAdapter branchLengthsAdapter)
           
 Document read(File file, NodeBranchDataAdapter internalAdapter, NodeBranchDataAdapter branchLengthsAdapter, TreeSelector selector, boolean translateInternalNodes)
          If you want to implement file specific functionalities you should override this method.
 Document read(InputStream stream)
           
 Document read(InputStream stream, NodeBranchDataAdapter internalAdapter, NodeBranchDataAdapter branchLengthsAdapter)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface info.bioinfweb.treegraph.document.io.DocumentReader
read
 

Field Detail

document

protected Document document
Constructor Detail

AbstractDocumentReader

public AbstractDocumentReader()
Method Detail

read

public Document read(File file)
              throws Exception
Specified by:
read in interface DocumentReader
Throws:
Exception

read

public Document read(File file,
                     NodeBranchDataAdapter internalAdapter,
                     NodeBranchDataAdapter branchLengthsAdapter)
              throws Exception
Specified by:
read in interface DocumentReader
Throws:
Exception

read

public Document read(File file,
                     NodeBranchDataAdapter internalAdapter,
                     NodeBranchDataAdapter branchLengthsAdapter,
                     TreeSelector selector,
                     boolean translateInternalNodes)
              throws Exception
If you want to implement file specific functionalities you should override this method. It is called by all other read-methods with a file as parameter.

Specified by:
read in interface DocumentReader
Throws:
Exception
See Also:
info.bioinfweb.treegraph.document.io.DocumentReader#read(java.io.File, NodeBranchDataAdapter, int)

read

public Document read(InputStream stream,
                     NodeBranchDataAdapter internalAdapter,
                     NodeBranchDataAdapter branchLengthsAdapter)
              throws Exception
Specified by:
read in interface DocumentReader
Throws:
Exception

read

public Document read(InputStream stream)
              throws Exception
Specified by:
read in interface DocumentReader
Throws:
Exception