78   typedef JRange<time_t>  JRange_t;
 
   93     JParser<> zap(
"Auxiliary program to decompose detector to separate calibrations.");
 
   99     zap[
'a'] = 
make_field(detectorFile, 
"detector file");
 
  104                                                                               &JCalibrationType::nick_name));
 
  105     zap[
'V'] = 
make_field(validity,     
"validity range UTC [s], e.g. \"<UTC min> <UTC max>\"")  = JRange_t(UTC_INVALID_S, UTC_INVALID_S);
 
  106     zap[
'r'] = 
make_field(
range,        
"run range e.g. \"<first run> <last run>\"")             = JRange_t(RUN_INVALID,   RUN_INVALID);
 
  107     zap[
'p'] = 
make_field(precision,    
"precision for match with reference module")             = 1.0e-5;
 
  112   catch(
const exception &error) {
 
  113     FATAL(error.what() << endl);
 
  123   catch(
const JException& error) {
 
  128     FATAL(
"No detector address map for detector identier " << 
detector.getID() << endl);
 
  144       for (JPersons 
object; rs >> object; ) {
 
  153       for (JDetectors 
object; rs >> object; ) {
 
  154         locid   = 
object.LOCATIONID;
 
  161     if (
range.getLowerLimit() != RUN_INVALID && validity.getLowerLimit() == UTC_INVALID_S) {
 
  165       for (JRuns 
object; rs >> object; ) {
 
  166         validity.setLowerLimit(
object.UNIXJOBSTART / 1000);
 
  172     if (
range.getUpperLimit() != RUN_INVALID && validity.getUpperLimit() == UTC_INVALID_S) {
 
  176       for (JRuns 
object; rs >> object; ) {
 
  177         validity.setUpperLimit(
object.UNIXJOBEND   / 1000);
 
  183   catch(
const exception& error) {
 
  184     FATAL(error.what() << endl);
 
  190   for (JDetector::const_iterator module = 
detector.begin(); module != 
detector.end(); ++module) {
 
  192     if (module->getFloor() != 0) {
 
  194       JModule buffer = demo.getModule(module->getID(), module->getLocation());
 
  200       if (!JModule::compare(buffer, *module, precision)) {
 
  201         FATAL(
"Module " << setw(10) <<  module->getID() << 
' ' << module->getLocation() << 
" incompatible with reference." << endl);
 
  211                         { 
EndTime_t,     JDateAndTime(
true).toString() },
 
  229     for (JDetector::const_iterator module = 
detector.begin(); module != 
detector.end(); ++module) {
 
  230       for (JModule::const_iterator pmt = module->begin(); pmt != module->end(); ++pmt) {
 
  231         data.push_back(JPMTCalibration_t(pmt->getID(), 
getCalibration(JCalibration(), *pmt)));
 
  245     for (JDetector::const_iterator module = 
detector.begin(); module != 
detector.end(); ++module) {
 
  247       const JModule& buffer = demo.getModule(module->getID(), module->getLocation());
 
  249       if (buffer.getFloor() == 0)
 
  250         data[0].push_back(JModulePosition_t(module->getID(), 
getPosition(buffer, *module)));
 
  252         data[1].push_back(JModulePosition_t(module->getID(), 
getPosition(buffer, *module)));
 
  266     for (JDetector::const_iterator module = 
detector.begin(); module != 
detector.end(); ++module) {
 
  268       const JModule& buffer = demo.getModule(module->getID(), module->getLocation());
 
  270       if (module->getFloor() != 0) {
 
  271         data.push_back(JModuleRotation_t(module->getID(), 
getRotation(buffer, *module)));
 
  285     for (JDetector::const_iterator module = 
detector.begin(); module != 
detector.end(); ++module) {
 
  287       if (module->getFloor() == 0)
 
  288         data[0].push_back(JModuleCalibration_t(module->getID(), module->getT0()));
 
  290         data[1].push_back(JModuleCalibration_t(module->getID(), module->getT0()));
 
  304     for (JDetector::const_iterator module = 
detector.begin(); module != 
detector.end(); ++module) {
 
  305       if (module->getFloor() == 0)
 
  306         data[0].push_back(JCompassRotation_t(module->getID(), module->getQuaternion()));
 
  308         data[1].push_back(JCompassRotation_t(module->getID(), module->getQuaternion()));
 
  325       for (JDetector::const_iterator module = 
detector.begin(); module != 
detector.end(); ++module) {
 
  326         for (JModule::const_iterator pmt = module->begin(); pmt != module->end(); ++pmt) {
 
  327           data.push_back(JPMTStatus_t(pmt->getID(), pmt->getStatus()));
 
  336       for (JDetector::const_iterator module = 
detector.begin(); module != 
detector.end(); ++module) {
 
  337         if (module->getFloor() == 0)
 
  338           data[0].push_back(JModuleStatus_t(module->getID(), module->getStatus()));
 
  340           data[1].push_back(JModuleStatus_t(module->getID(), module->getStatus()));
 
static const std::string Arguments_t
Utility class to parse command line options. 
static const std::string DOMStatusInfo_t
static const std::string Code_t
static const std::string UserId_t
static const std::string EndTime_t
static const std::string ACAL
acoustic time offsets (piezo sensor or hydrophone) 
static const std::string CCAL
compass alignment (a.k.a. quaternion calibration) 
static const std::string PMTT0s_t
bool hasDetectorAddressMap(const int id)
Check if detector address map is available. 
static const std::string Error_t
std::vector< JModuleRotation_t > JModuleRotation
Module rotation. 
static JRotation getRotation
Function object to get rotation matrix to go from first to second module. 
JCalibration getCalibration(const JCalibration &first, const JCalibration &second)
Get calibration to go from first to second calibration. 
static const std::string BaseStatusInfo_t
std::vector< JCompassRotation_t > JCompassRotation
Compass rotation. 
static const std::string ValidFrom_t
static const std::string TCAL
PMT time offsets. 
static const std::string Comment_t
static const std::string ValidThrough_t
#define make_field(A,...)
macro to convert parameter to JParserTemplateElement object 
const array_type< JValue_t > & make_array(const JValue_t(&array)[N])
Method to create array of values. 
void store(const std::string &file_name, const JDetector &detector)
Store detector to output file. 
JPosition3D getPosition(const Vec &pos)
Get position. 
static const std::string StartTime_t
static const std::string DOMPositions_t
Auxiliary data structure for streaming of STL containers. 
static const std::string RCAL
optical module orientations 
static const std::string DOMCompassRotations_t
static const std::string Message_t
static const std::string DetOID_t
std::string setWildCard(const std::string &file_name, const std::string &value)
Get file name by setting wild card to given value. 
z range($ZMAX-$ZMIN)< $MINIMAL_DZ." fi fi typeset -Z 4 STRING typeset -Z 2 FLOOR JPlot1D -f $
std::vector< JModuleStatus_t > JModuleStatus
Module status. 
then JCookie sh JDataQuality D $DETECTOR_ID R
static const std::string Data_t
void load(const std::string &file_name, JDetector &detector)
Load detector from input file. 
static const std::string SCAL
(module|PMT) status 
std::vector< JPMTStatus_t > JPMTStatus
PMT status. 
static const std::string BasePositions_t
ResultSet & getResultSet(const std::string &query)
Get result set. 
static const std::string DOMRotations_t
std::vector< JServer > getServernames()
Get list of names of available database servers. 
static const std::string LocationId_t
const char * getName()
Get ROOT name of given data type. 
static const std::string BaseCompassRotations_t
std::vector< JModulePosition_t > JModulePosition
Module position. 
do set_variable DETECTOR_TXT $WORKDIR detector
static const std::string PMTStatusInfo_t
static const std::string PCAL
(optical|base) module positions 
JDetectorBuilder & getDetectorBuilder()
Get detector builder. 
static const char FILENAME_WILDCARD
wild card character for file name substitution 
JSON::getCalibrationType getCalibrationType
static const std::string DOMAcousticT0_t
std::vector< JPMTCalibration_t > JPMTCalibration
PMT time calibration. 
static const std::string TypeId_t
static const std::string BaseAcousticT0_t
std::vector< JModuleCalibration_t > JModuleCalibration
Module time calibration. 
static const std::string OK_t
bool hasWildCard(const std::string &file_name)
Check presence of wild card.