Loading...
Searching...
No Matches
pappso::TimsMsRunReaderDia Class Reference

`#include <timsmsrunreaderdia.h>`

Inheritance diagram for pappso::TimsMsRunReaderDia:

## Public Member Functions

| TimsMsRunReaderDia (MsRunIdCstSPtr &msrun_id_csp)
| TimsMsRunReaderDia (const TimsMsRunReaderBase &msrun_reader_base)
virtual | ~TimsMsRunReaderDia ()
virtual MassSpectrumSPtr | massSpectrumSPtr (std::size_t spectrum_index) override
| get a MassSpectrumSPtr class given its spectrum index
virtual MassSpectrumCstSPtr | massSpectrumCstSPtr (std::size_t spectrum_index) override
virtual QualifiedMassSpectrum | qualifiedMassSpectrum (std::size_t spectrum_index, bool want_binary_data=true) const override
| get a QualifiedMassSpectrum class given its scan number
virtual XicCoordSPtr | newXicCoordSPtrFromSpectrumIndex (std::size_t spectrum_index, PrecisionPtr precision) const override
| get a xic coordinate object from a given spectrum index
virtual XicCoordSPtr | newXicCoordSPtrFromQualifiedMassSpectrum (const QualifiedMassSpectrum &mass_spectrum, PrecisionPtr precision) const override
| get a xic coordinate object from a given spectrum
virtual std::size_t | spectrumListSize () const override
| get the totat number of spectrum conained in the MSrun data file
virtual void | readSpectrumCollection (SpectrumCollectionHandlerInterface &handler) override
| function to visit an MsRunReader and get each Spectrum in a spectrum collection handler
virtual void | readSpectrumCollection2 (const MsRunReadConfig &config, SpectrumCollectionHandlerInterface &handler) override
virtual void | readSpectrumCollectionByMsLevel (SpectrumCollectionHandlerInterface &handler, unsigned int ms_level) override
| function to visit an MsRunReader and get each Spectrum in a spectrum collection handler by Ms Levels
virtual bool | acquireDevice () override
| acquire data back end device
Public Member Functions inherited from pappso::TimsMsRunReaderBase
| TimsMsRunReaderBase (MsRunIdCstSPtr &msrun_id_csp)
| TimsMsRunReaderBase (const TimsMsRunReaderBase &msrun_reader_base)
virtual | ~TimsMsRunReaderBase ()
virtual TimsDataSp | getTimsDataSPtr ()
| give an access to the underlying raw data pointer
virtual bool | hasScanNumbers () const override
| tells if spectra can be accessed using scan numbers by default, it returns false. Only overrided functions can check if scan numbers are available in the current file
virtual bool | releaseDevice () override
| release data back end device if a the data back end is released, the developper has to use acquireDevice before using the msrunreader object
virtual Trace | getTicChromatogram () override
| get a TIC chromatogram
virtual std::vector< double > | getRetentionTimeLine () override
| retention timeline get retention times along the MSrun in seconds
Public Member Functions inherited from pappso::MsRunReader
| MsRunReader (const MsRunIdCstSPtr &ms_run_id)
| MsRunReader (const MsRunReader &other)
virtual | ~MsRunReader ()
const MsRunIdCstSPtr & | getMsRunId () const
virtual std::size_t | scanNumber2SpectrumIndex (std::size_t scan_number)
| if possible, converts a scan number into a spectrum index This is a convenient function to help transition from the old scan number (not implemented by all vendors) to more secure spectrum index (not vendor dependant). It is better to not rely on this function.
void | setMonoThread (bool is_mono_thread)
| set only one is_mono_thread to true
bool | isMonoThread () const

## Protected Member Functions

virtual void | initialize () override
Protected Member Functions inherited from pappso::TimsMsRunReaderBase
virtual bool | accept (const QString &file_name) const override
| tells if the reader is able to handle this file must be implemented by private MS run reader, specific of one or more file format

## Private Attributes

TimsDiaSlices * | mp_timsDiaSlices = nullptr

## Friends

class | MsFileAccessor

## Additional Inherited Members

Protected Attributes inherited from pappso::TimsMsRunReaderBase
TimsDataSp | msp_timsData = nullptr
Protected Attributes inherited from pappso::MsRunReader
MsRunIdCstSPtr | mcsp_msRunId
MsRunReaderScanNumberMultiMap * | mpa_multiMapScanNumber = nullptr

## Detailed Description

Definition at line 44 of file timsmsrunreaderdia.h.

## Constructor & Destructor Documentation

## TimsMsRunReaderDia() [1/2]

pappso::TimsMsRunReaderDia::TimsMsRunReaderDia | ( | MsRunIdCstSPtr & | msrun_id_csp | ) |

Default constructor

Definition at line 38 of file timsmsrunreaderdia.cpp.

: TimsMsRunReaderBase(msrun_id_csp)
{
// qInfo() << msp_timsData.get();
initialize();
}
pappso::TimsMsRunReaderBase::TimsMsRunReaderBase
TimsMsRunReaderBase(MsRunIdCstSPtr &msrun_id_csp)
Definition timsmsrunreaderbase.cpp:36
pappso::TimsMsRunReaderDia::initialize
virtual void initialize() override
Definition timsmsrunreaderdia.cpp:59

References initialize().

## TimsMsRunReaderDia() [2/2]

pappso::TimsMsRunReaderDia::TimsMsRunReaderDia | ( | const TimsMsRunReaderBase & | msrun_reader_base | ) |

Definition at line 46 of file timsmsrunreaderdia.cpp.

: TimsMsRunReaderBase(msrun_reader_base)
{
initialize();
}

References initialize().

## ~TimsMsRunReaderDia()

pappso::TimsMsRunReaderDia::~TimsMsRunReaderDia | ( |  | ) |

virtual

Destructor

Definition at line 53 of file timsmsrunreaderdia.cpp.

{
}

## Member Function Documentation

## acquireDevice()

bool pappso::TimsMsRunReaderDia::acquireDevice | ( |  | ) |

override virtual

acquire data back end device

Returns
  bool true if done

Reimplemented from pappso::TimsMsRunReaderBase.

Definition at line 168 of file timsmsrunreaderdia.cpp.

{
if(TimsMsRunReaderBase::acquireDevice())
{
qDebug() << msp_timsData.get();
mp_timsDiaSlices = msp_timsData.get()->getTimsDiaSlicesPtr();
return true;
}
return false;
qDebug();
}
pappso::TimsMsRunReaderBase::msp_timsData
TimsDataSp msp_timsData
Definition timsmsrunreaderbase.h:84
pappso::TimsMsRunReaderBase::acquireDevice
virtual bool acquireDevice() override
acquire data back end device
Definition timsmsrunreaderbase.cpp:96
pappso::TimsMsRunReaderDia::mp_timsDiaSlices
TimsDiaSlices * mp_timsDiaSlices
Definition timsmsrunreaderdia.h:115

References pappso::TimsMsRunReaderBase::acquireDevice(), mp_timsDiaSlices, and pappso::TimsMsRunReaderBase::msp_timsData.

## initialize()

void pappso::TimsMsRunReaderDia::initialize | ( |  | ) |

override protected virtual

Reimplemented from pappso::TimsMsRunReaderBase.

Definition at line 59 of file timsmsrunreaderdia.cpp.

{
qDebug();
if(msp_timsData == nullptr)
msp_timsData =
std::make_shared<TimsData>(mcsp_msRunId.get()->getFileName());
if(msp_timsData.get() == nullptr)
{
throw PappsoException(
QObject::tr("ERROR in TimsMsRunReaderDia::initialize "
"msp_timsData is null for MsRunId %1")
.arg(mcsp_msRunId.get()->toString()));
}
qDebug();
qDebug() << msp_timsData.get();
mp_timsDiaSlices = msp_timsData.get()->getTimsDiaSlicesPtr();
qDebug();
}
pappso::MsRunReader::mcsp_msRunId
MsRunIdCstSPtr mcsp_msRunId
Definition msrunreader.h:175

Referenced by TimsMsRunReaderDia(), and TimsMsRunReaderDia().

## massSpectrumCstSPtr()

MassSpectrumCstSPtr pappso::TimsMsRunReaderDia::massSpectrumCstSPtr | ( | std::size_t | spectrum_index | ) |

override virtual

Implements pappso::MsRunReader.

Definition at line 152 of file timsmsrunreaderdia.cpp.

{
throw ExceptionNotImplemented(QObject::tr("Not implemented %1 %2 %3")
.arg(__FILE__)
.arg(__FUNCTION__)
.arg(__LINE__));
}

## massSpectrumSPtr()

MassSpectrumSPtr pappso::TimsMsRunReaderDia::massSpectrumSPtr | ( | std::size_t | spectrum_index | ) |

override virtual

get a MassSpectrumSPtr class given its spectrum index

Implements pappso::MsRunReader.

Definition at line 144 of file timsmsrunreaderdia.cpp.

{
throw ExceptionNotImplemented(QObject::tr("Not implemented %1 %2 %3")
.arg(__FILE__)
.arg(__FUNCTION__)
.arg(__LINE__));
}

## newXicCoordSPtrFromQualifiedMassSpectrum()

pappso::XicCoordSPtr pappso::TimsMsRunReaderDia::newXicCoordSPtrFromQualifiedMassSpectrum | ( | const QualifiedMassSpectrum & | mass_spectrum,
|  | pappso::PrecisionPtr | precision
| ) |  | const

override virtual

get a xic coordinate object from a given spectrum

Reimplemented from pappso::TimsMsRunReaderBase.

Definition at line 92 of file timsmsrunreaderdia.cpp.

{
throw ExceptionNotImplemented(QObject::tr("Not implemented %1 %2 %3")
.arg(__FILE__)
.arg(__FUNCTION__)
.arg(__LINE__));
}

## newXicCoordSPtrFromSpectrumIndex()

