Jpp
Main Page
Namespaces
Classes
Files
File List
File Members
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Macros
Pages
software
JGizmo
JPrint.cc
Go to the documentation of this file.
1
2
#include <string>
3
#include <iostream>
4
#include <iomanip>
5
6
#include "evt/Head.hh"
7
#include "evt/Evt.hh"
8
9
#include "
JDAQ/JDAQTimeslice.hh
"
10
#include "
JDAQ/JDAQEvent.hh
"
11
#include "
JDAQ/JDAQSummaryslice.hh
"
12
13
#include "
JTrigger/JTriggerParameters.hh
"
14
15
#include "antares-dataformat/TimeSlice.hh"
16
#include "antares-dataformat/PhysicsEvent.hh"
17
18
#include "
JSupport/JMultipleFileScanner.hh
"
19
#include "
JSupport/JMonteCarloFileSupportkit.hh
"
20
#include "
JSupport/JTriggerParametersSupportkit.hh
"
21
#include "
JSupport/JSupport.hh
"
22
#include "
JLang/JStreamObjectOutput.hh
"
23
#include "
JLang/JPipe.hh
"
24
#include "
JROOT/JROOTClassSelector.hh
"
25
26
#include "
Jeep/JParser.hh
"
27
#include "
Jeep/JMessage.hh
"
28
29
30
/**
31
* \file
32
* Auxiliary program to print 'any' data.
33
*
34
* The name of the data structure following option -C should be preceded by a '+' or '-'
35
* to add or remove data types in the output, respectively.\n
36
* In this, ROOT wildcards are accepted (e.g. <pre>-C -\\.\\*</pre> will remove all data types).
37
*
38
* Note that for printing TRandom information and meta data, JPrintRandom.cc and JPrintMeta.cc should be used, respectively.
39
* \author mdejong
40
*/
41
int
main
(
int
argc,
char
**argv)
42
{
43
using namespace
std;
44
using namespace
JPP;
45
46
typedef
JAppend<JAllDataTypes_t, JAntaresTypes_t>::typelist
typelist;
47
48
JMultipleFileScanner<typelist> inputFile;
49
JLimit_t
& numberOfEvents = inputFile.
getLimit
();
50
JROOTClassSelection selection = getROOTClassSelection<typelist>();
51
int
debug
;
52
53
try
{
54
55
JParser<>
zap(
"Auxiliary program to print 'any' data."
);
56
57
zap[
'f'
] =
make_field
(inputFile);
58
zap[
'n'
] =
make_field
(numberOfEvents) = 1;
59
zap[
'C'
] =
make_field
(selection,
60
"Precede name of data structure by a '+' or '-'"
61
"to add or remove data types in the output, respectively."
62
"\nROOT wildcards are accepted."
) =
JPARSER::initialised
();
63
zap[
'd'
] =
make_field
(
debug
) = 1;
64
65
zap(argc, argv);
66
}
67
catch
(
const
exception& error) {
68
FATAL
(error.what() << endl);
69
}
70
71
if
(
debug
>=
JEEP::debug_t
) {
72
setLongprint
(cout);
73
}
74
75
JStreamObjectOutput<typelist> out(cout);
76
77
inputFile | JValve<typelist>(selection) | out;
78
}
JPARSER::JParser
Utility class to parse command line options.
Definition:
JParser.hh:1410
JTriggerParameters.hh
JEEP::debug_t
debug
Definition:
JMessage.hh:27
JLANG::JAppend
Append to type list.
Definition:
JTypeList.hh:61
JDAQEvent.hh
setLongprint
void setLongprint(std::ostream &out)
Set long print option.
Definition:
JPrint.hh:149
JPARSER::initialised
Empty structure for specification of parser element that is initialised (i.e.
Definition:
JParser.hh:64
JDAQSummaryslice.hh
JSUPPORT::JLimit_t
JLimit JLimit_t
Type definition of limit.
Definition:
JLimit.hh:214
make_field
#define make_field(A,...)
macro to convert parameter to JParserTemplateElement object
Definition:
JParser.hh:1836
JPipe.hh
Implementation of pipe operation for object iterators.
debug
int debug
debug level
Definition:
JSirene.cc:59
JTriggerParametersSupportkit.hh
JMessage.hh
General purpose messaging.
FATAL
#define FATAL(A)
Definition:
JMessage.hh:65
JMultipleFileScanner.hh
Scanning of objects from multiple files according a format that follows from the extension of each fi...
JMonteCarloFileSupportkit.hh
JParser.hh
Utility class to parse command line options.
JROOTClassSelector.hh
JSupport.hh
ROOT TTree parameter settings.
JDAQTimeslice.hh
JSUPPORT::JLimit::getLimit
const JLimit & getLimit() const
Get limit.
Definition:
JLimit.hh:72
JStreamObjectOutput.hh
main
int main(int argc, char *argv[])
Definition:
Main.cpp:15
Generated by
1.8.5