org.biomage.BioSequence
Class BioSequence

java.lang.Object
  extended by org.biomage.Common.Extendable
      extended by org.biomage.Common.Describable
          extended by org.biomage.Common.Identifiable
              extended by org.biomage.BioSequence.BioSequence
All Implemented Interfaces:
SecuredElementItf, java.io.Serializable, HasAuditTrail, HasDescriptions, HasOntologyEntries, HasPolymerType, HasPropertySets, HasSecurity, HasSeqFeatures, HasSequenceDatabases, HasSpecies, HasType

public class BioSequence
extends Identifiable
implements java.io.Serializable, HasSequenceDatabases, HasOntologyEntries, HasPolymerType, HasType, HasSpecies, HasSeqFeatures

A BioSequence is a representation of a DNA, RNA, or protein sequence. It can be represented by a Clone, Gene, or the sequence.

See Also:
Serialized Form

Nested Class Summary
 
Nested classes/interfaces inherited from interface org.biomage.Interface.HasSequenceDatabases
HasSequenceDatabases.SequenceDatabases_list
 
Nested classes/interfaces inherited from interface org.biomage.Interface.HasOntologyEntries
HasOntologyEntries.OntologyEntries_list
 
Nested classes/interfaces inherited from interface org.biomage.Interface.HasSeqFeatures
HasSeqFeatures.SeqFeatures_list
 
Nested classes/interfaces inherited from interface org.biomage.Interface.HasAuditTrail
HasAuditTrail.AuditTrail_list
 
Nested classes/interfaces inherited from interface org.biomage.Interface.HasDescriptions
HasDescriptions.Descriptions_list
 
Nested classes/interfaces inherited from interface org.biomage.Interface.HasPropertySets
HasPropertySets.PropertySets_list
 
Field Summary
protected  OntologyEntry polymerType
          A choice of protein, RNA, or DNA.
protected  OntologyEntry species
          The organism from which this sequence was obtained.
protected  OntologyEntry type
          The type of biosequence, i.e.
 
Fields inherited from class org.biomage.Common.Describable
security
 
Fields inherited from class org.biomage.Common.Extendable
editable, id, securedElementId
 
Constructor Summary
BioSequence()
          Default constructor.
BioSequence(org.xml.sax.Attributes atts)
          Attribute constructor.
 
