#include <precision.h>
Definition at line 126 of file precision.h.
◆ MapDaltonPrecision [1/2]
◆ MapDaltonPrecision [2/2]
◆ MapMzPrecision
◆ MapPpmPrecision [1/2]
◆ MapPpmPrecision [2/2]
◆ MapResPrecision [1/2]
◆ MapResPrecision [2/2]
◆ fromString() [1/2]
PrecisionPtr pappso::PrecisionFactory::fromString |
( |
const QString & |
str | ) |
|
|
static |
get a precision pointer from a string
- Parameters
-
str | is of the form : "nominal_value unit", example : "0.02 dalton" |
Definition at line 71 of file precision.cpp.
80 QStringList list = str.split(QRegExp(
"\\s+"), QString::SkipEmptyParts);
88 throw ExceptionNotPossible(
89 QObject::tr(
"ERROR getting precision from string :\nunable to "
90 "convert %1 to number in %2")
98 else if(list.size() == 2)
100 if(list[1].toLower() ==
"dalton")
105 if(list[1].toLower() ==
"ppm")
110 if(list[1].toLower() ==
"res")
115 throw ExceptionNotPossible(
116 QObject::tr(
"ERROR getting precision from string :\nprecision "
117 "unit %1 to not known in %2")
123 throw ExceptionNotPossible(QObject::tr(
"ERROR getting precision from string "
124 ":\nunable to convert %1 to precision")
References getDaltonInstance(), getPpmInstance(), and getResInstance().
Referenced by pappso::FilterChargeDeconvolution::buildFilterFromString(), and pappso::FilterComplementIonEnhancer::buildFilterFromString().
◆ fromString() [2/2]
static PrecisionPtr pappso::PrecisionFactory::fromString |
( |
const QString & |
str | ) |
|
|
static |
◆ getDaltonInstance() [1/2]
◆ getDaltonInstance() [2/2]
◆ getMzInstance()
Definition at line 239 of file massspectrumcombinerfactory.cpp.
244 MapMzPrecision::iterator it = std::find_if(
247 [value, charge](
const std::pair<pappso_double, MzPrecision *> &pair) {
248 return ((pair.first == value) && (pair.second->charge() == charge));
254 std::pair<MapMzPrecision::iterator, bool> insert_res =
255 m_mapMz.insert(std::pair<pappso_double, MzPrecision *>(
256 value,
new MzPrecision(value, charge)));
258 it = insert_res.first;
References m_mapMz.
◆ getPpmInstance() [1/2]
get a ppm precision pointer
- Parameters
-
value | the precision value in ppm |
Definition at line 149 of file precision.cpp.
152 throw ExceptionNotPossible(
153 QObject::tr(
"Fatal error at precision.cpp "
154 "-- ERROR trying to set a Resolution precision value of 0. "
155 "Program aborted."));
157 MapPpmPrecision::iterator it =
m_mapPpm.find(value);
162 std::pair<MapPpmPrecision::iterator, bool> insert_res =
163 m_mapPpm.insert(std::pair<pappso_double, PpmPrecision *>(
164 value,
new PpmPrecision(value)));
165 it = insert_res.first;
References m_mapPpm.
Referenced by pappso::MzIntegrationParams::MzIntegrationParams(), pappso::PrecisionWidget::PrecisionWidget(), pappso::MassSpectrum::equals(), fromString(), getPrecisionPtrInstance(), pappso::MzIntegrationParams::operator=(), pappso::MzIntegrationParams::reset(), and pappso::PrecisionWidget::setPpmValueChanged().
◆ getPpmInstance() [2/2]
◆ getPrecisionPtrFractionInstance()
◆ getPrecisionPtrInstance()
◆ getResInstance() [1/2]
◆ getResInstance() [2/2]
◆ m_mapDalton
◆ m_mapMz
◆ m_mapPpm
◆ m_mapRes
The documentation for this class was generated from the following files: