#include #include #include #include "JROOT/JTreeParameters.hh" #include "JAAnet/JSupport.hh" #include "JDAQ/JSupport.hh" #include "JSupport/JSupport.hh" #include "JLang/JBool.hh" #include "JLang/JType.hh" #include "Jeep/JParser.hh" #include "Jeep/JMessage.hh" namespace { using namespace JPP; /** * Printer for TTree parameters. */ struct JPrinter { /** * Print TTree parameters of given data type. * * \param type type */ template void operator()(JType type) { print(type, JBool::result>()); } /** * Print TTree parameters of given data type according option. * * \param type type * \param option option */ template static void print(JType type, JBool option) { using namespace std; using namespace JPP; cout << getTreeParameters() << endl; }; /** * Print TTree parameters of given data type according option. * * \param type type * \param option option */ template static void print(JType type, JBool option) {} }; } /** * \file * * Auxiliary program to print ROOT TTree parameters. * \author mdejong */ int main(int argc, char **argv) { using namespace std; using namespace JPP; using namespace KM3NETDAQ; int debug; try { JParser<> zap("Auxiliary program to print ROOT TTree parameters."); zap['d'] = make_field(debug) = 1; zap(argc, argv); } catch(const exception &error) { FATAL(error.what() << endl); } JPrinter printer; for_each(printer, JType()); }