OpenMS
Loading...
Searching...
No Matches
ThermoRawScanReader::Accessor Class Reference

Converts scans independently of each other (random access). More...

#include <OpenMS/FORMAT/HANDLERS/ThermoRawScanReader.h>

Public Member Functions

 ~Accessor ()
 
 Accessor (const Accessor &)=delete
 
Accessor & operator= (const Accessor &)=delete
 
void convert (const ScanRecord &record, MSSpectrum &spectrum, bool peaks)
 Convert the scan of record, as ThermoRawScanReader::convert() would.
 
void readPeaks (int scan, MSSpectrum &spectrum)
 Only the peaks (and the charge array if requested by the options) of scan; spectrum is reset.
 
std::unique_ptr< Accessor > clone () const
 A new accessor on the same file; safe to call concurrently from several threads.
 

Private Member Functions

 Accessor (std::unique_ptr< Impl > impl)
 

Private Attributes

std::unique_ptr< Impl > impl_
 

Friends

class ThermoRawScanReader
 

Detailed Description

Converts scans independently of each other (random access).

Created by ThermoRawScanReader::accessor() once the records of the scans have been taken. Each accessor has its own handle on the file: one accessor must only be used by one thread at a time, but distinct accessors (e.g. from clone()) may be used concurrently. Accessors may outlive the reader that created them.

Constructor & Destructor Documentation

◆ ~Accessor()

~Accessor ( )

◆ Accessor() [1/2]

Accessor ( const Accessor &  )
delete

◆ Accessor() [2/2]

Accessor ( std::unique_ptr< Impl >  impl)
explicitprivate

Member Function Documentation

◆ clone()

std::unique_ptr< Accessor > clone ( ) const

A new accessor on the same file; safe to call concurrently from several threads.

◆ convert()

void convert ( const ScanRecord &  record,
MSSpectrum &  spectrum,
bool  peaks 
)

Convert the scan of record, as ThermoRawScanReader::convert() would.

The parent spectra for the precursor intensity estimate are decoded on demand and the most recent ones are kept in a small cache.

Parameters
[in]recordRecord of the scan from ThermoRawScanReader::record()
[out]spectrumThe converted spectrum
[in]peaksIf false, no peaks or auxiliary arrays are read (metadata only)

◆ operator=()

Accessor & operator= ( const Accessor &  )
delete

◆ readPeaks()

void readPeaks ( int  scan,
MSSpectrum &  spectrum 
)

Only the peaks (and the charge array if requested by the options) of scan; spectrum is reset.

Friends And Related Symbol Documentation

◆ ThermoRawScanReader

friend class ThermoRawScanReader
friend

Member Data Documentation

◆ impl_

std::unique_ptr<Impl> impl_
private