Mass++ Common Libraries v2.7.5
 All Classes Namespaces Files Functions Variables Enumerations Macros
Peak2DElement.h
Go to the documentation of this file.
1 
12 #ifndef __KOME_OBJECTS_PEAK_2D_ELEMENT_H__
13 #define __KOME_OBJECTS_PEAK_2D_ELEMENT_H__
14 
15 
16 #include <vector>
17 #include <boost/function.hpp>
18 
19 #include "PeakElement.h"
20 
21 
22 namespace kome {
23  namespace objects {
24 
25  class Peaks2D;
26  class PeaksCluster2D;
27  class PeakElement;
28 
33  class DATA_OBJECTS_CLASS Peak2DElement {
34  public:
40  Peak2DElement( Peaks2D* peaks );
41 
46  virtual ~Peak2DElement();
47 
48  protected:
50  double m_rt;
51 
53  double m_startRt;
54 
56  double m_endRt;
57 
59  double m_mz;
60 
62  double m_startMz;
63 
65  double m_endMz;
66 
68  double m_intensity;
69 
71  int m_charge;
72 
74  double m_fwhm;
75 
77  double m_area;
78 
81 
84 
86  int m_elmId;
87 
90 
92  double m_precursor;
93 
94  protected:
99  struct DataInfo {
100  PeakElement peak;
101  int profile;
102  int sampleId;
103  double peakVal;
104  };
105 
110  struct ParamInfo {
111  int type;
112  std::string name;
113  std::string value;
114  };
115 
117  std::vector< DataInfo > m_dataList;
118 
120  std::vector< ParamInfo > m_params;
121 
122  public:
130  void setRt( const double rt, const double startRt, const double endRt );
131 
137  double getRt();
138 
144  double getStartRt();
145 
151  double getEndRt();
152 
160  void setMz( const double mz, const double startMz, const double endMz );
161 
167  double getMz();
168 
174  double getStartMz();
175 
181  double getEndMz();
182 
188  void setIntensity( const double intensity );
189 
195  double getIntensity();
196 
202  void setCluster( PeaksCluster2D* cluster );
203 
209  PeaksCluster2D* getCluster();
210 
216  void setPrecursorMass( const double precursor );
217 
223  double getPrecursorMass();
224 
230  void setCharge( const int charge );
231 
237  int getCharge();
238 
244  void setFwhm( const double fwhm );
245 
251  double getFwhm();
252 
258  void setArea( const double area );
259 
265  double getArea();
266 
272  void setId( int id );
273 
279  int getId();
280 
281  public:
286  void clearData();
287 
293  unsigned int getDataListSize();
294 
303  void addData( const int sampleId, const int profileId, const double peakVal, PeakElement* peak );
304 
313  void setData( const int sampleId, const int profileId, const double peakVal, PeakElement* peak );
314 
321  PeakElement* getDataPeak( const unsigned int idx = 0 );
322 
329  int getDataProfileId( const unsigned int idx = 0 );
330 
337  int getDataSampleId( const unsigned int idx = 0 );
338 
345  double getDataPeakValue( const unsigned int idx = 0 );
346 
347  public:
352  void clearParameters();
353 
361  void setParameter( const char* name, const char* value, const int type = 0 );
362 
368  unsigned int getNumberOfParameters();
369 
375  const char* getParameterName( const int idx );
376 
383  const char* getParameterValue( const char* name );
384 
391  const char* getParameterValue( const int idx );
392 
399  int getParameterType( const char* name );
400 
407  int getParameterType( const int idx );
408 
409  protected:
416  int searchParameterIndex( const char* name );
417  };
418  }
419 }
420 
421 
422 #endif // __KOME_OBJECTS_PEAK_2D_ELEMENT_H__
PeaksCluster2D * m_cluster
Definition: Peak2DElement.h:83
std::vector< ParamInfo > m_params
2-dimentional peaks cluster
interfaces of PeakElement class
2-dimentional peaks
Definition: Peaks2D.h:32
2-dimentional peak element
Definition: Peak2DElement.h:33
std::vector< DataInfo > m_dataList