6 #include "FairMQLogger.h"
7 #include "runSimpleMQStateMachine.h"
11 #include "PndMvdMQFileSampler.h"
22 while (is >> ch && ch!=
'=') into.first += ch;
23 return is >> into.second;
29 int main(
int argc,
char** argv)
38 po::options_description sampler_options(
"Sampler options");
39 sampler_options.add_options()
40 (
"file-name", po::value<std::vector<std::string>>(&
filename) ,
"Path to the input file")
41 (
"max-index", po::value<int64_t> (&maxindex) ->default_value(-1),
"number of events to read")
42 (
"branch-name", po::value<channelBranches>(&branchnames) ->multitoken() ,
"branch name");
45 FairMQProgOptions config;
46 config.AddToCmdLineOptions(sampler_options);
48 config.ParseAll(argc, argv);
52 for (
unsigned int ielem = 0 ; ielem < filename.size() ; ielem++ ) {
58 for(
int i = 0;
i < branchnames.size();
i++){
59 LOG(INFO) <<
"BranchNames: " << branchnames[
i].first <<
"/" << branchnames[
i].second;
65 runStateMachine(sampler, config);
69 catch (std::exception& e)
71 LOG(ERROR) <<
"Unhandled Exception reached the top of main: "
72 << e.what() <<
", application will now exit";
int main(int argc, char **argv)
void AddInputFileName(std::string tempString)
static std::istream & operator>>(std::istream &is, std::pair< std::string, std::string > &into)
void SetMaxIndex(int64_t tempInt)
void AddInputChannelBranchName(std::pair< std::string, std::string > tempString)
std::vector< std::pair< std::string, std::string > > channelBranches
std