Jpp  16.0.0-rc.1
the software that should make you happy
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
Functions
software/JGizmo/JPrint.cc File Reference

Auxiliary program to print 'any' data. More...

#include <string>
#include <iostream>
#include <iomanip>
#include "km3net-dataformat/offline/Head.hh"
#include "km3net-dataformat/offline/Evt.hh"
#include "JDAQ/JDAQTimesliceIO.hh"
#include "JDAQ/JDAQEventIO.hh"
#include "JDAQ/JDAQSummarysliceIO.hh"
#include "JTrigger/JTriggerParameters.hh"
#include "antares-dataformat/TimeSlice.hh"
#include "antares-dataformat/PhysicsEvent.hh"
#include "JSupport/JMultipleFileScanner.hh"
#include "JSupport/JMonteCarloFileSupportkit.hh"
#include "JSupport/JTriggerParametersSupportkit.hh"
#include "JSupport/JSupport.hh"
#include "JLang/JStreamObjectOutput.hh"
#include "JLang/JPipe.hh"
#include "JROOT/JROOTClassSelector.hh"
#include "Jeep/JParser.hh"
#include "Jeep/JMessage.hh"

Go to the source code of this file.

Functions

int main (int argc, char **argv)
 

Detailed Description

Auxiliary program to print 'any' data.

The name of the data structure following option -C should be preceded by a '+' or '-' to add or remove data types in the output, respectively.
In this, ROOT wildcards are accepted (e.g. -C -\.\* will remove all data types).

Note that for printing TRandom information and meta data, JPrintRandom.cc and JPrintMeta.cc should be used, respectively.

Author
mdejong

Definition in file software/JGizmo/JPrint.cc.

Function Documentation

int main ( int  argc,
char **  argv 
)

Definition at line 41 of file software/JGizmo/JPrint.cc.

42 {
43  using namespace std;
44  using namespace JPP;
45  using namespace KM3NETDAQ;
46 
48 
50  JLimit_t& numberOfEvents = inputFile.getLimit();
51  JROOTClassSelection selection = getROOTClassSelection<typelist>();
52  int debug;
53 
54  try {
55 
56  JParser<> zap("Auxiliary program to print 'any' data.");
57 
58  zap['f'] = make_field(inputFile);
59  zap['n'] = make_field(numberOfEvents) = 1;
60  zap['C'] = make_field(selection,
61  "Precede name of data structure by a '+' or '-' "
62  "to add or remove data types in the output, respectively."
63  "\nROOT wildcards are accepted.") = JPARSER::initialised();
64  zap['d'] = make_field(debug) = 1;
65 
66  zap(argc, argv);
67  }
68  catch(const exception& error) {
69  FATAL(error.what() << endl);
70  }
71 
73 
75 
76  inputFile | JValve<typelist>(selection) | out;
77 }
Utility class to parse command line options.
Definition: JParser.hh:1500
debug
Definition: JMessage.hh:29
Auxiliary class for ROOT class selection.
Empty structure for specification of parser element that is initialised (i.e. does not require input)...
Definition: JParser.hh:66
Auxiliary class for selection of data type.
Type list.
Definition: JTypeList.hh:22
void setDAQLongprint(const bool option)
Set DAQ print option.
Definition: JDAQPrint.hh:28
Auxiliary class for defining the range of iterations of objects.
Definition: JLimit.hh:41
#define make_field(A,...)
macro to convert parameter to JParserTemplateElement object
Definition: JParser.hh:1961
int debug
debug level
Definition: JSirene.cc:63
#define FATAL(A)
Definition: JMessage.hh:67
General purpose class for object reading from a list of file names.
Template implementation of stream output for single data type.
const JLimit & getLimit() const
Get limit.
Definition: JLimit.hh:73