Class DNAToRNATranslator
java.lang.Object
org.biojava.nbio.core.sequence.template.AbstractCompoundTranslator<NucleotideCompound,NucleotideCompound>
org.biojava.nbio.core.sequence.transcription.DNAToRNATranslator
- All Implemented Interfaces:
CompoundTranslator<NucleotideCompound,NucleotideCompound>
public class DNAToRNATranslator
extends AbstractCompoundTranslator<NucleotideCompound,NucleotideCompound>
Performs the first stage of transcription by going from DNA to RNA. This
class will first delegate to
Frame in order to be in the correctly
specified translation frame and then translates T to U. The other
translation carried out is to convert an equivalent compound in DNA to RNA
i.e. for the base A in DNA fetching the equivalent A base in the RNA
CompoundSet.- Author:
- ayates
-
Constructor Summary
ConstructorsConstructorDescriptionDNAToRNATranslator(SequenceCreatorInterface<NucleotideCompound> rnaCreator, CompoundSet<NucleotideCompound> dna, CompoundSet<NucleotideCompound> rna, boolean shortCutTranslation) -
Method Summary
Modifier and TypeMethodDescriptioncreateSequence(Sequence<NucleotideCompound> originalSequence) createSequence(Sequence<NucleotideCompound> originalSequence, Frame frame) createSequences(Sequence<NucleotideCompound> originalSequence) Overloaded local version which delegates to an optional translator when told to (specified during construction).protected voidpostProcessCompoundLists(List<List<NucleotideCompound>> compoundLists) protected RNASequenceTakes in the given DNA Sequence and returns an instance of RNASequence which is usingRnaSequenceViewas aProxySequenceReader.Methods inherited from class org.biojava.nbio.core.sequence.template.AbstractCompoundTranslator
addCompounds, addCompoundsToList, addCompoundToLists, addStrings, getCreator, getFromCompoundSet, getToCompoundSet, translate, translateMany, workingListToSequences
-
Constructor Details
-
DNAToRNATranslator
public DNAToRNATranslator(SequenceCreatorInterface<NucleotideCompound> rnaCreator, CompoundSet<NucleotideCompound> dna, CompoundSet<NucleotideCompound> rna, boolean shortCutTranslation)
-
-
Method Details
-
createSequences
public List<Sequence<NucleotideCompound>> createSequences(Sequence<NucleotideCompound> originalSequence) Overloaded local version which delegates to an optional translator when told to (specified during construction).- Specified by:
createSequencesin interfaceCompoundTranslator<NucleotideCompound,NucleotideCompound> - Overrides:
createSequencesin classAbstractCompoundTranslator<NucleotideCompound,NucleotideCompound> - Parameters:
originalSequence- The DNA sequence to translate- Returns:
- The translated single sequence
-
wrapToRna
Takes in the given DNA Sequence and returns an instance of RNASequence which is usingRnaSequenceViewas aProxySequenceReader. -
createSequence
public Sequence<NucleotideCompound> createSequence(Sequence<NucleotideCompound> originalSequence, Frame frame) -
createSequence
- Specified by:
createSequencein interfaceCompoundTranslator<NucleotideCompound,NucleotideCompound> - Overrides:
createSequencein classAbstractCompoundTranslator<NucleotideCompound,NucleotideCompound>
-
postProcessCompoundLists
- Specified by:
postProcessCompoundListsin classAbstractCompoundTranslator<NucleotideCompound,NucleotideCompound>
-