|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.proteinshader.structure.io.PDBLineParser
public class PDBLineParser
Parses a line from a PDB file and adds it to a Structure.
The line must be from a structure entry for a '.pdb' file formated
according to the
PDB Contents Guide (Version 2.2, 20 Dec 1996). The record name
in the first 6 characters of the line will be used to determine what
CategoryEnum and RecordEnum the line belongs to, so the appropriate
information can be added to the Structure object that was given as an
argument to the constructor.
Field Summary | |
---|---|
static VisibilityEnum |
ATOM_VISIBILITY
The default visibilty for Atoms. |
static VisibilityEnum |
BOND_VISIBILITY
The default visibilty for Bonds. |
static String |
DEFAULT_CHAIN_ID
Default chainID to use if the chainID field of a record is blank. |
static String |
DEFAULT_MODEL_ID
Default modelID to use if there is only one unnamed model. |
static int |
MIN_CHAR_PER_LINE
The minimum number of columns in a line from a PDB file. |
Constructor Summary | |
---|---|
PDBLineParser(Structure structure)
Constructs a PDBLineParser for the Structure given as an argument. |
Method Summary | |
---|---|
List<String> |
getBadLines()
Returns a list with all bad lines that were found by parseLine(). |
void |
parseLine(String line,
int lineNumber)
Verifies that the line is a valid PDB record before adding it's data to the Structure. |
void |
processSecondaryStructures()
Any Helix and BetaStrand records that were found while parsing lines will now be added to the Structure. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final String DEFAULT_MODEL_ID
public static final String DEFAULT_CHAIN_ID
public static final int MIN_CHAR_PER_LINE
public static final VisibilityEnum ATOM_VISIBILITY
public static final VisibilityEnum BOND_VISIBILITY
Constructor Detail |
---|
public PDBLineParser(Structure structure)
structure
- the Structure that readLine() will add data to.
NullPointerException
- if structure is null.Method Detail |
---|
public void parseLine(String line, int lineNumber) throws StructureReaderException
line
- the line to get a record from.lineNumber
- - the line's number in the file.
StructureReaderException
- if a serious error occurs.public void processSecondaryStructures()
public List<String> getBadLines()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |