File indexing completed on 2023-03-17 10:41:42
0001 #include "CalibCalorimetry/EcalTPGTools/interface/EcalTPGDBApp.h"
0002
0003 #include <cassert>
0004 #include <string>
0005 #include <fstream>
0006 #include <iostream>
0007
0008
0009
0010 int main (int argc, char* argv[])
0011 {
0012 std::string host;
0013 std::string sid;
0014 std::string user;
0015 std::string pass;
0016 std::string sport;
0017 std::string smin_run;
0018 std::string sn_run;
0019
0020 if (argc != 8) {
0021 std::cout << "Usage:" << std::endl;
0022 std::cout << " " << argv[0] << " <host> <SID> <user> <pass> <port> <min_run> <n_run>" << std::endl;
0023 exit(-1);
0024 }
0025
0026
0027 host = argv[1];
0028 sid = argv[2];
0029 user = argv[3];
0030 pass = argv[4];
0031 sport = argv[5];
0032 int port=atoi(sport.c_str());
0033 smin_run = argv[6];
0034 int min_run=atoi(smin_run.c_str());
0035 sn_run = argv[7];
0036 int n_run=atoi(sn_run.c_str());
0037
0038 try {
0039 EcalTPGDBApp app( sid, user, pass);
0040
0041 int i ;
0042
0043
0044
0045
0046 } catch (exception &e) {
0047 std::cout << "ERROR: " << e.what() << std::endl;
0048 } catch (...) {
0049 std::cout << "Unknown error caught" << std::endl;
0050 }
0051
0052 std::cout << "All Done." << std::endl;
0053
0054 return 0;
0055 }