libpappsomspp
Library for mass spectrometry
|
#include <peptide.h>
Public Member Functions | |
Peptide (const QString &pepstr) | |
virtual | ~Peptide () |
Peptide (const Peptide &peptide) | |
Peptide (Peptide &&toCopy) | |
PeptideSp | makePeptideSp () const |
NoConstPeptideSp | makeNoConstPeptideSp () const |
void | addAaModification (AaModificationP aaModification, unsigned int position) |
adds a modification to amino acid sequence More... | |
std::vector< Aa >::iterator | begin () |
std::vector< Aa >::iterator | end () |
std::vector< Aa >::const_iterator | begin () const |
std::vector< Aa >::const_iterator | end () const |
std::vector< Aa >::const_reverse_iterator | rbegin () const |
std::vector< Aa >::const_reverse_iterator | rend () const |
Aa & | getAa (unsigned int position) |
const Aa & | getConstAa (unsigned int position) const |
pappso_double | getMass () |
pappso_double | getMass () const override |
virtual int | getNumberOfAtom (AtomIsotopeSurvey atom) const override |
get the number of atom C, O, N, H in the molecule More... | |
virtual int | getNumberOfIsotope (Isotope isotope) const override |
get the number of isotopes C13, H2, O17, O18, N15, S33, S34, S36 in the molecule More... | |
const QString | getSequence () const override |
print amino acid sequence without modifications More... | |
unsigned int | size () const override |
unsigned int | getNumberOfModification (AaModificationP mod) const |
count modification occurence More... | |
unsigned int | countModificationOnAa (AaModificationP mod, const std::vector< char > &aa_list) const |
count modification occurence More... | |
void | replaceAaModification (AaModificationP oldmod, AaModificationP newmod) |
replaces all occurences of a modification by a new one More... | |
void | removeAaModification (AaModificationP mod) |
removes all occurences of a modification More... | |
std::vector< unsigned int > | getModificationPositionList (AaModificationP mod) const |
get modification positions More... | |
std::vector< unsigned int > | getModificationPositionList (AaModificationP mod, const std::vector< char > &aa_list) const |
get modification positions More... | |
std::vector< unsigned int > | getAaPositionList (char aa) const |
get positions of one amino acid in peptide More... | |
std::vector< unsigned int > | getAaPositionList (std::list< char > list_aa) const |
const QString | toString () const |
print modification except internal modifications More... | |
const QString | toAbsoluteString () const |
print all modifications More... | |
const QString | getLiAbsoluteString () const |
get all sequence string with modifications and converting Leucine to Isoleucine More... | |
AaModificationP | getInternalNterModification () const |
AaModificationP | getInternalCterModification () const |
void | removeInternalNterModification () |
void | removeInternalCterModification () |
void | setInternalNterModification (AaModificationP mod) |
void | setInternalCterModification (AaModificationP mod) |
void | rotate () |
void | reverse () |
virtual bool | isPalindrome () const override |
tells if the peptide sequence is a palindrome More... | |
void | replaceLeucineIsoleucine () |
void | removeNterAminoAcid () |
void | removeCterAminoAcid () |
![]() | |
virtual const QString | getSequenceLi () const |
amino acid sequence without modification where L are replaced by I More... | |
virtual const QString | getName () const |
virtual const QString | getFormula (unsigned int charge) const final |
virtual bool | matchPeak (PrecisionPtr precision, pappso_double peak_mz, unsigned int charge) const final |
![]() | |
Ion () | |
~Ion () | |
virtual pappso_double | getMz (unsigned int charge) const final |
Protected Attributes | |
std::vector< Aa > | m_aaVec |
pappso_double | m_proxyMass = -1 |
Friends | |
bool | operator< (const Peptide &l, const Peptide &r) |
bool | operator== (const Peptide &l, const Peptide &r) |
pappso::Peptide::Peptide | ( | const QString & | pepstr | ) |
Definition at line 79 of file peptide.cpp.
References pappso::Aa::addAaModification(), pappso::AaModification::getInstance(), getMass(), and m_aaVec.
|
virtual |
Definition at line 108 of file peptide.cpp.
pappso::Peptide::Peptide | ( | const Peptide & | peptide | ) |
Definition at line 112 of file peptide.cpp.
pappso::Peptide::Peptide | ( | Peptide && | toCopy | ) |
Definition at line 118 of file peptide.cpp.
void pappso::Peptide::addAaModification | ( | AaModificationP | aaModification, |
unsigned int | position | ||
) |
adds a modification to amino acid sequence
aaModification | pointer on modification to add |
position | position in the amino acid sequence (starts at 0) |
Definition at line 137 of file peptide.cpp.
References getMass(), m_aaVec, m_proxyMass, and size().
Referenced by pappso::PeptideStrParser::parseStringToPeptide(), reverse(), rotate(), pappso::PeptideBuilder::setPeptide(), pappso::PeptideFixedModificationBuilder::setPeptideSp(), and pappso::PeptideVariableModificationBuilder::setPeptideSp().
|
inline |
Definition at line 133 of file peptide.h.
Referenced by pappso::PeptideRawFragmentMasses::PeptideRawFragmentMasses().
|
inline |
unsigned int pappso::Peptide::countModificationOnAa | ( | AaModificationP | mod, |
const std::vector< char > & | aa_list | ||
) | const |
count modification occurence
mod | modification to look for |
aa_list | amino acid list targets (one letter code) |
Definition at line 266 of file peptide.cpp.
References m_aaVec.
|
inline |
Definition at line 139 of file peptide.h.
Referenced by pappso::PeptideRawFragmentMasses::PeptideRawFragmentMasses().
|
inline |
Aa & pappso::Peptide::getAa | ( | unsigned int | position | ) |
Definition at line 535 of file peptide.cpp.
References m_aaVec.
Referenced by pappso::PeptideVariableModificationReplacement::replaceModificationsAtPosition().
std::vector< unsigned int > pappso::Peptide::getAaPositionList | ( | char | aa | ) | const |
get positions of one amino acid in peptide
aa | the one letter code of the amino acid |
Definition at line 360 of file peptide.cpp.
References m_aaVec.
Referenced by pappso::PeptideBuilder::setPeptide().
std::vector< unsigned int > pappso::Peptide::getAaPositionList | ( | std::list< char > | list_aa | ) | const |
const Aa & pappso::Peptide::getConstAa | ( | unsigned int | position | ) | const |
Definition at line 545 of file peptide.cpp.
References m_aaVec.
Referenced by pappso::PeptideModificatorBase::getModificationPositionList().
AaModificationP pappso::Peptide::getInternalCterModification | ( | ) | const |
Definition at line 411 of file peptide.cpp.
References m_aaVec.
Referenced by pappso::PeptideRawFragmentMasses::PeptideRawFragmentMasses(), removeCterAminoAcid(), reverse(), and rotate().
AaModificationP pappso::Peptide::getInternalNterModification | ( | ) | const |
Definition at line 400 of file peptide.cpp.
References m_aaVec.
Referenced by pappso::PeptideRawFragmentMasses::PeptideRawFragmentMasses(), removeNterAminoAcid(), reverse(), and rotate().
const QString pappso::Peptide::getLiAbsoluteString | ( | ) | const |
get all sequence string with modifications and converting Leucine to Isoleucine
Definition at line 180 of file peptide.cpp.
References m_aaVec.
pappso_double pappso::Peptide::getMass | ( | ) |
Definition at line 207 of file peptide.cpp.
References m_aaVec, and m_proxyMass.
Referenced by Peptide(), addAaModification(), pappso::Protein::getMass(), removeAaModification(), removeCterAminoAcid(), removeNterAminoAcid(), and replaceAaModification().
|
inlineoverridevirtual |
Implements pappso::Ion.
std::vector< unsigned int > pappso::Peptide::getModificationPositionList | ( | AaModificationP | mod | ) | const |
get modification positions
mod | modification to look for |
Definition at line 313 of file peptide.cpp.
References m_aaVec.
std::vector< unsigned int > pappso::Peptide::getModificationPositionList | ( | AaModificationP | mod, |
const std::vector< char > & | aa_list | ||
) | const |
get modification positions
mod | modification to look for |
aa_list | amino acid list targets (one letter code) |
Definition at line 334 of file peptide.cpp.
References m_aaVec.
|
overridevirtual |
get the number of atom C, O, N, H in the molecule
Implements pappso::AtomNumberInterface.
Definition at line 223 of file peptide.cpp.
References m_aaVec.
|
overridevirtual |
get the number of isotopes C13, H2, O17, O18, N15, S33, S34, S36 in the molecule
Implements pappso::AtomNumberInterface.
Definition at line 237 of file peptide.cpp.
References m_aaVec.
unsigned int pappso::Peptide::getNumberOfModification | ( | AaModificationP | mod | ) | const |
count modification occurence
mod | modification to look for |
Definition at line 252 of file peptide.cpp.
References m_aaVec.
|
overridevirtual |
print amino acid sequence without modifications
Implements pappso::PeptideInterface.
Definition at line 155 of file peptide.cpp.
References m_aaVec.
Referenced by pappso::XtandemHyperscoreBis::computeXtandemHyperscore(), and pappso::PeptideModificatorBase::getModificationPositionList().
|
overridevirtual |
tells if the peptide sequence is a palindrome
Implements pappso::PeptideInterface.
Definition at line 520 of file peptide.cpp.
NoConstPeptideSp pappso::Peptide::makeNoConstPeptideSp | ( | ) | const |
Definition at line 131 of file peptide.cpp.
Referenced by pappso::PeptideStrParser::parseNoConstString().
PeptideSp pappso::Peptide::makePeptideSp | ( | ) | const |
Definition at line 125 of file peptide.cpp.
Referenced by pappso::PeptideStrParser::parseString(), pappso::PeptideBuilder::setPeptide(), pappso::PeptideModificatorPipeline::setPeptide(), pappso::PeptideFixedModificationBuilder::setPeptideSp(), pappso::PeptideVariableModificationBuilder::setPeptideSp(), and pappso::PeptideVariableModificationReplacement::setPeptideSp().
|
inline |
Definition at line 157 of file peptide.h.
Referenced by pappso::PeptideRawFragmentMasses::PeptideRawFragmentMasses().
void pappso::Peptide::removeAaModification | ( | AaModificationP | mod | ) |
removes all occurences of a modification
mod | modification to remove |
Definition at line 299 of file peptide.cpp.
References getMass(), m_aaVec, m_proxyMass, and toAbsoluteString().
void pappso::Peptide::removeCterAminoAcid | ( | ) |
Definition at line 593 of file peptide.cpp.
References getInternalCterModification(), getMass(), m_aaVec, and m_proxyMass.
void pappso::Peptide::removeInternalCterModification | ( | ) |
Definition at line 433 of file peptide.cpp.
References m_aaVec, and m_proxyMass.
Referenced by reverse(), rotate(), and setInternalCterModification().
void pappso::Peptide::removeInternalNterModification | ( | ) |
Definition at line 422 of file peptide.cpp.
References m_aaVec, and m_proxyMass.
Referenced by setInternalNterModification().
void pappso::Peptide::removeNterAminoAcid | ( | ) |
Definition at line 570 of file peptide.cpp.
References getInternalNterModification(), getMass(), m_aaVec, and m_proxyMass.
|
inline |
Definition at line 163 of file peptide.h.
Referenced by pappso::PeptideRawFragmentMasses::PeptideRawFragmentMasses().
void pappso::Peptide::replaceAaModification | ( | AaModificationP | oldmod, |
AaModificationP | newmod | ||
) |
replaces all occurences of a modification by a new one
oldmod | modification to change |
newmod | new modification |
Definition at line 285 of file peptide.cpp.
References getMass(), m_aaVec, and m_proxyMass.
void pappso::Peptide::replaceLeucineIsoleucine | ( | ) |
void pappso::Peptide::reverse | ( | ) |
Definition at line 507 of file peptide.cpp.
References addAaModification(), getInternalCterModification(), getInternalNterModification(), m_aaVec, and removeInternalCterModification().
void pappso::Peptide::rotate | ( | ) |
Definition at line 495 of file peptide.cpp.
References addAaModification(), getInternalCterModification(), getInternalNterModification(), m_aaVec, and removeInternalCterModification().
void pappso::Peptide::setInternalCterModification | ( | AaModificationP | mod | ) |
Definition at line 470 of file peptide.cpp.
References pappso::AaModification::getAccession(), m_aaVec, and removeInternalCterModification().
Referenced by pappso::PeptideStrParser::parseStringToPeptide().
void pappso::Peptide::setInternalNterModification | ( | AaModificationP | mod | ) |
Definition at line 447 of file peptide.cpp.
References pappso::AaModification::getAccession(), m_aaVec, and removeInternalNterModification().
Referenced by pappso::PeptideStrParser::parseStringToPeptide().
|
inlineoverridevirtual |
Implements pappso::PeptideInterface.
Definition at line 185 of file peptide.h.
Referenced by addAaModification(), isPalindrome(), and pappso::PeptideFixedModificationBuilder::setPeptideSp().
const QString pappso::Peptide::toAbsoluteString | ( | ) | const |
print all modifications
Definition at line 167 of file peptide.cpp.
References m_aaVec.
Referenced by removeAaModification().
const QString pappso::Peptide::toString | ( | ) | const |
print modification except internal modifications
Definition at line 194 of file peptide.cpp.
References m_aaVec.
|
protected |
Definition at line 102 of file peptide.h.
Referenced by Peptide(), addAaModification(), countModificationOnAa(), getAa(), getAaPositionList(), getConstAa(), getInternalCterModification(), getInternalNterModification(), getLiAbsoluteString(), getMass(), getModificationPositionList(), getNumberOfAtom(), getNumberOfIsotope(), getNumberOfModification(), getSequence(), isPalindrome(), removeAaModification(), removeCterAminoAcid(), removeInternalCterModification(), removeInternalNterModification(), removeNterAminoAcid(), replaceAaModification(), replaceLeucineIsoleucine(), reverse(), rotate(), setInternalCterModification(), setInternalNterModification(), toAbsoluteString(), and toString().
|
protected |
Definition at line 103 of file peptide.h.
Referenced by addAaModification(), getMass(), removeAaModification(), removeCterAminoAcid(), removeInternalCterModification(), removeInternalNterModification(), removeNterAminoAcid(), and replaceAaModification().