bpp-seq3
3.0.0
|
Replication between to nucleic acids. More...
#include <Bpp/Seq/NucleicAcidsReplication.h>
Public Member Functions | |
NucleicAcidsReplication (std::shared_ptr< const NucleicAlphabet > nuc1, std::shared_ptr< const NucleicAlphabet > nuc2) | |
NucleicAcidsReplication (const NucleicAcidsReplication &nar) | |
NucleicAcidsReplication & | operator= (const NucleicAcidsReplication &nar) |
virtual | ~NucleicAcidsReplication () |
std::shared_ptr< const Alphabet > | getSourceAlphabet () const override |
Get the source alphabet. More... | |
const Alphabet & | sourceAlphabet () const override |
Get the source alphabet. More... | |
std::shared_ptr< const Alphabet > | getTargetAlphabet () const override |
Get the target alphabet. More... | |
const Alphabet & | targetAlphabet () const override |
Get the target alphabet. More... | |
int | translate (int state) const override |
Translate a given state coded as a int from source alphabet to target alphabet. More... | |
std::string | translate (const std::string &state) const override |
Translate a given state coded as a string from source alphabet to target alphabet. More... | |
std::unique_ptr< Sequence > | translate (const SequenceInterface &sequence) const override |
Translate a whole sequence from source alphabet to target alphabet. More... | |
int | reverse (int state) const override |
Translate a given state coded as a int from target alphabet to source alphabet. More... | |
std::string | reverse (const std::string &state) const override |
Translate a given state coded as a string from target alphabet to source alphabet. More... | |
std::unique_ptr< Sequence > | reverse (const SequenceInterface &sequence) const override |
Translate a whole sequence from target alphabet to source alphabet. More... | |
Private Attributes | |
std::shared_ptr< const NucleicAlphabet > | nuc1_ |
std::shared_ptr< const NucleicAlphabet > | nuc2_ |
std::map< int, int > | trans_ |
Replication between to nucleic acids.
Example of use:
Since this is an instance of the ReverseIterator interface, transcription and reverse transcription may be achieved from the same instance of the object by using the translate and reverse methods.
Definition at line 31 of file NucleicAcidsReplication.h.
NucleicAcidsReplication::NucleicAcidsReplication | ( | std::shared_ptr< const NucleicAlphabet > | nuc1, |
std::shared_ptr< const NucleicAlphabet > | nuc2 | ||
) |
Definition at line 11 of file NucleicAcidsReplication.cpp.
References trans_.
|
inline |
Definition at line 43 of file NucleicAcidsReplication.h.
|
inlinevirtual |
Definition at line 57 of file NucleicAcidsReplication.h.
|
inlineoverridevirtual |
Get the source alphabet.
Implements bpp::TransliteratorInterface.
Definition at line 60 of file NucleicAcidsReplication.h.
References nuc1_.
Referenced by reverse(), and translate().
|
inlineoverridevirtual |
Get the target alphabet.
Implements bpp::TransliteratorInterface.
Definition at line 64 of file NucleicAcidsReplication.h.
References nuc2_.
Referenced by reverse(), and translate().
|
inline |
Definition at line 48 of file NucleicAcidsReplication.h.
|
overridevirtual |
Translate a whole sequence from target alphabet to source alphabet.
sequence | A sequence in target alphabet. |
Implements bpp::ReverseTransliteratorInterface.
Definition at line 75 of file NucleicAcidsReplication.cpp.
References bpp::CruxSymbolListInterface::getAlphabet(), bpp::Commentable::getComments(), bpp::CoreSequenceInterface::getName(), getSourceAlphabet(), getTargetAlphabet(), bpp::TemplateCoreSymbolListInterface< T >::getValue(), reverse(), and bpp::CruxSymbolListInterface::size().
|
overridevirtual |
Translate a given state coded as a string from target alphabet to source alphabet.
state | A state in target alphabet. |
Implements bpp::ReverseTransliteratorInterface.
Definition at line 69 of file NucleicAcidsReplication.cpp.
|
overridevirtual |
Translate a given state coded as a int from target alphabet to source alphabet.
state | A state in target alphabet. |
Implements bpp::ReverseTransliteratorInterface.
Definition at line 63 of file NucleicAcidsReplication.cpp.
Referenced by reverse().
|
inlineoverridevirtual |
Get the source alphabet.
Implements bpp::TransliteratorInterface.
Definition at line 62 of file NucleicAcidsReplication.h.
References nuc1_.
|
inlineoverridevirtual |
Get the target alphabet.
Implements bpp::TransliteratorInterface.
Definition at line 66 of file NucleicAcidsReplication.h.
References nuc2_.
|
overridevirtual |
Translate a whole sequence from source alphabet to target alphabet.
sequence | A sequence in source alphabet. |
Implements bpp::TransliteratorInterface.
Definition at line 49 of file NucleicAcidsReplication.cpp.
References bpp::CruxSymbolListInterface::getAlphabet(), bpp::Commentable::getComments(), bpp::CoreSequenceInterface::getName(), getSourceAlphabet(), getTargetAlphabet(), bpp::TemplateCoreSymbolListInterface< T >::getValue(), bpp::CruxSymbolListInterface::size(), and translate().
|
overridevirtual |
Translate a given state coded as a string from source alphabet to target alphabet.
state | A state in source alphabet. |
Implements bpp::TransliteratorInterface.
Definition at line 43 of file NucleicAcidsReplication.cpp.
|
overridevirtual |
Translate a given state coded as a int from source alphabet to target alphabet.
state | A state in source alphabet. |
Implements bpp::TransliteratorInterface.
Definition at line 37 of file NucleicAcidsReplication.cpp.
Referenced by bpp::SequenceWithQualityTools::complement(), bpp::SequenceTools::complement(), bpp::SequenceTools::getComplement(), bpp::SequenceTools::invertComplement(), and translate().
|
private |
Definition at line 35 of file NucleicAcidsReplication.h.
Referenced by getSourceAlphabet(), operator=(), reverse(), sourceAlphabet(), and translate().
|
private |
Definition at line 35 of file NucleicAcidsReplication.h.
Referenced by getTargetAlphabet(), operator=(), reverse(), targetAlphabet(), and translate().
|
mutableprivate |
Definition at line 36 of file NucleicAcidsReplication.h.
Referenced by NucleicAcidsReplication(), operator=(), reverse(), and translate().