#include <iostream>
#include <string>
#include <unistd.h>
#include "EventStorage/pickDataReader.h"
#include "FileMetaData.h"
#include "CxxUtils/checker_macros.h"
Go to the source code of this file.
◆ ATLAS_NOT_THREAD_SAFE()
| int main ATLAS_NOT_THREAD_SAFE |
( |
int | argc, |
|
|
char ** | argv ) |
Definition at line 103 of file BSFilePeeker.cxx.
103 {
104
106 bool kvDump=false;
108
109 while ((c = getopt (argc, argv, "vk")) != -1) {
110 switch (c) {
111 case 'v':
113 break;
114 case 'k':
115 kvDump=true;
116 break;
117 default:
118 std::cerr << "Unkown command line option" << std::endl;
119 return -1;
120 }
121 }
122
123
124 const int nfiles=
argc-optind;
125 if (nfiles<=0) {
126 std::cerr << "Expected at least one file name as parameter" << std::endl;
127 return -1;
128 }
129
130
131 std::vector<FileMetaData>
output;
132
133 for (
int iFile=optind;iFile<
argc;++iFile) {
134 const std::string
filename(argv[iFile]);
136
138
139 output.push_back(bsfp.get());
140 }
141
142
143 if (kvDump) {
144 for (const auto& o : output) o.keyValueDump();
145 }
146 else {
147 for (const auto& o : output) o.dump();
148 }
149
150 return 0;
151}