Auxiliary class for PMT thresholds.
More...
#include <JPMTThreshold.hh>
Auxiliary class for PMT thresholds.
Definition at line 34 of file JPMTThreshold.hh.
JDATABASE::JPMTThreshold::JPMTThreshold |
( |
| ) |
|
|
inline |
JDATABASE::JPMTThreshold::JPMTThreshold |
( |
const int |
id, |
|
|
const int |
run |
|
) |
| |
|
inline |
Constructor.
- Parameters
-
id | detector identifier |
run | run number |
Definition at line 60 of file JPMTThreshold.hh.
void configure(const int id, const int run)
Configure PMT thresholds for given detector and run.
void JDATABASE::JPMTThreshold::configure |
( |
const int |
id, |
|
|
const int |
run |
|
) |
| |
|
inline |
Configure PMT thresholds for given detector and run.
- Parameters
-
id | detector identifier |
run | run number |
Definition at line 72 of file JPMTThreshold.hh.
87 if (rs >> parameters) {
108 if (parameters.PAR_OID == upars.OID && parameters.ISINPUT ==
'Y') {
109 if (parameters.VALUE !=
"") {
110 istringstream(parameters.VALUE) >> (*this)[parameters.UPIFILTER];
*fatal Wrong number of arguments esac JCookie sh typeset Z DETECTOR typeset Z SOURCE_RUN typeset Z TARGET_RUN set_variable PARAMETERS_FILE $WORKDIR parameters
const char *const PMT_THRESHOLD_t
name of PMT threshold
JDetectorsHelper getDetector
Function object for mapping serial number to object identifier of detector and vice versa...
const char *const OPTICS_t
sub-system of PMT
ResultSet & getResultSet(const std::string &query)
Get result set.
Template definition for getting table specific selector.
Get PMT threshold for given UPI of PMT.
- Parameters
-
- Returns
- PMT threshold
Definition at line 126 of file JPMTThreshold.hh.
128 const_iterator p = this->find(upi.
toString());
130 const bool is_default = (p == this->end());
134 std::ostringstream os;
142 p = this->find(os.str());
145 if (p != this->end())
146 return { is_default, p->second };
148 THROW(JDatabaseException,
"Invalid UPI " << upi);
const std::string & getVariant() const
Get variant.
#define THROW(JException_t, A)
Marco for throwing exception with std::ostream compatible message.
static const char SEPARATOR
Separator between PBS, variant and version.
const JPBS_t & getPBS() const
Get PBS.
std::string toString() const
Convert UPI.
static const char DOT
Separator between PBS values.
std::ostream& operator<< |
( |
std::ostream & |
out, |
|
|
const JPMTThreshold & |
object |
|
) |
| |
|
friend |
Write PMT thresholds to output stream.
- Parameters
-
out | output stream |
object | PMT thresholds |
- Returns
- output stream
Definition at line 159 of file JPMTThreshold.hh.
163 for (JPMTThreshold::const_iterator i =
object.begin(); i !=
object.end(); ++i) {
164 out << left << setw(32) << i->first <<
' ' << right << setw(3) << i->second << endl;
The documentation for this class was generated from the following file: