Jpp  15.0.5
the software that should make you happy
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
getAAnetFiles.cc
Go to the documentation of this file.
1 
2 #include <string>
3 #include <iostream>
4 #include <iomanip>
5 #include <map>
6 
9 
10 #include "JLang/JVectorize.hh"
11 
12 #include "JAAnet/JHead.hh"
13 #include "JAAnet/JHeadToolkit.hh"
14 
17 #include "JSupport/JSupport.hh"
18 
19 #include "Jeep/JPrint.hh"
20 #include "Jeep/JParser.hh"
21 #include "Jeep/JMessage.hh"
22 
23 
24 /**
25  * \file
26  * Auxiliary program to select Monte Carlo files according generator.
27  *
28  * \author mdejong
29  */
30 int main(int argc, char **argv)
31 {
32  using namespace std;
33  using namespace JPP;
34 
35  JMultipleFileScanner_t inputFile;
36  string application;
37  int debug;
38 
39  try {
40 
41  JParser<> zap("Auxiliary program to select Monte Carlo files according generator.");
42 
43  zap['f'] = make_field(inputFile);
44  zap['H'] = make_field(application) = get_keys(get_is_head);
45  zap['d'] = make_field(debug) = 1;
46 
47  zap['H'] = JPARSER::not_initialised();
48 
49  zap(argc, argv);
50  }
51  catch(const exception &error) {
52  FATAL(error.what() << endl);
53  }
54 
55  cout << getAAnetFiles(inputFile, get_is_head(application));
56 }
57 
Utility class to parse command line options.
Definition: JParser.hh:1500
int main(int argc, char *argv[])
Definition: Main.cc:15
ROOT TTree parameter settings of various packages.
I/O formatting auxiliaries.
#define make_field(A,...)
macro to convert parameter to JParserTemplateElement object
Definition: JParser.hh:1961
int debug
debug level
Definition: JSirene.cc:63
Auxiliary methods to convert data members or return values of member methods of a set of objects to a...
General purpose messaging.
#define FATAL(A)
Definition: JMessage.hh:67
Scanning of objects from multiple files according a format that follows from the extension of each fi...
Empty structure for specification of parser element that is not initialised (i.e. does require input)...
Definition: JParser.hh:72
Auxiliary base class for list of file names.
Utility class to parse command line options.
static JHeadHelper get_is_head
Function object to get check method for given application.
JMultipleFileScanner_t getAAnetFiles(const JMultipleFileScanner_t &input, JFunction_t test)
Get list of files compatible with geven header.
const array_type< JKey_t > & get_keys(const std::map< JKey_t, JValue_t, JComparator_t, JAllocator_t > &data)
Method to create array of keys of map.
Definition: JVectorize.hh:139