libpappsomspp
Library for mass spectrometry
|
#include <cboroutputstream.h>
Public Member Functions | |
CborOutputStream (QIODevice *device) | |
virtual | ~CborOutputStream () |
void | setIsTraceOutput (bool is_trace_output) |
set trace output flag | |
void | setIsPeakShapeOutput (bool is_shape_output, double margin_in_seconds) |
set peak shape output flag | |
void | writeJsonObject (const QString &name, const QJsonObject &json_object) |
void | writeProjectParameters (const pappso::ProjectParameters &project_parameters) |
void | writeActionBegin (const QString &operation) |
void | close () |
QCborStreamWriter & | getCborStreamWriter () |
void | writeQrDataBlock (pappso::UiMonitorInterface &m_uiMonitor, const MsRunPeptideList &msrun_peptide_list, bool is_mbr) |
void | writeMsRunRetentionTime (const pappso::Trace &report_common_ms2, const pappso::MsRunRetentionTime< QString > &msrun_retention_time) |
Private Member Functions | |
void | writeMbrPeptideMeasurements (const MbrPeptideMeasurements &peptide_measurements, const pappso::MsRunRetentionTime< QString > *msrun_retention_time_p) |
void | writeMeasurement (const PeptideMeasurements::Measurement &measurement, const pappso::MsRunRetentionTime< QString > *msrun_retention_time_p) |
void | writeTrace (const pappso::Trace &trace) |
void | writeVectorDouble (const std::vector< double > &vector) |
void | writeTracePeak (const pappso::TracePeak &peak, const pappso::MsRunRetentionTime< QString > *msrun_retention_time_p) |
void | writeActionEnd () |
void | writeMsRun (const MsRun &msrun) |
void | writePeptideMeasurements (const PeptideMeasurements &peptide_measurements, const pappso::MsRunRetentionTime< QString > *msrun_retention_time_p) |
Private Attributes | |
pappso::cbor::CborStreamWriter * | mpa_writer = nullptr |
bool | m_isTraceOutput = false |
bool | m_isPeakShapeOutput = false |
bool | m_isXicCoordOutput = true |
double | m_peakShapeMarginInSeconds = 20 |
Definition at line 50 of file cboroutputstream.h.
pappso::masschroq::CborOutputStream::CborOutputStream | ( | QIODevice * | device | ) |
Default constructor
Definition at line 42 of file cboroutputstream.cpp.
References mpa_writer.
|
virtual |
void pappso::masschroq::CborOutputStream::close | ( | ) |
Definition at line 84 of file cboroutputstream.cpp.
References mpa_writer, and writeActionEnd().
QCborStreamWriter & pappso::masschroq::CborOutputStream::getCborStreamWriter | ( | ) |
Definition at line 103 of file cboroutputstream.cpp.
References mpa_writer.
Referenced by pappso::masschroq::JsonInput::action(), pappso::masschroq::MsRunGroup::align(), pappso::masschroq::MsRunGroup::alignRetentionTimeBetweenMsRuns(), pappso::masschroq::MsRunGroup::quantify(), and pappso::masschroq::JsonInput::readAction().
void pappso::masschroq::CborOutputStream::setIsPeakShapeOutput | ( | bool | is_shape_output, |
double | margin_in_seconds ) |
set peak shape output flag
Definition at line 53 of file cboroutputstream.cpp.
References m_isPeakShapeOutput, and m_peakShapeMarginInSeconds.
void pappso::masschroq::CborOutputStream::setIsTraceOutput | ( | bool | is_trace_output | ) |
set trace output flag
Definition at line 61 of file cboroutputstream.cpp.
References m_isTraceOutput.
void pappso::masschroq::CborOutputStream::writeActionBegin | ( | const QString & | operation | ) |
Definition at line 67 of file cboroutputstream.cpp.
References pappso::masschroq::Utils::getVersion(), and mpa_writer.
Referenced by pappso::masschroq::JsonInput::action().
|
private |
Definition at line 75 of file cboroutputstream.cpp.
References mpa_writer.
Referenced by close().
void pappso::masschroq::CborOutputStream::writeJsonObject | ( | const QString & | name, |
const QJsonObject & | json_object ) |
Definition at line 93 of file cboroutputstream.cpp.
References mpa_writer.
Referenced by pappso::masschroq::JsonInput::action().
|
private |
Definition at line 302 of file cboroutputstream.cpp.
References pappso::masschroq::Peptide::getId(), pappso::masschroq::PeptideMeasurementsBase::getMeasurementList(), pappso::masschroq::Peptide::getMods(), pappso::masschroq::PeptideBase::getPappsoPeptideSp(), pappso::masschroq::MbrPeptideMeasurements::getPeptideSp(), mpa_writer, and writeMeasurement().
Referenced by writeQrDataBlock().
|
private |
Definition at line 165 of file cboroutputstream.cpp.
References pappso::masschroq::Utils::enumToString(), pappso::masschroq::PeptideLabel::getLabel(), pappso::masschroq::PeptideMeasurementsBase::Measurement::m_charge, m_isPeakShapeOutput, m_isTraceOutput, m_isXicCoordOutput, pappso::masschroq::PeptideMeasurementsBase::Measurement::m_peakQualityCategory, m_peakShapeMarginInSeconds, pappso::masschroq::PeptideMeasurementsBase::Measurement::m_peptideNaturalIsotopeAverageSp, pappso::masschroq::PeptideMeasurementsBase::Measurement::m_tracePeakSp, pappso::masschroq::PeptideMeasurementsBase::Measurement::mp_peptideLabel, mpa_writer, pappso::masschroq::PeptideMeasurementsBase::Measurement::msp_xicCoord, writeTrace(), and writeTracePeak().
Referenced by writeMbrPeptideMeasurements(), and writePeptideMeasurements().
|
private |
Definition at line 110 of file cboroutputstream.cpp.
References pappso::masschroq::MsRun::getMsRunReaderSPtr(), and mpa_writer.
Referenced by writeQrDataBlock().
void pappso::masschroq::CborOutputStream::writeMsRunRetentionTime | ( | const pappso::Trace & | report_common_ms2, |
const pappso::MsRunRetentionTime< QString > & | msrun_retention_time ) |
Definition at line 434 of file cboroutputstream.cpp.
References pappso::FilterMorphoWindowBase::filter(), pappso::MsRunRetentionTime< T >::getAlignedRetentionTimeVector(), pappso::MsRunRetentionTime< T >::getMs1RetentionTimeVector(), pappso::MsRunRetentionTime< T >::getMs2MeanFilter(), pappso::MsRunRetentionTime< T >::getMs2MedianFilter(), mpa_writer, writeTrace(), writeVectorDouble(), and pappso::Trace::yValues().
Referenced by pappso::masschroq::MsRunGroup::alignRetentionTimeBetweenMsRuns().
|
private |
Definition at line 125 of file cboroutputstream.cpp.
References pappso::masschroq::Peptide::getId(), pappso::masschroq::PeptideMeasurementsBase::getMeasurementList(), pappso::masschroq::Peptide::getMods(), pappso::masschroq::PeptideBase::getPappsoPeptideSp(), pappso::masschroq::PeptideMeasurements::getPeptideObservationSp(), pappso::masschroq::PeptideObservation::getPeptideSp(), mpa_writer, and writeMeasurement().
Referenced by writeQrDataBlock().
void pappso::masschroq::CborOutputStream::writeProjectParameters | ( | const pappso::ProjectParameters & | project_parameters | ) |
Definition at line 427 of file cboroutputstream.cpp.
References mpa_writer, and pappso::ProjectParameters::writeParameters().
Referenced by pappso::masschroq::JsonInput::action().
void pappso::masschroq::CborOutputStream::writeQrDataBlock | ( | pappso::UiMonitorInterface & | m_uiMonitor, |
const MsRunPeptideList & | msrun_peptide_list, | ||
bool | is_mbr ) |
Definition at line 340 of file cboroutputstream.cpp.
References pappso::UiMonitorInterface::count(), pappso::masschroq::MsRunPeptideList::getMbrPeptideMeasurementsList(), pappso::masschroq::MsRun::getMsRunReaderSPtr(), pappso::masschroq::MsRunPeptideList::getMsRunRetentionTimeConstPtr(), pappso::masschroq::MsRunPeptideList::getMsRunSp(), pappso::masschroq::MsRunPeptideList::getPeptideMeasurementsList(), mpa_writer, pappso::UiMonitorInterface::setStatus(), pappso::UiMonitorInterface::setTotalSteps(), writeMbrPeptideMeasurements(), writeMsRun(), and writePeptideMeasurements().
Referenced by pappso::masschroq::MsRunGroup::quantify().
|
private |
Definition at line 244 of file cboroutputstream.cpp.
References mpa_writer, pappso::x, pappso::Trace::xValues(), pappso::y, and pappso::Trace::yValues().
Referenced by writeMeasurement(), and writeMsRunRetentionTime().
|
private |
Definition at line 267 of file cboroutputstream.cpp.
References pappso::TracePeak::getArea(), pappso::TracePeak::getLeftBoundary(), pappso::TracePeak::getMaxXicElement(), pappso::TracePeak::getRightBoundary(), pappso::MsRunRetentionTime< T >::isAligned(), mpa_writer, pappso::MsRunRetentionTime< T >::translateOriginal2AlignedRetentionTime(), pappso::DataPoint::x, and pappso::DataPoint::y.
Referenced by writeMeasurement().
|
private |
Definition at line 416 of file cboroutputstream.cpp.
References mpa_writer, and pappso::x.
Referenced by writeMsRunRetentionTime().
|
private |
Definition at line 115 of file cboroutputstream.h.
Referenced by setIsPeakShapeOutput(), and writeMeasurement().
|
private |
Definition at line 114 of file cboroutputstream.h.
Referenced by setIsTraceOutput(), and writeMeasurement().
|
private |
Definition at line 116 of file cboroutputstream.h.
Referenced by writeMeasurement().
|
private |
Definition at line 118 of file cboroutputstream.h.
Referenced by setIsPeakShapeOutput(), and writeMeasurement().
|
private |
Definition at line 113 of file cboroutputstream.h.
Referenced by CborOutputStream(), close(), getCborStreamWriter(), writeActionBegin(), writeActionEnd(), writeJsonObject(), writeMbrPeptideMeasurements(), writeMeasurement(), writeMsRun(), writeMsRunRetentionTime(), writePeptideMeasurements(), writeProjectParameters(), writeQrDataBlock(), writeTrace(), writeTracePeak(), and writeVectorDouble().