org.biojava.bio.program.phred
Class PhredSequence
java.lang.Object
org.biojava.utils.AbstractChangeable
org.biojava.bio.seq.impl.SimpleSequence
org.biojava.bio.program.phred.PhredSequence
- All Implemented Interfaces:
- java.io.Serializable, Annotatable, Qualitative, FeatureHolder, RealizingFeatureHolder, Sequence, SymbolList, Changeable
public class PhredSequence
- extends SimpleSequence
- implements Qualitative
PhredSequence is an extension of SimpleSequence that implements
Qualitative to hold Phred quality scores.
Copyright: Copyright (c) 2001
Company: AgResearch
- Since:
- 1.1
- Author:
- Mark Schreiber
- See Also:
- Serialized Form
Method Summary |
SymbolList |
getDNA()
Extracts the DNA part of the PhredAlpahbet SymbolList and returns it as a SymbolList |
Symbol |
getDNAAt(int index)
|
SymbolList |
getQuality()
Extracts the quality part if the Phred Alphabet and returns it as a SymbolList
over the Integer SubAlphabet from 0..99. |
Symbol |
getQualityAt(int index)
Retreives the quality symbol for the specified index. |
Methods inherited from class org.biojava.bio.seq.impl.SimpleSequence |
containsFeature, countFeatures, createFeature, createFeature, edit, featureHolderAllocated, features, filter, filter, getAlphabet, getAnnotation, getChangeSupport, getFeatureHolder, getName, getSchema, getURN, iterator, length, realizeFeature, removeFeature, seqString, setName, setURN, subList, subStr, symbolAt, toList, toString |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
PhredSequence
public PhredSequence(SymbolList phredSequence,
java.lang.String name,
java.lang.String urn,
Annotation anno)
throws IllegalAlphabetException
- Constructs a new PhredSequence.
- Parameters:
phredSequence
- - a SymbolList over the Phred Alphabet.name
- - the name for the sequence.urn
- - the URN for the sequence.anno
- - the Annotation object for the sequence.
- Throws:
IllegalAlphabetException
getQuality
public SymbolList getQuality()
- Extracts the quality part if the Phred Alphabet and returns it as a SymbolList
over the Integer SubAlphabet from 0..99.
- Specified by:
getQuality
in interface Qualitative
getDNA
public SymbolList getDNA()
- Extracts the DNA part of the PhredAlpahbet SymbolList and returns it as a SymbolList
getQualityAt
public Symbol getQualityAt(int index)
throws java.lang.IndexOutOfBoundsException
- Description copied from interface:
Qualitative
- Retreives the quality symbol for the specified index.
- Specified by:
getQualityAt
in interface Qualitative
- Parameters:
index
- - Must be greater than zero.
- Throws:
java.lang.IndexOutOfBoundsException
- if index is outside of the quality symbol list.
getDNAAt
public Symbol getDNAAt(int index)
throws java.lang.IndexOutOfBoundsException
- Throws:
java.lang.IndexOutOfBoundsException