Method Summary
 void addToOntologyEntries(int position, OntologyEntry ontologyEntry)
          Method to add OntologyEntry at position to OntologyEntries_list
 void addToOntologyEntries(OntologyEntry ontologyEntry)
          Method to add OntologyEntry to OntologyEntries_list
 void addToSeqFeatures(int position, SeqFeature seqFeature)
          Method to add SeqFeature at position to SeqFeatures_list
 void addToSeqFeatures(SeqFeature seqFeature)
          Method to add SeqFeature to SeqFeatures_list
 void addToSequenceDatabases(DatabaseEntry databaseEntry)
          Method to add DatabaseEntry to SequenceDatabases_list
 void addToSequenceDatabases(int position, DatabaseEntry databaseEntry)
          Method to add DatabaseEntry at position to SequenceDatabases_list
 boolean emptyMAGEobject()
           
 OntologyEntry getFromOntologyEntries(int position)
          Method to get OntologyEntry from OntologyEntries_list
 SeqFeature getFromSeqFeatures(int position)
          Method to get SeqFeature from SeqFeatures_list
 DatabaseEntry getFromSequenceDatabases(int position)
          Method to get DatabaseEntry from SequenceDatabases_list
 java.lang.Boolean getIsApproximateLength()
          Get method for isApproximateLength
 java.lang.Boolean getIsCircular()
          Get method for isCircular
 java.lang.Integer getLength()
          Get method for length
 java.lang.String getModelClassName()
           
 HasOntologyEntries.OntologyEntries_list getOntologyEntries()
          Get method for ontologyEntries
 OntologyEntry getPolymerType()
          Get method for polymerType
 HasSeqFeatures.SeqFeatures_list getSeqFeatures()
          Get method for seqFeatures
 java.lang.String getSequence()
          Get method for sequence
 HasSequenceDatabases.SequenceDatabases_list getSequenceDatabases()
          Get method for sequenceDatabases
 OntologyEntry getSpecies()
          Get method for species
 OntologyEntry getType()
          Get method for type
 void removeElementAtFromOntologyEntries(int position)
          Method to remove by position from OntologyEntries_list
 void removeElementAtFromSeqFeatures(int position)
          Method to remove by position from SeqFeatures_list
 void removeElementAtFromSequenceDatabases(int position)
          Method to remove by position from SequenceDatabases_list
 void removeFromOntologyEntries(OntologyEntry ontologyEntry)
          Method to remove first OntologyEntry from OntologyEntries_list
 void removeFromSeqFeatures(SeqFeature seqFeature)
          Method to remove first SeqFeature from SeqFeatures_list
 void removeFromSequenceDatabases(DatabaseEntry databaseEntry)
          Method to remove first DatabaseEntry from SequenceDatabases_list
 void setAttributes(org.xml.sax.Attributes atts)
           
 void setIsApproximateLength(java.lang.Boolean isApproximateLength)
          Set method for isApproximateLength
 void setIsCircular(java.lang.Boolean isCircular)
          Set method for isCircular
 void setLength(java.lang.Integer length)
          Set method for length
 void setOntologyEntries(HasOntologyEntries.OntologyEntries_list ontologyEntries)
          Set method for ontologyEntries
 void setPolymerType(OntologyEntry polymerType)
          Set method for polymerType
 void setSeqFeatures(HasSeqFeatures.SeqFeatures_list seqFeatures)
          Set method for seqFeatures
 void setSequence(java.lang.String sequence)
          Set method for sequence
 void setSequenceDatabases(HasSequenceDatabases.SequenceDatabases_list sequenceDatabases)
          Set method for sequenceDatabases
 void setSpecies(OntologyEntry species)
          Set method for species
 void setType(OntologyEntry type)
          Set method for type
 void writeAssociations(java.io.Writer out)
          writeAssociations This method is responsible for assembling the association data into XML.
 void writeAttributes(java.io.Writer out)
          writeAttributes This method is responsible for assembling the attribute data into XML.
 void writeMAGEML(java.io.Writer out)
          writeMAGEML This method is responsible for assembling the attribute and association data into XML.
 
Methods inherited from class org.biomage.Common.Identifiable
getIdentifier, getName, setIdentifier, setName, toString
 
Methods inherited from class org.biomage.Common.Describable
addToAuditTrail, addToAuditTrail, addToDescriptions, addToDescriptions, getAuditTrail, getDescriptions, getFromAuditTrail, getFromDescriptions, getSecurity, removeElementAtFromAuditTrail, removeElementAtFromDescriptions, removeFromAuditTrail, removeFromDescriptions, setAuditTrail, setDescriptions, setSecurity
 
Methods inherited from class org.biomage.Common.Extendable
addToPropertySets, addToPropertySets, equals, getFromPropertySets, getId, getIsEditable, getPropertySets, getSecuredElementId, isEditable, removeElementAtFromPropertySets, removeFromPropertySets, setId, setIsEditable, setPropertySets, setSecuredElementId
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

polymerType

protected OntologyEntry polymerType
A choice of protein, RNA, or DNA.


type

protected OntologyEntry type
The type of biosequence, i.e. gene, exon, UniGene cluster, fragment, BAC, EST, etc.


species

protected OntologyEntry species
The organism from which this sequence was obtained.

Constructor Detail

BioSequence

public BioSequence()
Default constructor.


BioSequence

public BioSequence(org.xml.sax.Attributes atts)
Attribute constructor. Looks up the attributes in the parameter and casts them from strings appropriately

Parameters:
atts: - the attribute list.
Method Detail

setAttributes

