org.biojavax.bio.seq.io
Class UniProtCommentParser

java.lang.Object
  extended by org.biojavax.bio.seq.io.UniProtCommentParser

public class UniProtCommentParser
extends Object

Since:
1.5
Author:
Richard Holland

Nested Class Summary
static class UniProtCommentParser.Event
          A class to describe events for alternative product comments.
static class UniProtCommentParser.Interaction
          A class to describe protein-protein interactions.
static class UniProtCommentParser.Isoform
          A class to describe isoforms for alternative product comments.
static class UniProtCommentParser.SeqCaution
          A class to describe seq caution entries.
 
Field Summary
static String ALTERNATIVE_PRODUCTS
          A name for a comment type.
static String BIOPHYSICOCHEMICAL_PROPERTIES
          A name for a comment type.
static String DATABASE
          A name for a comment type.
static String INTERACTION
          A name for a comment type.
static String MASS_SPECTROMETRY
          A name for a comment type.
static String PTM
          A name for a comment type.
static String SEQUENCE_CAUTION
          A name for a comment type.
 
Constructor Summary
UniProtCommentParser()
          Creates a new instance of UniProtCommentParser.
 
Method Summary
 String generate()
          Generates a comment string based on the current values of the internal fields.
 String getAbsorptionMax()
          Getter for property absorptionMax.
 String getAbsorptionNote()
          Getter for property absorptionNote.
 String getCommentType()
          Getter for property commentType.
 String getDatabaseName()
          Getter for property databaseName.
 List getEvents()
          Getter for property events.
 List getInteractions()
          Getter for property interactions.
 List getIsoforms()
          Getter for property isoforms.
 String getKineticsNote()
          Getter for property kineticsNote.
 List getKMs()
          Getter for property KMs.
 int getMolecularWeight()
          Getter for property molecularWeight.
 Integer getMolWeightError()
          Getter for property molWeightError.
 String getMolWeightMethod()
          Getter for property molWeightMethod.
 int getMolWeightRangeEnd()
          Getter for property molWeightRangeEnd.
 int getMolWeightRangeStart()
          Getter for property molWeightRangeStart.
 String getNote()
          Getter for property note.
 String getPHDependence()
          Getter for property PHDependence.
 String getRedoxPotential()
          Getter for property redoxPotential.
 List getSeqCautions()
          Getter for property seqCautions.
 String getTemperatureDependence()
          Getter for property temperatureDependence.
 String getText()
          Getter for property text.
 String getUri()
          Getter for property uri.
 List getVMaxes()
          Getter for property VMaxes.
static boolean isParseable(Comment c)
          Returns true if the comment may be parseable (starts with -!-).
static boolean isParseable(String c)
          Returns true if the comment may be parseable (starts with -!-).
 void parseComment(Comment c)
          Parses the comment string from the given comment and populates the internal fields appropriately.
 void parseComment(String c)
          Parses the comment string from the given comment and populates the internal fields appropriately.
 void setAbsorptionMax(String absorptionMax)
          Setter for property absorptionMax.
 void setAbsorptionNote(String absorptionNote)
          Setter for property absorptionNote.
 void setCommentType(String commentType)
          Setter for property commentType.
 void setDatabaseName(String databaseName)
          Setter for property databaseName.
 void setEvents(List events)
          Setter for property events.
 void setInteractions(List interactions)
          Setter for property interactions.
 void setIsoforms(List isoforms)
          Setter for property isoforms.
 void setKineticsNote(String kineticsNote)
          Setter for property kineticsNote.
 void setKMs(List KMs)
          Setter for property KMs.
 void setMolecularWeight(int molecularWeight)
          Setter for property molecularWeight.
 void setMolWeightError(Integer molWeightError)
          Setter for property molWeightError.
 void setMolWeightMethod(String molWeightMethod)
          Setter for property molWeightMethod.
 void setMolWeightRangeEnd(int molWeightRangeEnd)
          Setter for property molWeightRangeEnd.
 void setMolWeightRangeStart(int molWeightRangeStart)
          Setter for property molWeightRangeStart.
 void setNote(String note)
          Setter for property note.
 void setPHDependence(String PHDependence)
          Setter for property PHDependence.
 void setRedoxPotential(String redoxPotential)
          Setter for property redoxPotential.
 void setSeqCautions(List seqCautions)
          Setter for property seqCautions.
 void setTemperatureDependence(String temperatureDependence)
          Setter for property temperatureDependence.
 void setText(String text)
          Setter for property text.
 void setUri(String uri)
          Setter for property uri.
 void setVMaxes(List VMaxes)
          Setter for property VMaxes.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