XicCoordSPtr pappso::TimsMsRunReaderDia::newXicCoordSPtrFromSpectrumIndex | ( | std::size_t | spectrum_index,
|  | pappso::PrecisionPtr | precision
| ) |  | const

override virtual

get a xic coordinate object from a given spectrum index

Reimplemented from pappso::TimsMsRunReaderBase.

Definition at line 82 of file timsmsrunreaderdia.cpp.

{
throw ExceptionNotImplemented(QObject::tr("Not implemented %1 %2 %3")
.arg(__FILE__)
.arg(__FUNCTION__)
.arg(__LINE__));
}

## qualifiedMassSpectrum()

QualifiedMassSpectrum pappso::TimsMsRunReaderDia::qualifiedMassSpectrum | ( | std::size_t | spectrum_index,
|  | bool | want_binary_data = `true`
| ) |  | const

override virtual

get a QualifiedMassSpectrum class given its scan number

Implements pappso::MsRunReader.

Definition at line 112 of file timsmsrunreaderdia.cpp.

{
// spectrum index is a global slice index
QualifiedMassSpectrum q_dia_spectrum;
mp_timsDiaSlices->getMs2QualifiedSpectrumByGlobalSliceIndex(
getMsRunId(), q_dia_spectrum, spectrum_index, want_binary_data);
return q_dia_spectrum;
}
pappso::MsRunReader::getMsRunId
const MsRunIdCstSPtr & getMsRunId() const
Definition msrunreader.cpp:57
pappso::TimsDiaSlices::getMs2QualifiedSpectrumByGlobalSliceIndex
void getMs2QualifiedSpectrumByGlobalSliceIndex(const MsRunIdCstSPtr &msrun_id, QualifiedMassSpectrum &mass_spectrum, std::size_t global_slice_index, bool want_binary_data) const
Definition timsdiaslices.cpp:367

References pappso::TimsDiaSlices::getMs2QualifiedSpectrumByGlobalSliceIndex(), pappso::MsRunReader::getMsRunId(), and mp_timsDiaSlices.

## readSpectrumCollection()

void pappso::TimsMsRunReaderDia::readSpectrumCollection | ( | SpectrumCollectionHandlerInterface & | handler | ) |

override virtual

function to visit an MsRunReader and get each Spectrum in a spectrum collection handler

Implements pappso::MsRunReader.

Definition at line 124 of file timsmsrunreaderdia.cpp.

{
throw ExceptionNotImplemented(QObject::tr("Not implemented %1 %2 %3")
.arg(__FILE__)
.arg(__FUNCTION__)
.arg(__LINE__));
}

## readSpectrumCollection2()

void pappso::TimsMsRunReaderDia::readSpectrumCollection2 | ( | const MsRunReadConfig & | config,
|  | SpectrumCollectionHandlerInterface & | handler
| ) |  |

override virtual

Implements pappso::MsRunReader.

Definition at line 134 of file timsmsrunreaderdia.cpp.

{
throw ExceptionNotImplemented(QObject::tr("Not implemented %1 %2 %3")
.arg(__FILE__)
.arg(__FUNCTION__)
.arg(__LINE__));
}

## readSpectrumCollectionByMsLevel()

void pappso::TimsMsRunReaderDia::readSpectrumCollectionByMsLevel | ( | SpectrumCollectionHandlerInterface & | handler,
|  | unsigned int | ms_level
| ) |  |

override virtual

function to visit an MsRunReader and get each Spectrum in a spectrum collection handler by Ms Levels

Implements pappso::MsRunReader.

Definition at line 102 of file timsmsrunreaderdia.cpp.

{
throw ExceptionNotImplemented(QObject::tr("Not implemented %1 %2 %3")
.arg(__FILE__)
.arg(__FUNCTION__)
.arg(__LINE__));
}

## spectrumListSize()

std::size_t pappso::TimsMsRunReaderDia::spectrumListSize | ( |  | ) | const

override virtual

get the totat number of spectrum conained in the MSrun data file

Implements pappso::MsRunReader.

Definition at line 161 of file timsmsrunreaderdia.cpp.

{
return mp_timsDiaSlices->getTotalSlicesCount();
}
pappso::TimsDiaSlices::getTotalSlicesCount
std::size_t getTotalSlicesCount() const
get the number of DIA MS2 slices analyzed by PASEF
Definition timsdiaslices.cpp:295

References pappso::TimsDiaSlices::getTotalSlicesCount(), and mp_timsDiaSlices.

## Friends And Related Symbol Documentation

## MsFileAccessor

friend class MsFileAccessor

friend

Definition at line 46 of file timsmsrunreaderdia.h.

## Member Data Documentation

## mp_timsDiaSlices

TimsDiaSlices* pappso::TimsMsRunReaderDia::mp_timsDiaSlices = nullptr

private

Definition at line 115 of file timsmsrunreaderdia.h.

Referenced by acquireDevice(), qualifiedMassSpectrum(), and spectrumListSize().

The documentation for this class was generated from the following files:

- pappsomspp/msrun/private/timsmsrunreaderdia.h
- pappsomspp/msrun/private/timsmsrunreaderdia.cpp