| OpenMS 2.5.0

Public Member Functions | Protected Attributes | List of all members
HasScanMode< SpectrumType > Class Template Reference
Kernel » RangeUtils

Predicate that determines if a spectrum has a certain scan mode. More...

`#include <OpenMS/KERNEL/RangeUtils.h>`

Inheritance diagram for HasScanMode< SpectrumType >:

## Public Member Functions

| HasScanMode (Int mode, bool reverse=false)
| Constructor. More...
bool | operator() (const SpectrumType &s) const

## Protected Attributes

Int | mode_
bool | reverse_

## Detailed Description

### template<class SpectrumType>
class OpenMS::HasScanMode< SpectrumType >

Predicate that determines if a spectrum has a certain scan mode.

SpectrumType must be a Spectrum or have the same interface (SpectrumSettings)

## Constructor & Destructor Documentation

## ◆ HasScanMode()

HasScanMode | ( | Int | mode,
|  | bool | reverse = `false`
| ) |  |

inline

Constructor.

Parameters

  mode | scan mode
  reverse | if `reverse` is true, operator() returns true if the spectrum has a different scan mode

## Member Function Documentation

## ◆ operator()()

bool operator() | ( | const SpectrumType & | s | ) | const

inline

References SpectrumSettings::getInstrumentSettings(), InstrumentSettings::getScanMode(), HasScanMode< SpectrumType >::mode_, and HasScanMode< SpectrumType >::reverse_.

## Member Data Documentation

## ◆ mode_

Int mode_

protected

Referenced by HasScanMode< SpectrumType >::operator()().

## ◆ reverse_

bool reverse_

protected

Referenced by HasScanMode< SpectrumType >::operator()().