#include #include #include #include "JAcoustics/JMechanics.hh" #include "Jeep/JPrint.hh" #include "Jeep/JParser.hh" #include "Jeep/JMessage.hh" /** * \file * * Auxiliary program to print mechanical constants. * \author mdejong */ int main(int argc, char **argv) { using namespace std; using namespace JPP; int string; int id; int debug; try { JParser<> zap("Auxiliary program to print mechanical constants."); zap['M'] = make_field(getMechanics, "mechanics data") = JPARSER::initialised(); zap['S'] = make_field(string, "string number") = 0; zap['D'] = make_field(id, "detector identifier") = 0; zap['d'] = make_field(debug) = 1; zap(argc, argv); } catch(const exception &error) { FATAL(error.what() << endl); } if (id != 0) { DEBUG("Load mechanical model parameters from file: " << JDetectorMechanics::getFilename(id) << endl); getMechanics.load(id); } if (string != 0) cout << setw(4) << string << ' ' << getMechanics(string) << endl; else cout << getMechanics << endl; }