28 TString measurement_type(
"");
30 measurement_type =
fPrefix[type];
31 if (measurement_type[0] ==
'a' &&
33 || (suffix ==
"p" || suffix ==
"a"
37 measurement_type[0] =
'd';
38 }
else if (measurement_type[0] ==
'y') {
39 measurement_type += suffix;
43 << type <<
", " << suffix
44 <<
" \'" << measurement_type.Data() <<
"\'" <<
QwLog::endl;
45 return measurement_type;
86 template<> QwParitySSQLS::md_data
87 QwDBInterface::TypedDBClone<QwParitySSQLS::md_data>() {
88 QwParitySSQLS::md_data row(0);
89 row.analysis_id = fAnalysisId;
90 row.main_detector_id = fDeviceId;
91 row.measurement_type_id = fMeasurementTypeId;
92 row.subblock = fSubblock;
98 template<> QwParitySSQLS::lumi_data
99 QwDBInterface::TypedDBClone<QwParitySSQLS::lumi_data>() {
100 QwParitySSQLS::lumi_data row(0);
101 row.analysis_id = fAnalysisId;
102 row.lumi_detector_id = fDeviceId;
103 row.measurement_type_id = fMeasurementTypeId;
104 row.subblock = fSubblock;
110 template<> QwParitySSQLS::beam
111 QwDBInterface::TypedDBClone<QwParitySSQLS::beam>() {
112 QwParitySSQLS::beam row(0);
113 row.analysis_id = fAnalysisId;
114 row.monitor_id = fDeviceId;
115 row.measurement_type_id = fMeasurementTypeId;
116 row.subblock = fSubblock;
152 template<> QwParitySSQLS::md_errors
153 QwErrDBInterface::TypedDBClone<QwParitySSQLS::md_errors>() {
154 QwParitySSQLS::md_errors row(0);
155 row.analysis_id = fAnalysisId;
156 row.main_detector_id = fDeviceId;
157 row.error_code_id = fErrorCodeId;
163 template<> QwParitySSQLS::lumi_errors
164 QwErrDBInterface::TypedDBClone<QwParitySSQLS::lumi_errors>() {
165 QwParitySSQLS::lumi_errors row(0);
166 row.analysis_id = fAnalysisId;
167 row.lumi_detector_id = fDeviceId;
168 row.error_code_id = fErrorCodeId;
176 template<> QwParitySSQLS::beam_errors
177 QwErrDBInterface::TypedDBClone<QwParitySSQLS::beam_errors>() {
178 QwParitySSQLS::beam_errors row(0);
179 row.analysis_id = fAnalysisId;
180 row.monitor_id = fDeviceId;
181 row.error_code_id = fErrorCodeId;
187 template<> QwParitySSQLS::general_errors
188 QwErrDBInterface::TypedDBClone<QwParitySSQLS::general_errors>() {
189 QwParitySSQLS::general_errors row(0);
190 row.analysis_id = fAnalysisId;
191 row.error_code_id = fErrorCodeId;
void SetLumiDetectorID(QwParityDB *db)
UInt_t GetMonitorID(const string &name, Bool_t zero_id_is_error=kTRUE)
void SetMainDetectorID(QwParityDB *db)
UInt_t GetMainDetectorID(const string &name, Bool_t zero_id_is_error=kTRUE)
EQwDBIDataTableType SetDetectorID(QwParityDB *db)
static std::map< TString, TString > fPrefix
UInt_t GetLumiDetectorID(const string &name, Bool_t zero_id_is_error=kTRUE)
void SetLumiDetectorID(QwParityDB *db)
void SetMonitorID(QwParityDB *db)
#define QwDebug
Predefined log drain for debugging output.
static const double T
Magnetic field: base unit is T.
void SetMonitorID(QwParityDB *db)
void SetMainDetectorID(QwParityDB *db)
static std::ostream & endl(std::ostream &)
End of the line.
static TString DetermineMeasurementTypeID(TString type, TString suffix="", Bool_t forcediffs=kFALSE)