org.biojava.bio.structure.io
Class PDBFileReader

java.lang.Object
  extended byorg.biojava.bio.structure.io.PDBFileReader
All Implemented Interfaces:
StructureIO, StructureIOFile
Direct Known Subclasses:
PDBSRSReader

public class PDBFileReader
extends Object
implements StructureIOFile

A PDB file parser.


Constructor Summary
PDBFileReader()
           
 
Method Summary
 void addExtension(String s)
          define supported file extensions compressed extensions .Z,.gz do not need to be specified they are dealt with automatically.
 String getId()
           
 String getPath()
           
 Structure getStructure()
          load a structure from local file system and return a PDBStructure object requires pdb_code to be set earlier...
 Structure getStructure(String filename)
          open filename (does not support compressed files!) and returns a PDBStructure object
protected  String getTimeStamp()
           
 Structure parsePDBFile(BufferedReader buf)
           
 Structure parsePDBFile(InputStream inStream)
          parse a PDB file and return a datastructure implementing PDBStructure interface.
 void setId(String id)
           
 void setPath(String p)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

PDBFileReader

public PDBFileReader()
Method Detail

setId

public void setId(String id)
Specified by:
setId in interface StructureIO

getId

public String getId()
Specified by:
getId in interface StructureIO

setPath

public void setPath(String p)
Specified by:
setPath in interface StructureIOFile

getPath

public String getPath()

addExtension

public void addExtension(String s)
define supported file extensions compressed extensions .Z,.gz do not need to be specified they are dealt with automatically.

Specified by:
addExtension in interface StructureIOFile

getTimeStamp

protected String getTimeStamp()

parsePDBFile

public Structure parsePDBFile(InputStream inStream)
                       throws IOException,
                              PDBParseException
parse a PDB file and return a datastructure implementing PDBStructure interface.

Throws:
IOException
PDBParseException

parsePDBFile

public Structure parsePDBFile(BufferedReader buf)
                       throws IOException,
                              PDBParseException
Throws:
IOException
PDBParseException

getStructure

public Structure getStructure()
                       throws IOException
load a structure from local file system and return a PDBStructure object requires pdb_code to be set earlier...

Specified by:
getStructure in interface StructureIO
Throws:
IOException

getStructure

public Structure getStructure(String filename)
                       throws IOException
open filename (does not support compressed files!) and returns a PDBStructure object

Specified by:
getStructure in interface StructureIO
Throws:
IOException