public abstract class BioSequenceImpl extends Molecule implements Cloneable, BioSequence
Modifier and Type | Class and Description |
---|---|
class |
BioSequenceImpl.SeqFilterReader |
Modifier and Type | Field and Description |
---|---|
protected static Pattern |
GAP_PATTERN |
Constructor and Description |
---|
BioSequenceImpl() |
BioSequenceImpl(XMLNode inXML) |
add, add, addAtom, addAtoms, addAtoms, addAtoms, addElementalComposition, addElementalComposition, addElementalComposition, addKa, addKa, calculateMassFromElementalComposition, clearAttributes, clearElementalComposition, compareTo, formatMassString, getAtoms, getAttribute, getAttributeNames, getKas, getLastAtom, getPhysicalProperty, hasAttribute, hasAttributes, hashCode, isLocked, lock, massesAreUserSet, name, remove, remove, removeAttribute, setAttribute, setAverageMass, setChemicalFormula, setElementalComposition, setMonoisotopicMass, setName, setOrganicAverageMass, setPhysicalProperty
finalize, getClass, notify, notifyAll, wait, wait, wait
getAttribute, getAttributeNames, hasAttribute, instantiate, removeAttribute, setAttribute
compareTo
protected static final Pattern GAP_PATTERN
public BioSequenceImpl()
public BioSequenceImpl(XMLNode inXML)
public BioSequence setCompressionThreshold(int inNumBytes)
public BioSequenceType getType()
getType
in interface BioSequence
public BioSequenceImpl clone()
Molecule
clone
in interface BioSequence
clone
in class Molecule
public BioSequence setID(String inValue)
BioSequence
setID
in interface BioSequence
inValue
- the id to use for this sequencepublic String getID()
getID
in interface BioSequence
public BioSequence setDescription(CharSequence inValue)
setDescription
in interface BioSequence
public String getDescription()
getDescription
in interface BioSequence
public BioSequence setSequence(CharSequence inValue)
setSequence
in interface BioSequence
public BioSequence setSequence(Reader inReader) throws SeqIOException
setSequence
in interface BioSequence
SeqIOException
public String getSequence()
getSequence
in interface BioSequence
public Reader getSequenceReader()
getSequenceReader
in interface BioSequence
public Reader getSubSequenceReader(SeqLocation inSeqLocation)
getSubSequenceReader
in interface BioSequence
public InputStream getSequenceStream()
getSequenceStream
in interface BioSequence
public String getSubSequence(SeqLocation inSeqLocation)
getSubSequence
in interface BioSequence
public byte[] getMD5Checksum()
getMD5Checksum
in interface BioSequence
public byte[] getSHA1Checksum()
getSHA1Checksum
in interface BioSequence
public boolean containsGaps()
public Integer getTotalGapLength()
protected void setNumGaps(Integer inValue)
protected void setTotalGapLength(Integer inValue)
public Integer getNumGaps()
protected void countGaps()
public int length()
length
in interface BioSequence
public char residueAt(int inIndex)
residueAt
in interface BioSequence
inIndex
- the 1-based residue positionpublic void setResidueAt(int inIndex, char inResidue)
inIndex
- the 1-based residue positioninResidue
- the residue to place at the specified positionpublic XMLNode toXMLNode()
toXMLNode
in interface BioSequence
toXMLNode
in interface HfgXMLSerializable
toXMLNode
in class Molecule
protected Map<String,Integer> getComposition()
public Map<Element,Float> getElementalComposition()
getElementalComposition
in interface Matter
getElementalComposition
in class Molecule
public String getChemicalFormula()
getChemicalFormula
in interface Matter
getChemicalFormula
in class Molecule
public String getChemicalFormulaWithSubscripts()
getChemicalFormulaWithSubscripts
in class Molecule
public Double getMonoisotopicMass()
getMonoisotopicMass
in interface Matter
getMonoisotopicMass
in class Molecule
public Double getAverageMass()
getAverageMass
in interface Matter
getAverageMass
in class Molecule
public Double getOrganicAverageMass()
Zhang Z, Pan H, Chen X. 2009. Mass spectrometry for structural characterization of therapeutic antibodies. Mass Spectrom Rev 28:147-176.
getOrganicAverageMass
in interface Matter
getOrganicAverageMass
in class Molecule
public void clearCalculatedProperties()
clearCalculatedProperties
in class Molecule
public void clearElementalCompositionAndCalculatedProperties()
protected Map<Molecule,Integer> getResidueComposition()
protected Map<Molecule,Integer> getTerminiComposition()
protected Map<? extends Molecule,Integer> getXLinkComposition()
protected void recalculateElementalComposition()
protected InputStream getReverseSequenceStream()