libpappsomspp
Library for mass spectrometry
Toggle main menu visibility
Loading...
Searching...
No Matches
aa.h
Go to the documentation of this file.
1
/**
2
* \file pappsomspp/amino_acid/aaBase.h
3
* \date 7/3/2015
4
* \author Olivier Langella
5
* \brief amino acid model
6
*/
7
8
/*******************************************************************************
9
* Copyright (c) 2015 Olivier Langella <Olivier.Langella@moulon.inra.fr>.
10
*
11
* This file is part of the PAPPSOms++ library.
12
*
13
* PAPPSOms++ is free software: you can redistribute it and/or modify
14
* it under the terms of the GNU General Public License as published by
15
* the Free Software Foundation, either version 3 of the License, or
16
* (at your option) any later version.
17
*
18
* PAPPSOms++ is distributed in the hope that it will be useful,
19
* but WITHOUT ANY WARRANTY; without even the implied warranty of
20
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
21
* GNU General Public License for more details.
22
*
23
* You should have received a copy of the GNU General Public License
24
* along with PAPPSOms++. If not, see <http://www.gnu.org/licenses/>.
25
*
26
* Contributors:
27
* Olivier Langella <Olivier.Langella@moulon.inra.fr> - initial API and
28
*implementation
29
******************************************************************************/
30
31
32
#pragma once
33
34
#include <vector>
35
#include "
pappsomspp/core/types.h
"
36
#include "
pappsomspp/core/amino_acid/aabase.h
"
37
#include "
pappsomspp/core/amino_acid/aamodification.h
"
38
39
40
namespace
pappso
41
{
42
43
44
class
PMSPP_LIB_DECL
Aa
:
public
AaBase
45
{
46
public
:
47
Aa
(
char
aa_letter);
48
Aa
(
Enums::AminoAcidChar
aa_char);
49
Aa
(
const
Aa
&aa);
50
Aa
(
Aa
&&toCopy);
// move constructor
51
Aa
&
operator=
(
const
Aa
&toCopy);
52
53
virtual
~Aa
();
54
55
pappso_double
getMass
()
const override
;
56
int
getNumberOfAtom
(
Enums::AtomIsotopeSurvey
atom)
const
override
final
;
57
int
getNumberOfIsotope
(
Enums::Isotope
isotope)
const
override
final
;
58
unsigned
int
getNumberOfModification
(
AaModificationP
mod)
const
;
59
60
/* \brief print modification except internal modifications */
61
const
QString
toString
()
const
;
62
/* \brief print all modifications */
63
const
QString
toAbsoluteString
()
const
;
64
65
/** @brief get the amino acid in ProForma notation
66
* https://github.com/HUPO-PSI/ProForma/blob/master/README.md
67
* @return QString as described in ProForma
68
*/
69
const
QString
toProForma
()
const
;
70
71
72
void
addAaModification
(
AaModificationP
aaModification);
73
void
removeAaModification
(
AaModificationP
aaModification);
74
75
76
/** @brief replaces all occurences of a modification by a new one
77
* @param oldmod modification to change
78
* @param newmod new modification
79
*/
80
void
replaceAaModification
(
AaModificationP
oldmod,
AaModificationP
newmod);
81
82
83
/** @brief remove all non internal modifications
84
*/
85
void
removeAllButInternalModification
();
86
87
const
std::vector<AaModificationP> &
getModificationList
()
const
;
88
89
/** @brief get the sum of mass modifications
90
*/
91
double
getTotalModificationMass
()
const
;
92
93
bool
isLesser
(
Aa
const
&r)
const
;
94
bool
isAaEqual
(
Aa
const
&r)
const
;
95
96
private
:
97
// const pappso_double _aa_mass;
98
std::vector<AaModificationP>
m_listMod
;
99
};
100
101
bool
operator<
(
const
Aa
&l,
const
Aa
&r);
102
103
bool
operator==
(
const
Aa
&l,
const
Aa
&r);
104
105
}
/* namespace pappso */
aabase.h
aamodification.h
pappso::AaBase::AaBase
AaBase(char aa_letter)
Definition
aabase.cpp:43
pappso::Aa
Definition
aa.h:45
pappso::Aa::toProForma
const QString toProForma() const
get the amino acid in ProForma notation https://github.com/HUPO-PSI/ProForma/blob/master/README....
Definition
aa.cpp:147
pappso::Aa::toAbsoluteString
const QString toAbsoluteString() const
Definition
aa.cpp:104
pappso::Aa::getNumberOfIsotope
int getNumberOfIsotope(Enums::Isotope isotope) const override final
get the number of isotopes C13, H2, O17, O18, N15, S33, S34, S36 in the molecule
Definition
aa.cpp:220
pappso::Aa::getTotalModificationMass
double getTotalModificationMass() const
get the sum of mass modifications
Definition
aa.cpp:79
pappso::Aa::Aa
Aa(char aa_letter)
Definition
aa.cpp:41
pappso::Aa::getModificationList
const std::vector< AaModificationP > & getModificationList() const
Definition
aa.cpp:73
pappso::Aa::toString
const QString toString() const
Definition
aa.cpp:124
pappso::Aa::isAaEqual
bool isAaEqual(Aa const &r) const
Definition
aa.cpp:279
pappso::Aa::replaceAaModification
void replaceAaModification(AaModificationP oldmod, AaModificationP newmod)
replaces all occurences of a modification by a new one
Definition
aa.cpp:199
pappso::Aa::addAaModification
void addAaModification(AaModificationP aaModification)
Definition
aa.cpp:189
pappso::Aa::getNumberOfModification
unsigned int getNumberOfModification(AaModificationP mod) const
Definition
aa.cpp:233
pappso::Aa::removeAllButInternalModification
void removeAllButInternalModification()
remove all non internal modifications
Definition
aa.cpp:247
pappso::Aa::m_listMod
std::vector< AaModificationP > m_listMod
Definition
aa.h:98
pappso::Aa::getNumberOfAtom
int getNumberOfAtom(Enums::AtomIsotopeSurvey atom) const override final
get the number of atom C, O, N, H in the molecule
Definition
aa.cpp:206
pappso::Aa::isLesser
bool isLesser(Aa const &r) const
Definition
aa.cpp:254
pappso::Aa::operator=
Aa & operator=(const Aa &toCopy)
Definition
aa.cpp:65
pappso::Aa::removeAaModification
void removeAaModification(AaModificationP aaModification)
Definition
aa.cpp:177
pappso::Aa::getMass
pappso_double getMass() const override
Definition
aa.cpp:90
PMSPP_LIB_DECL
#define PMSPP_LIB_DECL
Definition
export-import-config.h:14
pappso::Enums::AtomIsotopeSurvey
AtomIsotopeSurvey
Definition
types.h:103
pappso::Enums::Isotope
Isotope
Definition
types.h:119
pappso::Enums::AminoAcidChar
AminoAcidChar
Definition
types.h:187
pappso
tries to keep as much as possible monoisotopes, removing any possible C13 peaks and changes multichar...
Definition
aa.cpp:39
pappso::operator<
bool operator<(Aa const &l, Aa const &r)
Definition
aa.cpp:292
pappso::AaModificationP
const AaModification * AaModificationP
Definition
aamodification.h:52
pappso::pappso_double
double pappso_double
A type definition for doubles.
Definition
types.h:60
pappso::operator==
bool operator==(Aa const &l, Aa const &r)
Definition
aa.cpp:286
types.h
pappsomspp
core
amino_acid
aa.h
Generated on
for libpappsomspp by
1.17.0