public void setAttributes(org.xml.sax.Attributes atts)
Overrides:
setAttributes in class Identifiable

writeMAGEML

public void writeMAGEML(java.io.Writer out)
                 throws java.io.IOException
writeMAGEML This method is responsible for assembling the attribute and association data into XML. It creates the object tag and then calls the writeAttributes and writeAssociation methods.

Overrides:
writeMAGEML in class Identifiable
Throws:
java.io.IOException

emptyMAGEobject

public boolean emptyMAGEobject()

writeAttributes

public void writeAttributes(java.io.Writer out)
                     throws java.io.IOException
writeAttributes This method is responsible for assembling the attribute data into XML. It calls the super method to write out all attributes of this class and it's ancestors.

Overrides:
writeAttributes in class Identifiable
Throws:
java.io.IOException

writeAssociations

public void writeAssociations(java.io.Writer out)
                       throws java.io.IOException
writeAssociations This method is responsible for assembling the association data into XML. It calls the super method to write out all associations of this class's ancestors.

Overrides:
writeAssociations in class Identifiable
Throws:
java.io.IOException

setLength

public void setLength(java.lang.Integer length)
Set method for length

Parameters:
value - to set

getLength

public java.lang.Integer getLength()
Get method for length

Returns:
value of the attribute

setIsApproximateLength

public void setIsApproximateLength(java.lang.Boolean isApproximateLength)
Set method for isApproximateLength

Parameters:
value - to set

getIsApproximateLength

public java.lang.Boolean getIsApproximateLength()
Get method for isApproximateLength

Returns:
value of the attribute

setIsCircular

public void setIsCircular(java.lang.Boolean isCircular)
Set method for isCircular

Parameters:
value - to set

getIsCircular

public java.lang.Boolean getIsCircular()
Get method for isCircular

Returns:
value of the attribute

setSequence

public void setSequence(java.lang.String sequence)
Set method for sequence

Parameters:
value - to set

getSequence

public java.lang.String getSequence()
Get method for sequence

Returns:
value of the attribute

getModelClassName

public java.lang.String getModelClassName()
Overrides:
getModelClassName in class Identifiable

setSequenceDatabases

public void setSequenceDatabases(HasSequenceDatabases.SequenceDatabases_list sequenceDatabases)
Set method for sequenceDatabases

Specified by:
setSequenceDatabases in interface HasSequenceDatabases
Parameters:
value - to set

getSequenceDatabases

public HasSequenceDatabases.SequenceDatabases_list getSequenceDatabases()
Get method for sequenceDatabases

Specified by:
getSequenceDatabases in interface HasSequenceDatabases
Returns:
value of the attribute

addToSequenceDatabases

public void addToSequenceDatabases(DatabaseEntry databaseEntry)
Method to add DatabaseEntry to SequenceDatabases_list

Specified by:
addToSequenceDatabases in interface HasSequenceDatabases

addToSequenceDatabases

public void addToSequenceDatabases(int position,
                                   DatabaseEntry databaseEntry)
Method to add DatabaseEntry at position to SequenceDatabases_list

Specified by:
addToSequenceDatabases in interface HasSequenceDatabases

getFromSequenceDatabases

public DatabaseEntry getFromSequenceDatabases(int position)
Method to get DatabaseEntry from SequenceDatabases_list

Specified by:
getFromSequenceDatabases in interface HasSequenceDatabases

removeElementAtFromSequenceDatabases

public void removeElementAtFromSequenceDatabases(int position)
Method to remove by position from SequenceDatabases_list

Specified by:
removeElementAtFromSequenceDatabases in interface HasSequenceDatabases

removeFromSequenceDatabases

public void removeFromSequenceDatabases(DatabaseEntry databaseEntry)
Method to remove first DatabaseEntry from SequenceDatabases_list

Specified by:
removeFromSequenceDatabases in interface HasSequenceDatabases

setOntologyEntries

public void setOntologyEntries(HasOntologyEntries.OntologyEntries_list ontologyEntries)
Set method for ontologyEntries

