37 reader.enterContainer();
38 qDebug() << txt_value;
39 while(reader.hasNext() && (!reader.isInvalid()))
45 qDebug() << txt_value;
46 if(txt_value ==
"cvParam")
66 reader.leaveContainer();
77 QObject::tr(
"isolation window target m/z MS:1000827 not found in cvParam map"));
80 return it->second.valueDouble;
93 QObject::tr(
"isolation window lower offset MS:1000828 not found in cvParam map"));
96 return mz - it->second.valueDouble;
102 QJsonObject isolationWindow;
103 isolationWindow.insert(
"cvParam",
cvParamMap.toJsonArray());
104 return isolationWindow;
109 QJsonObject precursor;
127 QObject::tr(
"isolation window upper offset MS:1000829 not found in cvParam map"));
130 return mz + it->second.valueDouble;
137 reader.enterContainer();
138 qDebug() << txt_value;
139 while(reader.hasNext() && (!reader.isInvalid()))
141 if(reader.isString())
145 qDebug() << txt_value;
146 if(txt_value ==
"cvParam")
166 reader.leaveContainer();
180 QObject::tr(
"Charge state not found in SelectedIon cvParam map"));
182 qDebug() << it->first <<
" " << it->second.valueInt;
183 return it->second.valueInt;
197 QObject::tr(
"Intensity not found in SelectedIon cvParam map"));
199 qDebug() << it->first <<
" " << it->second.valueInt;
200 return it->second.valueInt;
215 qDebug() << it->first <<
" " << it->second.valueDouble;
216 return it->second.valueDouble;
225 reader.enterContainer();
226 qDebug() << txt_value;
227 while(reader.hasNext() && (!reader.isInvalid()))
229 if(reader.isString())
233 qDebug() << txt_value;
234 if(txt_value ==
"cvParam")
239 else if(txt_value ==
"isolationWindow")
243 else if(txt_value ==
"selectedIonList")
246 reader.enterContainer();
248 while(reader.hasNext() && (!reader.isInvalid()))
250 if(reader.isString())
254 qDebug() << txt_value;
255 if(txt_value ==
"cvParam")
259 else if(txt_value ==
"selectedIon")
262 reader.enterContainer();
264 while(reader.hasNext() && (!reader.isInvalid()))
270 reader.leaveContainer();
287 reader.leaveContainer();
289 else if(txt_value ==
"activation")
295 else if(txt_value ==
"spectrumRef")
298 qDebug() << txt_value;
316 reader.leaveContainer();
simple override of the raw QCborStreamReader This adds convenient functions to put CBOR data into C++...
bool decodeString(QString &the_str)
decode the current cbor value as a string the point to the next value the current value is decoded as...
PSI precursor object for mzML/mzCBOR.
double getUpperMz() const
compute isolation window upper m/z given cvParam informations
double getLowerMz() const
compute isolation window lower m/z given cvParam informations
double getTargetMz() const
get isolation window target m/z given cvParam informations
QJsonObject toJsonObject() const
write the structure to a JSON object
void fromCbor(CborStreamReader &reader)
IsolationWindow isolationWindow
QJsonObject toJsonObject() const
write the structure to a JSON object
std::vector< SelectedIon > selectedIonList
CvParamMap selectedIonListCvParamMap
void fromCbor(CborStreamReader &reader)
int getChargeState() const
qint64 getIntensity() const
void fromCbor(CborStreamReader &reader)