41int main(
int argc,
char **argv)
66 catch(
const exception& error) {
67 FATAL(error.what() << endl);
71 TTree::SetMaxTreeSize(1000000000000LL);
75 if (pos == string::npos) {
76 FATAL(
"Valid wildcard must be specified (<" <<
outputFile <<
"> does not contain \'" << wildcard <<
"\').");
87 const size_t Ndigits =
to_string(scanners.size()).size();
91 const size_t Nfile =
distance(scanners.begin(), scanner);
93 const string filename = string(
outputFile).replace(pos, 1,
MAKE_STRING(setfill(
'0') << setw(Ndigits) << Nfile));
95 NOTICE(
"Writing " << filename <<
"..." << endl);
97 if (scanner->getFilelist().size() == 1 &&
98 symlink(scanner->getFilename().c_str(), filename.c_str()) == 0) {
112 while (scanner->hasNext()) {
114 const Evt*
event = scanner->next();
118 STATUS(
"Event:" <<
RIGHT(10) << scanner->getCounter() <<
'\r');
DEBUG(endl);
123 WARNING(
"Event " << scanner->getCounter() <<
" is empty; skip.");
Recording of objects on file according a format that follows from the file name extension.
General purpose messaging.
#define DEBUG(A)
Message macros.
Scanning of objects from multiple files according a format that follows from the extension of each fi...
Utility class to parse command line options.
#define make_field(A,...)
macro to convert parameter to JParserTemplateElement object
I/O formatting auxiliaries.
#define MAKE_STRING(A)
Make string.
int main(int argc, char **argv)
ROOT TTree parameter settings of various packages.
std::vector< T >::difference_type distance(typename std::vector< T >::const_iterator first, typename PhysicsEvent::const_iterator< T > second)
Specialisation of STL distance.
Data structure for set of track fit results.
Utility class to parse command line options.
virtual void open(const char *file_name) override
Open file.
General purpose class for object reading from a list of file names.
std::string to_string(const T &value)
Convert value to string.
This name space includes all other name spaces (except KM3NETDAQ, KM3NET and ANTARES).
Head getHeader(const JMultipleFileScanner_t &file_list)
Get Monte Carlo header.
The Evt class respresent a Monte Carlo (MC) event as well as an offline event.
The Head class reflects the header of Monte-Carlo event files, which consists of keys (also referred ...
virtual void close() override
Close device.
virtual bool put(const T &object) override
Object output.
Auxiliary class for recursive type list generation.
Auxiliary class for organising Monte Carlo file scanners associated with event weighters.
std::vector< filescanner_type >::iterator iterator
Auxiliary base class for list of file names.