OpenMS  3.0.0
RangeUtils.h
Go to the documentation of this file.
1 // --------------------------------------------------------------------------
2 // OpenMS -- Open-Source Mass Spectrometry
3 // --------------------------------------------------------------------------
4 // Copyright The OpenMS Team -- Eberhard Karls University Tuebingen,
5 // ETH Zurich, and Freie Universitaet Berlin 2002-2022.
6 //
7 // This software is released under a three-clause BSD license:
8 // * Redistributions of source code must retain the above copyright
9 // notice, this list of conditions and the following disclaimer.
10 // * Redistributions in binary form must reproduce the above copyright
11 // notice, this list of conditions and the following disclaimer in the
12 // documentation and/or other materials provided with the distribution.
13 // * Neither the name of any author or any participating institution
14 // may be used to endorse or promote products derived from this software
15 // without specific prior written permission.
16 // For a full list of authors, refer to the file AUTHORS.
17 // --------------------------------------------------------------------------
18 // THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
19 // AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
20 // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
21 // ARE DISCLAIMED. IN NO EVENT SHALL ANY OF THE AUTHORS OR THE CONTRIBUTING
22 // INSTITUTIONS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
23 // EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
24 // PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
25 // OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
26 // WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
27 // OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
28 // ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
29 //
30 // --------------------------------------------------------------------------
31 // $Maintainer: Timo Sachsenberg$
32 // $Authors: Marc Sturm, Chris Bielow $
33 // --------------------------------------------------------------------------
34 
35 #pragma once
36 
37 #include <functional>
38 #include <algorithm>
39 #include <vector>
40 #include <OpenMS/CONCEPT/Types.h>
44 
45 namespace OpenMS
46 {
95  template <class MetaContainer>
97  {
98 public:
105  HasMetaValue(String metavalue, bool reverse = false) :
106  metavalue_key_(metavalue),
108  {}
109 
110  inline bool operator()(const MetaContainer& s) const
111  {
112  bool has_meta_value = s.metaValueExists(metavalue_key_);
113  // XOR(^): same as 'if (rev_) return !(test) else return test;' where (test) is the condition; Speed: XOR is about 25% faster in VS10
114  return reverse_ ^ has_meta_value;
115  }
116 
117 protected:
119  bool reverse_;
120  };
121 
122 
130  template <class SpectrumType>
131  class InRTRange
132  {
133 public:
142  InRTRange(double min, double max, bool reverse = false) :
143  min_(min),
144  max_(max),
146  {}
147 
148  inline bool operator()(const SpectrumType& s) const
149  {
150  double tmp = s.getRT();
151  // XOR(^): same as 'if (rev_) return !(test) else return test;' where (test) is the condition; Speed: XOR is about 25% faster in VS10
152  return reverse_ ^ (min_ <= tmp && tmp <= max_);
153  }
154 
155 protected:
156  double min_, max_;
157  bool reverse_;
158  };
159 
167  template <class SpectrumType>
169  {
170 public:
178  InMSLevelRange(const IntList& levels, bool reverse = false) :
179  levels_(levels),
181  {}
182 
183  inline bool operator()(const SpectrumType& s) const
184  {
185  Int tmp = s.getMSLevel();
186  // XOR(^): same as 'if (rev_) return !(test) else return test;' where (test) is the condition; Speed: XOR is about 25% faster in VS10
187  return reverse_ ^ (std::find(levels_.begin(), levels_.end(), tmp) != levels_.end());
188  }
189 
190 protected:
192  bool reverse_;
193  };
194 
202  template <class SpectrumType>
204  {
205 public:
213  HasScanMode(Int mode, bool reverse = false) :
214  mode_(mode),
216  {}
217 
218  inline bool operator()(const SpectrumType& s) const
219  {
220  // XOR(^): same as 'if (rev_) return !(test) else return test;' where (test) is the condition; Speed: XOR is about 25% faster in VS10
221  return reverse_ ^ (s.getInstrumentSettings().getScanMode() == mode_);
222  }
223 
224 protected:
226  bool reverse_;
227  };
228 
236  template <class SpectrumType>
238  {
239 public:
247  HasScanPolarity(Int polarity, bool reverse = false) :
248  polarity_(polarity),
250  {}
251 
252  inline bool operator()(const SpectrumType& s) const
253  {
254  // XOR(^): same as 'if (rev_) return !(test) else return test;' where (test) is the condition; Speed: XOR is about 25% faster in VS10
256  }
257 
258 protected:
260  bool reverse_;
261  };
262 
263 
271  template <class SpectrumType>
273  {
274 public:
280  explicit IsEmptySpectrum(bool reverse = false) :
282  {}
283 
284  inline bool operator()(const SpectrumType& s) const
285  {
286  // XOR(^): same as 'if (rev_) return !(test) else return test;' where (test) is the condition; Speed: XOR is about 25% faster in VS10
287  return reverse_ ^ s.empty();
288  }
289 
290 protected:
291  bool reverse_;
292  };
293 
301  template <class SpectrumType>
303  {
304 public:
311  explicit IsZoomSpectrum(bool reverse = false) :
313  {}
314 
315  inline bool operator()(const SpectrumType& s) const
316  {
317  // XOR(^): same as 'if (rev_) return !(test) else return test;' where (test) is the condition; Speed: XOR is about 25% faster in VS10
319  }
320 
321 protected:
322  bool reverse_;
323  };
324 
325 
334  template <class SpectrumType>
336  {
337 public:
345  HasActivationMethod(const StringList& methods, bool reverse = false) :
346  methods_(methods),
348  {}
349 
350  inline bool operator()(const SpectrumType& s) const
351  {
352  for (const Precursor& p : s.getPrecursors())
353  {
354  for (const Precursor::ActivationMethod am : p.getActivationMethods())
355  {
357  {
358  // found matching activation method
359  if (reverse_) return false;
360  else return true;
361  }
362  }
363  }
364 
365  return reverse_;
366  }
367 
368 protected:
370  bool reverse_;
371  };
372 
382  template <class SpectrumType>
384  {
385 public:
393  InPrecursorMZRange(const double& mz_left, const double& mz_right, bool reverse = false) :
394  mz_left_(mz_left),
395  mz_right_(mz_right),
397  {}
398 
399  inline bool operator()(const SpectrumType& s) const
400  {
401  for (std::vector<Precursor>::const_iterator it = s.getPrecursors().begin(); it != s.getPrecursors().end(); ++it)
402  {
403  //std::cerr << mz_left_ << " " << mz_right_ << " " << it->getMZ() << "\n";
404  if (!(mz_left_ <= it->getMZ() && it->getMZ() <= mz_right_))
405  { // found PC outside of allowed window
406  if (reverse_) return true;
407  else return false;
408  }
409  }
410 
411  if (reverse_) return false;
412  else return true;
413  }
414 
415 protected:
416  double mz_left_;
417  double mz_right_;
418  bool reverse_;
419  };
420 
421 
430  template <class SpectrumType>
432  {
433 public:
441  HasPrecursorCharge(const IntList& charges, bool reverse = false) :
442  charges_(charges),
444  {}
445 
446  inline bool operator()(const SpectrumType& s) const
447  {
448  bool match = false;
449  for (std::vector<Precursor>::const_iterator it = s.getPrecursors().begin(); it != s.getPrecursors().end(); ++it)
450  {
451  Int tmp = it->getCharge();
452  match = match || (std::find(charges_.begin(), charges_.end(), tmp) != charges_.end());
453  }
454 
455  if (reverse_) return !match;
456  else return match;
457  }
458 
459 protected:
461  bool reverse_;
462  };
463 
464 
474  template <class PeakType>
475  class InMzRange
476  {
477 public:
486  InMzRange(double min, double max, bool reverse = false) :
487  min_(min),
488  max_(max),
490  {}
491 
492  inline bool operator()(const PeakType& p) const
493  {
494  double tmp = p.getPosition()[0];
495  // XOR(^): same as 'if (rev_) return !(test) else return test;' where (test) is the condition; Speed: XOR is about 25% faster in VS10
496  return reverse_ ^ (min_ <= tmp && tmp <= max_);
497  }
498 
499 protected:
500  double min_, max_;
501  bool reverse_;
502  };
503 
511  template <class PeakType>
513  {
514 public:
522  InIntensityRange(double min, double max, bool reverse = false) :
523  min_(min),
524  max_(max),
526  {}
527 
528  inline bool operator()(const PeakType& p) const
529  {
530  double tmp = p.getIntensity();
531  // XOR(^): same as 'if (rev_) return !(test) else return test;' where (test) is the condition; Speed: XOR is about 25% faster in VS10
532  return reverse_ ^ (min_ <= tmp && tmp <= max_);
533  }
534 
535 protected:
536  double min_, max_;
537  bool reverse_;
538  };
539 
547  template <class SpectrumType>
549  {
550 public:
558  IsInCollisionEnergyRange(double min, double max, bool reverse = false) :
559  min_energy_(min),
560  max_energy_(max),
562  {}
563 
564  inline bool operator()(const SpectrumType& s) const
565  {
566  // leave non-fragmentation spectra untouched
567  if (s.getMSLevel() == 1) return false;
568 
569  bool isIn = false;
570  bool hasCollisionEnergy = false;
571  for (std::vector<Precursor>::const_iterator it = s.getPrecursors().begin(); it != s.getPrecursors().end(); ++it)
572  {
573  if (it->metaValueExists("collision energy"))
574  {
575  hasCollisionEnergy = true;
576  double cE = it->getMetaValue("collision energy");
577  isIn |= !(cE > max_energy_ || cE < min_energy_);
578  }
579  }
580 
581  // we accept all spectra that have no collision energy value
582  if (!hasCollisionEnergy) return false;
583 
584  if (reverse_) return !isIn;
585  else return isIn;
586  }
587 
588 private:
590  bool reverse_;
591  };
592 
599  template <class SpectrumType>
601  {
602 
603 public:
611  IsInIsolationWindowSizeRange(double min_size, double max_size, bool reverse = false) :
612  min_size_(min_size),
613  max_size_(max_size),
615  {}
616 
617  inline bool operator()(const SpectrumType& s) const
618  {
619  // leave non-fragmentation spectra untouched
620  if (s.getMSLevel() == 1) return false;
621 
622  bool isIn = false;
623  for (std::vector<Precursor>::const_iterator it = s.getPrecursors().begin(); it != s.getPrecursors().end(); ++it)
624  {
625  const double isolationWindowSize = it->getIsolationWindowUpperOffset() + it->getIsolationWindowLowerOffset();
626  isIn |= !(isolationWindowSize > max_size_ || isolationWindowSize < min_size_);
627  }
628 
629  if (reverse_) return !isIn;
630  else return isIn;
631  }
632 
633 private:
635  bool reverse_;
636  };
637 
644  template <class SpectrumType>
646  {
647 
648 public:
655  IsInIsolationWindow(std::vector<double> vec_mz, bool reverse = false) :
656  vec_mz_(vec_mz),
658  {
659  std::sort(vec_mz_.begin(), vec_mz_.end());
660  }
661 
662  inline bool operator()(const SpectrumType& s) const
663  {
664  // leave non-fragmentation spectra untouched
665  if (s.getMSLevel() == 1) return false;
666 
667  bool isIn = false;
668  for (std::vector<Precursor>::const_iterator it = s.getPrecursors().begin(); it != s.getPrecursors().end(); ++it)
669  {
670  if (it->getIsolationWindowLowerOffset() == 0 || it->getIsolationWindowUpperOffset() == 0)
671  {
672  OPENMS_LOG_WARN << "IsInIsolationWindow(): Lower/Upper Offset for Precursor Isolation Window is Zero! " <<
673  "Filtering will probably be too strict (unless you hit the exact precursor m/z)!" << std::endl;
674  }
675  const double lower_mz = it->getMZ() - it->getIsolationWindowLowerOffset();
676  std::vector<double>::const_iterator it_mz = std::lower_bound(vec_mz_.begin(), vec_mz_.end(), lower_mz);
677  if (it_mz != vec_mz_.end()) // left side ok
678  { // right side?
679  const double upper_mz = it->getMZ() + it->getIsolationWindowUpperOffset();
680  isIn |= (*it_mz <= upper_mz);
681  }
682  }
683 
684  if (reverse_) return !isIn;
685  else return isIn;
686  }
687 
688 private:
689  std::vector<double> vec_mz_;
690  bool reverse_;
691  };
692 
693 } // namespace OpenMS
694 
LogStream.h
OpenMS::InIntensityRange::min_
double min_
Definition: RangeUtils.h:536
OpenMS::InMzRange::InMzRange
InMzRange(double min, double max, bool reverse=false)
Constructor.
Definition: RangeUtils.h:486
OpenMS::HasActivationMethod::operator()
bool operator()(const SpectrumType &s) const
Definition: RangeUtils.h:350
OpenMS::IsInIsolationWindow::operator()
bool operator()(const SpectrumType &s) const
Definition: RangeUtils.h:662
OpenMS::IsInIsolationWindowSizeRange
Predicate that determines if the width of the isolation window of an MSn spectrum is in the given ran...
Definition: RangeUtils.h:600
Types.h
OpenMS::InIntensityRange::operator()
bool operator()(const PeakType &p) const
Definition: RangeUtils.h:528
OpenMS::InIntensityRange::reverse_
bool reverse_
Definition: RangeUtils.h:537
OpenMS::StringUtils::reverse
static String & reverse(String &this_s)
Definition: StringUtilsSimple.h:350
OpenMS::HasScanPolarity
Predicate that determines if a spectrum has a certain scan polarity.
Definition: RangeUtils.h:237
OpenMS::HasScanMode::HasScanMode
HasScanMode(Int mode, bool reverse=false)
Constructor.
Definition: RangeUtils.h:213
OpenMS::HasMetaValue::reverse_
bool reverse_
Definition: RangeUtils.h:119
OpenMS::Peak2D
A 2-dimensional raw data point or peak.
Definition: Peak2D.h:54
OpenMS::HasPrecursorCharge::reverse_
bool reverse_
Definition: RangeUtils.h:461
OpenMS::String
A more convenient string class.
Definition: String.h:58
OpenMS::InPrecursorMZRange::InPrecursorMZRange
InPrecursorMZRange(const double &mz_left, const double &mz_right, bool reverse=false)
Constructor.
Definition: RangeUtils.h:393
OpenMS::IsEmptySpectrum::reverse_
bool reverse_
Definition: RangeUtils.h:291
OpenMS::SpectrumSettings::getPrecursors
const std::vector< Precursor > & getPrecursors() const
returns a const reference to the precursors
OpenMS::ListUtils::contains
static bool contains(const std::vector< T > &container, const E &elem)
Checks whether the element elem is contained in the given container.
Definition: ListUtils.h:162
OpenMS::MSSpectrum::getRT
double getRT() const
OpenMS::HasPrecursorCharge::HasPrecursorCharge
HasPrecursorCharge(const IntList &charges, bool reverse=false)
Constructor.
Definition: RangeUtils.h:441
OpenMS::IsZoomSpectrum::reverse_
bool reverse_
Definition: RangeUtils.h:322
OpenMS::IsInIsolationWindowSizeRange::reverse_
bool reverse_
Definition: RangeUtils.h:635
OpenMS::IsZoomSpectrum::operator()
bool operator()(const SpectrumType &s) const
Definition: RangeUtils.h:315
OpenMS::IsInCollisionEnergyRange::operator()
bool operator()(const SpectrumType &s) const
Definition: RangeUtils.h:564
OpenMS::Peak2D::getIntensity
IntensityType getIntensity() const
Definition: Peak2D.h:166
OpenMS::IsZoomSpectrum
Predicate that determines if a spectrum is a zoom (enhanced resolution) spectrum.
Definition: RangeUtils.h:302
OpenMS::IsInIsolationWindow::IsInIsolationWindow
IsInIsolationWindow(std::vector< double > vec_mz, bool reverse=false)
Constructor.
Definition: RangeUtils.h:655
OpenMS::IntList
std::vector< Int > IntList
Vector of signed integers.
Definition: ListUtils.h:55
OPENMS_LOG_WARN
#define OPENMS_LOG_WARN
Macro if a warning, a piece of information which should be read by the user, should be logged.
Definition: LogStream.h:460
ListUtils.h
OpenMS::IsInIsolationWindow::vec_mz_
std::vector< double > vec_mz_
Definition: RangeUtils.h:689
OpenMS::HasPrecursorCharge::charges_
IntList charges_
Definition: RangeUtils.h:460
OpenMS::InPrecursorMZRange::mz_right_
double mz_right_
Definition: RangeUtils.h:417
OpenMS::InMSLevelRange::InMSLevelRange
InMSLevelRange(const IntList &levels, bool reverse=false)
Constructor.
Definition: RangeUtils.h:178
OpenMS::HasScanMode::operator()
bool operator()(const SpectrumType &s) const
Definition: RangeUtils.h:218
OpenMS::SpectrumSettings::getInstrumentSettings
const InstrumentSettings & getInstrumentSettings() const
returns a const reference to the instrument settings of the current spectrum
OpenMS::Precursor
Precursor meta information.
Definition: Precursor.h:58
OpenMS::InMzRange::reverse_
bool reverse_
Definition: RangeUtils.h:501
OpenMS::Int
int Int
Signed integer type.
Definition: Types.h:102
OpenMS::MSSpectrum::getMSLevel
UInt getMSLevel() const
Returns the MS level.
OpenMS::InPrecursorMZRange
Predicate that determines if a spectrum's precursor is within a certain m/z range.
Definition: RangeUtils.h:383
OpenMS::HasScanPolarity::reverse_
bool reverse_
Definition: RangeUtils.h:260
OpenMS
Main OpenMS namespace.
Definition: FeatureDeconvolution.h:47
OpenMS::HasMetaValue::operator()
bool operator()(const MetaContainer &s) const
Definition: RangeUtils.h:110
OpenMS::InMSLevelRange::levels_
IntList levels_
Definition: RangeUtils.h:191
OpenMS::InRTRange::min_
double min_
Definition: RangeUtils.h:156
OpenMS::InMzRange::max_
double max_
Definition: RangeUtils.h:500
OpenMS::HasScanMode
Predicate that determines if a spectrum has a certain scan mode.
Definition: RangeUtils.h:203
OpenMS::IsEmptySpectrum
Predicate that determines if a spectrum is empty.
Definition: RangeUtils.h:272
OpenMS::IsEmptySpectrum::operator()
bool operator()(const SpectrumType &s) const
Definition: RangeUtils.h:284
OpenMS::IsInCollisionEnergyRange
Predicate that determines if an MSn spectrum was generated with a collision energy in the given range...
Definition: RangeUtils.h:548
OpenMS::InIntensityRange::max_
double max_
Definition: RangeUtils.h:536
OpenMS::InRTRange
Predicate that determines if a spectrum lies inside/outside a specific retention time range.
Definition: RangeUtils.h:131
OpenMS::HasScanMode::reverse_
bool reverse_
Definition: RangeUtils.h:226
OpenMS::InMzRange
Predicate that determines if a peak lies inside/outside a specific m/z range.
Definition: RangeUtils.h:475
OpenMS::InPrecursorMZRange::mz_left_
double mz_left_
Definition: RangeUtils.h:416
OpenMS::IsInIsolationWindowSizeRange::max_size_
double max_size_
Definition: RangeUtils.h:634
OpenMS::InRTRange::operator()
bool operator()(const SpectrumType &s) const
Definition: RangeUtils.h:148
OpenMS::StringList
std::vector< String > StringList
Vector of String.
Definition: ListUtils.h:70
OpenMS::IsInIsolationWindow
Predicate that determines if the isolation window covers ANY of the given m/z values.
Definition: RangeUtils.h:645
OpenMS::IsZoomSpectrum::IsZoomSpectrum
IsZoomSpectrum(bool reverse=false)
Constructor.
Definition: RangeUtils.h:311
OpenMS::IsInCollisionEnergyRange::IsInCollisionEnergyRange
IsInCollisionEnergyRange(double min, double max, bool reverse=false)
Constructor.
Definition: RangeUtils.h:558
OpenMS::HasScanMode::mode_
Int mode_
Definition: RangeUtils.h:225
OpenMS::HasPrecursorCharge
Predicate that determines if a spectrum has a certain precursor charge as given in the constructor li...
Definition: RangeUtils.h:431
OpenMS::HasActivationMethod
Predicate that determines if a spectrum was generated using any activation method given in the constr...
Definition: RangeUtils.h:335
OpenMS::HasActivationMethod::HasActivationMethod
HasActivationMethod(const StringList &methods, bool reverse=false)
Constructor.
Definition: RangeUtils.h:345
Precursor.h
OpenMS::InMSLevelRange::operator()
bool operator()(const SpectrumType &s) const
Definition: RangeUtils.h:183
OpenMS::InstrumentSettings::getPolarity
IonSource::Polarity getPolarity() const
returns the polarity
OpenMS::IsInCollisionEnergyRange::reverse_
bool reverse_
Definition: RangeUtils.h:590
OpenMS::IsInIsolationWindowSizeRange::operator()
bool operator()(const SpectrumType &s) const
Definition: RangeUtils.h:617
OpenMS::IsInCollisionEnergyRange::min_energy_
double min_energy_
Definition: RangeUtils.h:589
OpenMS::IsInCollisionEnergyRange::max_energy_
double max_energy_
Definition: RangeUtils.h:589
OpenMS::InIntensityRange::InIntensityRange
InIntensityRange(double min, double max, bool reverse=false)
Constructor.
Definition: RangeUtils.h:522
OpenMS::HasScanPolarity::HasScanPolarity
HasScanPolarity(Int polarity, bool reverse=false)
Constructor.
Definition: RangeUtils.h:247
OpenMS::InMzRange::min_
double min_
Definition: RangeUtils.h:500
OpenMS::Peak2D::getPosition
const PositionType & getPosition() const
Non-mutable access to the position.
Definition: Peak2D.h:178
OpenMS::IsInIsolationWindow::reverse_
bool reverse_
Definition: RangeUtils.h:690
OpenMS::InPrecursorMZRange::reverse_
bool reverse_
Definition: RangeUtils.h:418
OpenMS::InRTRange::max_
double max_
Definition: RangeUtils.h:156
OpenMS::HasMetaValue::metavalue_key_
String metavalue_key_
Definition: RangeUtils.h:118
OpenMS::InstrumentSettings::getZoomScan
bool getZoomScan() const
return if this scan is a zoom (enhanced resolution) scan
OpenMS::Precursor::NamesOfActivationMethod
static const std::string NamesOfActivationMethod[SIZE_OF_ACTIVATIONMETHOD]
Names of activation methods.
Definition: Precursor.h:106
OpenMS::HasPrecursorCharge::operator()
bool operator()(const SpectrumType &s) const
Definition: RangeUtils.h:446
OpenMS::InRTRange::reverse_
bool reverse_
Definition: RangeUtils.h:157
OpenMS::InRTRange::InRTRange
InRTRange(double min, double max, bool reverse=false)
Constructor.
Definition: RangeUtils.h:142
OpenMS::InMSLevelRange::reverse_
bool reverse_
Definition: RangeUtils.h:192
OpenMS::IsInIsolationWindowSizeRange::min_size_
double min_size_
Definition: RangeUtils.h:634
OpenMS::MSSpectrum
The representation of a 1D spectrum.
Definition: MSSpectrum.h:66
OpenMS::Precursor::ActivationMethod
ActivationMethod
Method of activation.
Definition: Precursor.h:84
OpenMS::IsInIsolationWindowSizeRange::IsInIsolationWindowSizeRange
IsInIsolationWindowSizeRange(double min_size, double max_size, bool reverse=false)
Constructor.
Definition: RangeUtils.h:611
OpenMS::InstrumentSettings::getScanMode
ScanMode getScanMode() const
returns the scan mode
OpenMS::HasActivationMethod::methods_
StringList methods_
Definition: RangeUtils.h:369
OpenMS::HasActivationMethod::reverse_
bool reverse_
Definition: RangeUtils.h:370
OpenMS::HasScanPolarity::polarity_
Int polarity_
Definition: RangeUtils.h:259
OpenMS::InIntensityRange
Predicate that determines if a peak lies inside/outside a specific intensity range.
Definition: RangeUtils.h:512
OpenMS::InPrecursorMZRange::operator()
bool operator()(const SpectrumType &s) const
Definition: RangeUtils.h:399
OpenMS::InMSLevelRange
Predicate that determines if a spectrum lies inside/outside a specific MS level set.
Definition: RangeUtils.h:168
OpenMS::IsEmptySpectrum::IsEmptySpectrum
IsEmptySpectrum(bool reverse=false)
Constructor.
Definition: RangeUtils.h:280
OpenMS::HasScanPolarity::operator()
bool operator()(const SpectrumType &s) const
Definition: RangeUtils.h:252
OpenMS::InMzRange::operator()
bool operator()(const PeakType &p) const
Definition: RangeUtils.h:492
OpenMS::HasMetaValue::HasMetaValue
HasMetaValue(String metavalue, bool reverse=false)
Constructor.
Definition: RangeUtils.h:105
OpenMS::HasMetaValue
Predicate that determines if a class has a certain metavalue.
Definition: RangeUtils.h:96