BIOPHYSICOCHEMICAL_PROPERTIES

public static final String BIOPHYSICOCHEMICAL_PROPERTIES
A name for a comment type.

See Also:
Constant Field Values

DATABASE

public static final String DATABASE
A name for a comment type.

See Also:
Constant Field Values

MASS_SPECTROMETRY

public static final String MASS_SPECTROMETRY
A name for a comment type.

See Also:
Constant Field Values

ALTERNATIVE_PRODUCTS

public static final String ALTERNATIVE_PRODUCTS
A name for a comment type.

See Also:
Constant Field Values

INTERACTION

public static final String INTERACTION
A name for a comment type.

See Also:
Constant Field Values

PTM

public static final String PTM
A name for a comment type.

See Also:
Constant Field Values

SEQUENCE_CAUTION

public static final String SEQUENCE_CAUTION
A name for a comment type.

See Also:
Constant Field Values
Constructor Detail

UniProtCommentParser

public UniProtCommentParser()
Creates a new instance of UniProtCommentParser.

Method Detail

parseComment

public void parseComment(Comment c)
                  throws ParseException
Parses the comment string from the given comment and populates the internal fields appropriately. If the comment is not a UniProt comment (does not start with -!-) then an exception is thrown.

Parameters:
c - the comment to parse.
Throws:
ParseException - if the comment was not parseable.

parseComment

public void parseComment(String c)
                  throws ParseException
Parses the comment string from the given comment and populates the internal fields appropriately. If the comment is not a UniProt comment (does not start with -!-) then an exception is thrown.

Parameters:
c - the comment to parse.
Throws:
ParseException - if the comment was not parseable.

isParseable

public static boolean isParseable(Comment c)
Returns true if the comment may be parseable (starts with -!-).

Parameters:
c - the comment to check.
Returns:
true if it starts with -!-, false otherwise.

isParseable

public static boolean isParseable(String c)
Returns true if the comment may be parseable (starts with -!-).

Parameters:
c - the comment to check.
Returns:
true if it starts with -!-, false otherwise.

generate

public String generate()
                throws ParseException
Generates a comment string based on the current values of the internal fields.

Returns:
the comment string representing the current settings.
Throws:
ParseException - if the current settings do not allow the creation of a correct comment string.

getCommentType

public String getCommentType()
Getter for property commentType.

Returns:
Value of property commentType.

setCommentType

public void setCommentType(String commentType)
Setter for property commentType.

Parameters:
commentType - New value of property commentType.

getText

public String getText()
Getter for property text.

Returns:
Value of property text.

setText

public void setText(String text)
Setter for property text.

Parameters:
text - New value of property text.

getDatabaseName

public String getDatabaseName()
Getter for property databaseName.

Returns:
Value of property databaseName.

setDatabaseName

public void setDatabaseName(String databaseName)
Setter for property databaseName.

Parameters:
databaseName - New value of property databaseName.

getNote

public String getNote()
Getter for property note.

Returns:
Value of property note.

setNote

public void setNote(String note)
Setter for property note.

Parameters:
note - New value of property note.

getUri

public String getUri()
Getter for property uri.

Returns:
Value of property uri.

setUri

public void setUri(String uri)
Setter for property uri.

Parameters:
uri - New value of property uri.

getMolecularWeight

public int getMolecularWeight()
Getter for property molecularWeight.

Returns:
Value of property molecularWeight.

setMolecularWeight

public void setMolecularWeight(int molecularWeight)
Setter for property molecularWeight.

Parameters:
molecularWeight - New value of property molecularWeight.

getMolWeightError

public Integer getMolWeightError()
Getter for property molWeightError.

Returns:
Value of property molWeightError.

setMolWeightError

public void setMolWeightError(Integer molWeightError)
Setter for property molWeightError.

Parameters:
molWeightError - New value of property molWeightError.

getMolWeightRangeStart

public int getMolWeightRangeStart()
Getter for property molWeightRangeStart.

Returns:
Value of property molWeightRangeStart.

setMolWeightRangeStart

public void setMolWeightRangeStart(int molWeightRangeStart)
Setter for property molWeightRangeStart.

Parameters:
molWeightRangeStart - New value of property molWeightRangeStart.

getMolWeightRangeEnd

public int getMolWeightRangeEnd()
Getter for property molWeightRangeEnd.

Returns:
Value of property molWeightRangeEnd.

setMolWeightRangeEnd

public void setMolWeightRangeEnd(int molWeightRangeEnd)
Setter for property molWeightRangeEnd.

Parameters:
molWeightRangeEnd - New value of property molWeightRangeEnd.

getMolWeightMethod

public String getMolWeightMethod()
Getter for property molWeightMethod.

Returns:
Value of property molWeightMethod.

setMolWeightMethod

public void setMolWeightMethod(String molWeightMethod)
Setter for property molWeightMethod.

Parameters:
molWeightMethod - New value of property molWeightMethod.

getInteractions

public List getInteractions()
Getter for property interactions.

Returns:
Value of property interactions.

setInteractions

public void setInteractions(List interactions)
Setter for property interactions.

Parameters:
interactions - New value of property interactions.

getSeqCautions

public List getSeqCautions()
Getter for property seqCautions.

Returns:
Value of property seqCautions.

setSeqCautions

public void setSeqCautions(List seqCautions)
Setter for property seqCautions.

Parameters:
seqCautions - New value of property seqCautions.

getEvents

public List getEvents()
Getter for property events.

Returns:
Value of property events.

setEvents

public void setEvents(List events)
Setter for property events.

Parameters:
events - New value of property events.

getIsoforms

public List getIsoforms()
Getter for property isoforms.

Returns:
Value of property isoforms.

setIsoforms

public void setIsoforms(List isoforms)
Setter for property isoforms.

Parameters:
isoforms - New value of property isoforms.

getAbsorptionMax

public String getAbsorptionMax()
Getter for property absorptionMax.

Returns:
Value of property absorptionMax.

setAbsorptionMax

public void setAbsorptionMax(String absorptionMax)
Setter for property absorptionMax.

Parameters:
absorptionMax - New value of property absorptionMax.

getAbsorptionNote

public String getAbsorptionNote()
Getter for property absorptionNote.

Returns:
Value of property absorptionNote.

setAbsorptionNote

public void setAbsorptionNote(String absorptionNote)
Setter for property absorptionNote.

Parameters:
absorptionNote - New value of property absorptionNote.

getKMs

public List getKMs()
Getter for property KMs.

Returns:
Value of property KMs.

setKMs

public void setKMs(List KMs)
Setter for property KMs.

Parameters:
KMs - New value of property KMs.

getVMaxes

public List getVMaxes()
Getter for property VMaxes.

Returns:
Value of property VMaxes.

setVMaxes

public void setVMaxes(List VMaxes)
Setter for property VMaxes.

Parameters:
VMaxes - New value of property VMaxes.

getKineticsNote

public String getKineticsNote()
Getter for property kineticsNote.

Returns:
Value of property kineticsNote.

setKineticsNote

public void setKineticsNote(String kineticsNote)
Setter for property kineticsNote.

Parameters:
kineticsNote - New value of property kineticsNote.

getPHDependence

public String getPHDependence()
Getter for property PHDependence.

Returns:
Value of property PHDependence.

setPHDependence

public void setPHDependence(String PHDependence)
Setter for property PHDependence.

Parameters:
PHDependence - New value of property PHDependence.

getRedoxPotential

public String getRedoxPotential()
Getter for property redoxPotential.

Returns:
Value of property redoxPotential.

setRedoxPotential

public void setRedoxPotential(String redoxPotential)
Setter for property redoxPotential.

Parameters:
redoxPotential - New value of property redoxPotential.

getTemperatureDependence

public String getTemperatureDependence()
Getter for property temperatureDependence.

Returns:
Value of property temperatureDependence.

setTemperatureDependence

public void setTemperatureDependence(String temperatureDependence)
Setter for property temperatureDependence.

Parameters:
temperatureDependence - New value of property temperatureDependence.