VeaR/JEllipse

pl.krakow.cmuj.bioinformatics.jellipse
Class PdbFile

java.lang.Object
  extended by pl.krakow.cmuj.bioinformatics.jellipse.PdbFile

public class PdbFile
extends java.lang.Object

String operations' implementations are dirty and require more study on regexps, although they work and are quite fast.


Field Summary
private  short ATOMNAMESTART
           
private  short ATOMNAMESTOP
           
private  short CHAINCOLUMN
           
private  java.lang.String chainsids
           
private  int chainsnum
           
private  short COLUMNWIDTH
           
private  short DISTANCETOTER
           
private  java.lang.String fileContent
           
private  java.lang.String pdbid
           
private  short RESIDUENAMESTART
           
private  short RESIDUENAMESTOP
           
private  short RESIDUENUMBERSTART
           
private  short RESIDUENUMBERSTOP
           
private  short XCOORDSTART
           
private  short XCOORDSTOP
           
private  short YCOORDSTART
           
private  short YCOORDSTOP
           
private  short ZCOORDSTART
           
private  short ZCOORDSTOP
           
 
Constructor Summary
PdbFile(java.lang.String fileContent, java.lang.String pdbid)
          Creates a new instance of PdbFile
 
Method Summary
private  void findChains()
          Searches for chains - counts them and collects their one-letter ids.
 Peptide getChain(char selectedchainid)
           
 java.lang.String getChainsIds()
          Gives chain ids (each is a one-letter).
 int getNumOfChains()
          Gives the number of chains (mainly separate polypeptides) of which crystallographic data was stored in a pdb file.
 java.lang.String getPdbId()
          Gives PDB ID in uppercase for this PdbFile object.
 java.lang.String toString()
          Enables getting whole content of the file stored in the current PdbFile object
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

COLUMNWIDTH

private final short COLUMNWIDTH
See Also:
Constant Field Values

DISTANCETOTER

private final short DISTANCETOTER
See Also:
Constant Field Values

ATOMNAMESTART

private final short ATOMNAMESTART
See Also:
Constant Field Values

ATOMNAMESTOP

private final short ATOMNAMESTOP
See Also:
Constant Field Values

RESIDUENAMESTART

private final short RESIDUENAMESTART
See Also:
Constant Field Values

RESIDUENAMESTOP

private final short RESIDUENAMESTOP
See Also:
Constant Field Values

CHAINCOLUMN

private final short CHAINCOLUMN
See Also:
Constant Field Values

RESIDUENUMBERSTART

private final short RESIDUENUMBERSTART
See Also:
Constant Field Values

RESIDUENUMBERSTOP

private final short RESIDUENUMBERSTOP
See Also:
Constant Field Values

XCOORDSTART

private final short XCOORDSTART
See Also:
Constant Field Values

XCOORDSTOP

private final short XCOORDSTOP
See Also:
Constant Field Values

YCOORDSTART

private final short YCOORDSTART
See Also:
Constant Field Values

YCOORDSTOP

private final short YCOORDSTOP
See Also:
Constant Field Values

ZCOORDSTART

private final short ZCOORDSTART
See Also:
Constant Field Values

ZCOORDSTOP

private final short ZCOORDSTOP
See Also:
Constant Field Values

pdbid

private java.lang.String pdbid

fileContent

private java.lang.String fileContent

chainsnum

private int chainsnum

chainsids

private java.lang.String chainsids
Constructor Detail

PdbFile

public PdbFile(java.lang.String fileContent,
               java.lang.String pdbid)
Creates a new instance of PdbFile

Method Detail

findChains

private void findChains()
Searches for chains - counts them and collects their one-letter ids. Modifies private values of numofchains and chainids.


getChain

public Peptide getChain(char selectedchainid)

getPdbId

public java.lang.String getPdbId()
Gives PDB ID in uppercase for this PdbFile object.

Returns:
PDB ID - a digit and three uppercased letters

getNumOfChains

public int getNumOfChains()
Gives the number of chains (mainly separate polypeptides) of which crystallographic data was stored in a pdb file.

Returns:
number of marked chains in a pdb file (that means - for the current PdbFile object)

getChainsIds

public java.lang.String getChainsIds()
Gives chain ids (each is a one-letter).

Returns:
ids of chains stored in the current pdb file as concatenated letters

toString

public java.lang.String toString()
Enables getting whole content of the file stored in the current PdbFile object

Overrides:
toString in class java.lang.Object
Returns:
plain pdb file content

VeaR/JEllipse