10 #define DATABASEUTIL_H 24 UBDaqID(
int _crate,
int _card,
int _channel ) :
34 if (this->crate == rhs.
crate &&
35 this->card == rhs.
card &&
36 this->channel < rhs.
channel) is_less=
true;
37 else if (this->crate == rhs.
crate &&
38 this->card < rhs.
card) is_less=
true;
39 else if (this->crate < rhs.
crate) is_less=
true;
59 int GetLifetimeFromDB(
int run,
double &lftime_real);
60 int GetTriggerOffsetFromDB(
int run,
double &T0_real);
61 int GetTemperatureFromDB(
int run,
double &temp_real);
62 int GetEfieldValuesFromDB(
int run,std::vector<double> &efield);
63 int GetPOTFromDB(
int run,
long double &POT);
64 UBChannelMap_t GetUBChannelMap(
int data_taking_timestamp = -1 ,
int swizzling_timestamp = -1 );
65 UBChannelReverseMap_t GetUBChannelReverseMap(
int data_taking_timestamp = -1 ,
int swizzling_timestamp = -1 );
67 int SelectFieldByName(std::vector<std::string> &
value,
const char * field,
const char * condition,
const char * table);
68 std::vector<std::string> & split(
const std::string &
s,
char delim, std::vector<std::string> &elems);
75 int SelectSingleFieldByQuery(std::vector<std::string> &value,
const char * query);
76 int Connect(
int conn_wait=0);
78 char connection_str[200];
92 void LoadUBChannelMap(
int data_taking_timestamp = -1 ,
int swizzling_timestamp = -1 );
Namespace for general, non-LArSoft-specific utilities.
#define DECLARE_ART_SERVICE(svc, scope)
const bool operator<(const UBDaqID &rhs) const
bool fToughErrorTreatment
UBDaqID(int _crate, int _card, int _channel)
bool ToughErrorTreatment() const
std::string value(boost::any const &)
std::map< UBDaqID, UBLArSoftCh_t > UBChannelMap_t
bool ShouldConnect() const
std::map< UBLArSoftCh_t, UBDaqID > UBChannelReverseMap_t
UBChannelReverseMap_t fChannelReverseMap
UBChannelMap_t fChannelMap