Specified by:
setOntologyEntries in interface HasOntologyEntries
Parameters:
value - to set

getOntologyEntries

public HasOntologyEntries.OntologyEntries_list getOntologyEntries()
Get method for ontologyEntries

Specified by:
getOntologyEntries in interface HasOntologyEntries
Returns:
value of the attribute

addToOntologyEntries

public void addToOntologyEntries(OntologyEntry ontologyEntry)
Method to add OntologyEntry to OntologyEntries_list

Specified by:
addToOntologyEntries in interface HasOntologyEntries

addToOntologyEntries

public void addToOntologyEntries(int position,
                                 OntologyEntry ontologyEntry)
Method to add OntologyEntry at position to OntologyEntries_list

Specified by:
addToOntologyEntries in interface HasOntologyEntries

getFromOntologyEntries

public OntologyEntry getFromOntologyEntries(int position)
Method to get OntologyEntry from OntologyEntries_list

Specified by:
getFromOntologyEntries in interface HasOntologyEntries

removeElementAtFromOntologyEntries

public void removeElementAtFromOntologyEntries(int position)
Method to remove by position from OntologyEntries_list

Specified by:
removeElementAtFromOntologyEntries in interface HasOntologyEntries

removeFromOntologyEntries

public void removeFromOntologyEntries(OntologyEntry ontologyEntry)
Method to remove first OntologyEntry from OntologyEntries_list

Specified by:
removeFromOntologyEntries in interface HasOntologyEntries

setPolymerType

public void setPolymerType(OntologyEntry polymerType)
Set method for polymerType

Specified by:
setPolymerType in interface HasPolymerType
Parameters:
value - to set

getPolymerType

public OntologyEntry getPolymerType()
Get method for polymerType

Specified by:
getPolymerType in interface HasPolymerType
Returns:
value of the attribute

setType

public void setType(OntologyEntry type)
Set method for type

Specified by:
setType in interface HasType
Parameters:
value - to set

getType

public OntologyEntry getType()
Get method for type

Specified by:
getType in interface HasType
Returns:
value of the attribute

setSpecies

public void setSpecies(OntologyEntry species)
Set method for species

Specified by:
setSpecies in interface HasSpecies
Parameters:
value - to set

getSpecies

public OntologyEntry getSpecies()
Get method for species

Specified by:
getSpecies in interface HasSpecies
Returns:
value of the attribute

setSeqFeatures

public void setSeqFeatures(HasSeqFeatures.SeqFeatures_list seqFeatures)
Set method for seqFeatures

Specified by:
setSeqFeatures in interface HasSeqFeatures
Parameters:
value - to set

getSeqFeatures

public HasSeqFeatures.SeqFeatures_list getSeqFeatures()
Get method for seqFeatures

Specified by:
getSeqFeatures in interface HasSeqFeatures
Returns:
value of the attribute

addToSeqFeatures

public void addToSeqFeatures(SeqFeature seqFeature)
Method to add SeqFeature to SeqFeatures_list

Specified by:
addToSeqFeatures in interface HasSeqFeatures

addToSeqFeatures

public void addToSeqFeatures(int position,
                             SeqFeature seqFeature)
Method to add SeqFeature at position to SeqFeatures_list

Specified by:
addToSeqFeatures in interface HasSeqFeatures

getFromSeqFeatures

public SeqFeature getFromSeqFeatures(int position)
Method to get SeqFeature from SeqFeatures_list

Specified by:
getFromSeqFeatures in interface HasSeqFeatures

removeElementAtFromSeqFeatures

public void removeElementAtFromSeqFeatures(int position)
Method to remove by position from SeqFeatures_list

Specified by:
removeElementAtFromSeqFeatures in interface HasSeqFeatures

removeFromSeqFeatures

public void removeFromSeqFeatures(SeqFeature seqFeature)
Method to remove first SeqFeature from SeqFeatures_list

Specified by:
removeFromSeqFeatures in interface HasSeqFeatures