libpappsomspp
Library for mass spectrometry
xiccoord.h
Go to the documentation of this file.
1 /**
2  * \file pappsomspp/msrun/xiccoord/xiccoord.h
3  * \date 22/04/2021
4  * \author Olivier Langella
5  * \brief XIC coordinate in MSrun
6  */
7 
8 
9 /*******************************************************************************
10  * Copyright (c) 2021 Olivier Langella
11  *<Olivier.Langella@universite-paris-saclay.fr>.
12  *
13  * This file is part of the PAPPSOms++ library.
14  *
15  * PAPPSOms++ is free software: you can redistribute it and/or modify
16  * it under the terms of the GNU General Public License as published by
17  * the Free Software Foundation, either version 3 of the License, or
18  * (at your option) any later version.
19  *
20  * PAPPSOms++ is distributed in the hope that it will be useful,
21  * but WITHOUT ANY WARRANTY; without even the implied warranty of
22  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
23  * GNU General Public License for more details.
24  *
25  * You should have received a copy of the GNU General Public License
26  * along with PAPPSOms++. If not, see <http://www.gnu.org/licenses/>.
27  *
28  ******************************************************************************/
29 
30 #pragma once
31 
32 #include "../../exportinmportconfig.h"
33 #include "../../mzrange.h"
34 #include "../../xic/xic.h"
35 #include <memory>
36 
37 namespace pappso
38 {
39 
40 
41 struct XicCoord;
42 
43 typedef std::shared_ptr<XicCoord> XicCoordSPtr;
44 
45 /** @brief coordinates of the XIC to extract and the resulting XIC after
46  * extraction
47  *
48  * to extract a XIC, we need basically the mass to extract it
49  * this structure is meant to extact a XIC quickly and not to maintain
50  * information about it : no peptide, no scan number, no retention time...
51  *
52  */
54 {
55  /**
56  * Default constructor
57  */
58  XicCoord();
59 
60  /**
61  * Copy constructor
62  *
63  * @param other TODO
64  */
65  XicCoord(const XicCoord &other);
66 
67  /**
68  * Destructor
69  */
70  virtual ~XicCoord();
71 
72 
73  /** @brief intialize the XIC and make a deep copy of object
74  */
75  virtual XicCoordSPtr initializeAndClone() const;
76 
77  /** @brief compute a new XIC coord as the sum of the given one
78  */
79  virtual XicCoordSPtr addition(XicCoordSPtr &to_add) const;
80 
81 
82  /** @brief compute a new xic coord as a product by
83  */
84  virtual XicCoordSPtr multiplyBy(double number) const;
85 
86 
87  /** @brief compute a new xic coord as a division by
88  */
89  virtual XicCoordSPtr divideBy(double number) const;
90 
91 
92  /** @brief reset to zero
93  */
94  virtual void reset();
95 
96  /** @brief get a description of the XIC coordinate in a string
97  */
98  virtual QString toString() const;
99 
100 
101  /** @brief the mass to extract
102  * */
104 
105  /** @brief the targeted retention time to extract around
106  * intended in seconds, and related to one msrun. This is not a reference,
107  * just to save memory and cpu usage when extracting xic
108  */
109  double rtTarget = 0;
110 
111  /** @brief extracted xic
112  */
113  XicSPtr xicSptr = nullptr;
114 };
115 } // namespace pappso
#define PMSPP_LIB_DECL
tries to keep as much as possible monoisotopes, removing any possible C13 peaks and changes multichar...
Definition: aa.cpp:39
std::shared_ptr< Xic > XicSPtr
Definition: xic.h:39
std::shared_ptr< XicCoord > XicCoordSPtr
Definition: xiccoord.h:41
coordinates of the XIC to extract and the resulting XIC after extraction
Definition: xiccoord.h:54
MzRange mzRange
the mass to extract
Definition: xiccoord.h:103