libpappsomspp
Library for mass spectrometry
Toggle main menu visibility
Loading...
Searching...
No Matches
peptideinterface.h
Go to the documentation of this file.
1
2
/*******************************************************************************
3
* Copyright (c) 2015 Olivier Langella <Olivier.Langella@moulon.inra.fr>.
4
*
5
* This file is part of the PAPPSOms++ library.
6
*
7
* PAPPSOms++ is free software: you can redistribute it and/or modify
8
* it under the terms of the GNU General Public License as published by
9
* the Free Software Foundation, either version 3 of the License, or
10
* (at your option) any later version.
11
*
12
* PAPPSOms++ is distributed in the hope that it will be useful,
13
* but WITHOUT ANY WARRANTY; without even the implied warranty of
14
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15
* GNU General Public License for more details.
16
*
17
* You should have received a copy of the GNU General Public License
18
* along with PAPPSOms++. If not, see <http://www.gnu.org/licenses/>.
19
*
20
* Contributors:
21
* Olivier Langella <Olivier.Langella@moulon.inra.fr> - initial API and
22
*implementation
23
******************************************************************************/
24
25
#pragma once
26
27
#include <memory>
28
#include "
ion.h
"
29
#include <QString>
30
#include "
../amino_acid/atomnumberinterface.h
"
31
#include "
../amino_acid/chemicalformula.h
"
32
#include "
pappsomspp/core/mzrange.h
"
33
#include "
pappsomspp/export-import-config.h
"
34
35
36
namespace
pappso
37
{
38
39
class
PeptideInterface
;
40
typedef
std::shared_ptr<const PeptideInterface>
PeptideInterfaceSp
;
41
42
43
class
PMSPP_LIB_DECL
PeptideInterface
:
public
Ion
,
public
AtomNumberInterface
44
{
45
public
:
46
/** @brief amino acid sequence without modification
47
* */
48
virtual
const
QString
getSequence
()
const
= 0;
49
50
51
/** @brief tells if the peptide sequence is a palindrome
52
*/
53
virtual
bool
isPalindrome
()
const
= 0;
54
55
/** @brief amino acid sequence without modification where L are replaced by I
56
* */
57
virtual
const
QString
getSequenceLi
()
const
;
58
59
virtual
unsigned
int
size
()
const
= 0;
60
virtual
const
QString
61
getName
()
const
62
{
63
return
QString(
"unknown"
);
64
};
65
66
virtual
const
ChemicalFormula
getChemicalFormulaCharge(
unsigned
int
charge)
const
;
67
virtual
const
QString getFormula(
unsigned
int
charge)
const
final
;
68
69
70
/** @brief tells if the peptide m/z matches a given experimental mass
71
*/
72
virtual
bool
73
matchPeak
(
PrecisionPtr
precision,
pappso_double
peak_mz,
unsigned
int
charge)
const
final
74
{
75
return
(
MzRange
((
getMass
() + (
MHPLUS
* charge)) / charge, precision).contains(peak_mz));
76
};
77
78
// virtual int getNumberOfIsotope(Enums::Isotope isotope) const override = 0;
79
};
80
}
// namespace pappso
atomnumberinterface.h
chemicalformula.h
pappso::AtomNumberInterface
Definition
atomnumberinterface.h:30
pappso::ChemicalFormula
Definition
chemicalformula.h:44
pappso::Ion::getMass
virtual pappso_double getMass() const =0
pappso::Ion::Ion
Ion()
Definition
ion.cpp:36
pappso::MzRange
Definition
mzrange.h:46
pappso::PeptideInterface
Definition
peptideinterface.h:44
pappso::PeptideInterface::getName
virtual const QString getName() const
Definition
peptideinterface.h:61
pappso::PeptideInterface::getSequence
virtual const QString getSequence() const =0
amino acid sequence without modification
pappso::PeptideInterface::matchPeak
virtual bool matchPeak(PrecisionPtr precision, pappso_double peak_mz, unsigned int charge) const final
tells if the peptide m/z matches a given experimental mass
Definition
peptideinterface.h:73
pappso::PeptideInterface::getSequenceLi
virtual const QString getSequenceLi() const
amino acid sequence without modification where L are replaced by I
Definition
peptideinterface.cpp:31
pappso::PeptideInterface::isPalindrome
virtual bool isPalindrome() const =0
tells if the peptide sequence is a palindrome
pappso::PeptideInterface::size
virtual unsigned int size() const =0
export-import-config.h
PMSPP_LIB_DECL
#define PMSPP_LIB_DECL
Definition
export-import-config.h:14
ion.h
mzrange.h
pappso
tries to keep as much as possible monoisotopes, removing any possible C13 peaks and changes multichar...
Definition
aa.cpp:39
pappso::PeptideInterfaceSp
std::shared_ptr< const PeptideInterface > PeptideInterfaceSp
Definition
peptideinterface.h:40
pappso::MHPLUS
const pappso_double MHPLUS(1.007276466879)
pappso::pappso_double
double pappso_double
A type definition for doubles.
Definition
types.h:60
pappso::PrecisionPtr
const PrecisionBase * PrecisionPtr
Definition
precision.h:122
pappsomspp
core
peptide
peptideinterface.h
Generated on
for libpappsomspp by
1.17.0