LCIO  02.17
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
lsh.cc
Go to the documentation of this file.
1 
13 #include <signal.h>
14 #include <string>
15 #include <cstring>
16 #include <cstdlib>
17 #include <sstream>
18 #include <fstream>
19 #include <iomanip>
20 #include "lcio.h"
21 
22 // C headers needed for output redirection (paging)
23 #include <sys/types.h>
24 #include <sys/stat.h>
25 #include <fcntl.h>
26 #include <unistd.h>
27 
28 
29 #include "EVENT/LCCollection.h"
30 #include "EVENT/SimTrackerHit.h"
32 
33 #include "IO/LCReader.h"
34 #include "UTIL/LCTOOLS.h"
35 #include "EVENT/LCRunHeader.h"
36 #include "UTIL/LCTime.h"
37 
38 /*** <READLINE> ***/
39 extern "C" {
40  #include <readline/readline.h>
41  #include <readline/history.h>
42 }
43  /*** </READLINE> ***/
44 
45 using namespace std ;
46 using namespace lcio ;
47 
48 // const int maxFilestring = 20;
49 
51 
52 struct pagerInfo{
53  char *filename;
54  int fd_temp;
55  int fd_old;
56  bool save;
57 } ;
58 
59 // Constants to identify postion in tree.
60 const int TOP = 0; // file information
61 const int RUN = 1;
62 const int EVT = 2;
63 const int COL = 3;
65 
68 int numEvents = 0;
69 bool withEvents = true;
70 bool interrupt = false; // flag for signal handling
71 bool pageOutput = false;
72 
73 string pager = "less";
74 string egg = "egg";
75 string prompt = "";
76 
77 // memorie for objects
78 LCReader* lcReader;
79 LCRunHeader *runHdr ;
80 LCEvent *event;
81 LCCollection *gCol;
82 
83 
87 const char * print_prompt() {
88 
89  prompt.clear() ;
90 
92  vector<level>::iterator levelItEnd = position.end();
93  for( levelIt = position.begin(); levelIt != levelItEnd ; levelIt++ ){
94  prompt += levelIt->second ;
95  }
96  prompt += "$ ";
97 
98  return prompt.c_str();
99 }
100 
110 void leave(int ret) {
111  cout << endl;
112  try {
113  lcReader->close() ;
114  }
115  catch (exception& e) {
116  }
117  delete lcReader;
118 //
119  exit(ret);
120 }
121 
129 void int_handler(int sig) {
130  cout << "interrupting.." << sig << endl;
131  interrupt = true;
132 }
133 
134 void term_handler(int sig) {
135  cout << "leaving.. " << sig << endl;
136  leave(1);
137 }
138 
147  if (!(file->save)) {
148  std::string s("./lcio_lsh.tmp" );
149  file->filename = &s[0] ;
150  }
151 
152  // C style output redirection (changing file descriptors)
153  file->fd_temp = open(file->filename, O_WRONLY | O_CREAT | O_TRUNC, S_IRUSR | S_IWUSR );
154  file->fd_old = open(file->filename, O_RDONLY); // creating a place for the old stdout fd (shell)
155  dup2(1, file->fd_old); // backing up old fd pointed to by stdout (1 = stdout)
156  dup2(file->fd_temp, 1); // changing the fd pointed to by stdout
157  // stdout points now to the fd of our temp file
158 }
159 
160 
161 bool end_paging(pagerInfo*file) {
162  dup2(file->fd_old, 1); // resetting the fd pointed to by stdout
163 
164  // stdout points to the shell's fd again
165  close(file->fd_temp);
166  close(file->fd_old); // removes the fd (the file stays open as stdout points to it too)
167 
168  string lessCommand = pager;
169  lessCommand.append(" ");
170  lessCommand.append(file->filename);
171 
172  int res = system(lessCommand.c_str());
173 
174  if (!(file->save)) {
175  remove (file->filename);
176  }
177 
178  return !res; // system returns 0 on success, but 0 is evaluated to false
179 }
180 
189 //Prints important info for tracker and calorimeter hits (and number of entries for all collections)
190 void simplePrintCol(LCCollection* col) {
191  int nElements;
192  const std::string colType = col->getTypeName();
193 
194  SimTrackerHit *trackerHit;
195  SimCalorimeterHit *calHit;
196 
197 
198  cout << "elements: " << (nElements = col->getNumberOfElements()) << endl;
199  if (colType == LCIO::SIMTRACKERHIT ) {
200  cout << " Hit \tCell"<< endl;
201  for (int i=0; i<nElements; i++) {
202  trackerHit = dynamic_cast<SimTrackerHit*> ( col->getElementAt(i) );
203  cout << setw(4) << i << "\t" << setw(10) << trackerHit->getCellID() << endl;
204  }
205  } else if (colType == LCIO::SIMCALORIMETERHIT ) {
206  cout << " Hit \tCell \tEnergy" << endl;
207  for (int i=0; i<nElements; i++) {
208  calHit = dynamic_cast<SimCalorimeterHit*> ( col->getElementAt(i) );
209  cout << setw(4) << i << "\t" << setw(10) << calHit->getCellID0() << "\t" << setw(6) << calHit->getEnergy() << endl;
210  }
211  }
212 }
213 // end simplePrintCol()
214 
215 
216 // prints a detailed listing of all the entries in the collection
217 void normalPrintCol(LCCollection *col) {
218  if( col->getTypeName() == LCIO::MCPARTICLE ){
219  LCTOOLS::printMCParticles( col ) ;
220 
221  }
222  else if( col->getTypeName() == LCIO::SIMTRACKERHIT ){
223 
224  LCTOOLS::printSimTrackerHits( col ) ;
225 
226  }
227  else if( col->getTypeName() == LCIO::TPCHIT ){
228 
229  LCTOOLS::printTPCHits( col ) ;
230 
231  }
232  else if( col->getTypeName() == LCIO::TRACKERHIT ){
233 
234  LCTOOLS::printTrackerHits( col ) ;
235 
236  }
237  else if( col->getTypeName() == LCIO::SIMCALORIMETERHIT ){
238 
239  LCTOOLS::printSimCalorimeterHits( col ) ;
240 
241  }
242  else if( col->getTypeName() == LCIO::CALORIMETERHIT ){
243 
244  LCTOOLS::printCalorimeterHits( col ) ;
245 
246  }
247  else if( col->getTypeName() == LCIO::RAWCALORIMETERHIT ){
248 
249  LCTOOLS::printRawCalorimeterHits( col ) ;
250 
251  }
252  else if( col->getTypeName() == LCIO::LCFLOATVEC ){
253 
254  LCTOOLS::printLCFloatVecs( col ) ;
255 
256  }
257  else if( col->getTypeName() == LCIO::LCINTVEC ){
258 
259  LCTOOLS::printLCIntVecs( col ) ;
260 
261  }
262  else if( col->getTypeName() == LCIO::LCSTRVEC ){
263 
264  LCTOOLS::printLCStrVecs( col ) ;
265 
266  }
267  else if( col->getTypeName() == LCIO::TRACK ){
268 
269  LCTOOLS::printTracks( col ) ;
270 
271  }
272  else if( col->getTypeName() == LCIO::CLUSTER ){
273 
274  LCTOOLS::printClusters( col ) ;
275 
276  }
277  else if( col->getTypeName() == LCIO::RECONSTRUCTEDPARTICLE ){
278 
279  LCTOOLS::printReconstructedParticles( col ) ;
280 
281  }
282  else if( col->getTypeName() == LCIO::VERTEX ){
283 
284  LCTOOLS::printVertices( col ) ;
285 
286  }
287  else if( col->getTypeName() == LCIO::LCGENERICOBJECT ){
288 
289  LCTOOLS::printLCGenericObjects( col ) ;
290 
291  }
292  else if( col->getTypeName() == LCIO::LCRELATION ){
293 
294  LCTOOLS::printRelation( col ) ;
295  }
296  else if( col->getTypeName() == LCIO::TRACKERRAWDATA ){
297 
298  LCTOOLS::printTrackerRawData( col ) ;
299  }
300  else if( col->getTypeName() == LCIO::TRACKERDATA ){
301 
302  LCTOOLS::printTrackerData( col ) ;
303  }
304  else if( col->getTypeName() == LCIO::TRACKERPULSE ){
305 
306  LCTOOLS::printTrackerPulse( col ) ;
307  }
308 }
309 // end normalPrintCol()
310 
311 
312 // prints short summary on open file
313 void printTop() {
314  if (withEvents) {
315  cout << mapRuns.size() << " Runs - " << numEvents << " Events" << endl;
316  } else {
317  cout << mapRuns.size() << " Runs - ?? Events" << endl;
318  }
319 }
320 
321 
322 
323 // print details for collection (called: print | cat and ls | dummp within a collection)
324 void fun_print(string colNr, string flag) {
325  if ((position.size() < 3)) {
326  return;
327  }
328  unsigned int c;
329  istringstream i(colNr);
330  i >> c;
331  lcReader->open( position[TOP].second ) ;
332  if ((event = lcReader->readEvent( position[RUN].first, position[EVT].first )) != 0) {
333  const vector<string> *colVec = event->getCollectionNames();
334  if (c < colVec->size()) {
335  gCol = event->getCollection((*colVec)[c]);
336  cout << "name: " << (*colVec)[c] << endl;
337  cout << "type: " << gCol->getTypeName() << endl;
338 
339  if (flag == "-s") {
341  } else {
343  }
344  }
345  }
346 
347  lcReader->close() ;
348 }
349 // end fun_print
350 
360 // list all runs in file
361 void lsRuns() {
363  map<int, string>::iterator itEnd = mapRuns.end();
364  for( it = mapRuns.begin() ; it != itEnd ; it++ ) {
365  if (withEvents) {
366  stringstream sstream;
367  sstream << "(" << mapEventsInRun[it->first] << " events)";
368  string tempEvents = sstream.str() ;
369  cout << "[" << setw(2) << it->first << "] " << left << setw(40) << it->second << " " << right << setw(13) << tempEvents << endl;
370  } else {
371  cout << "[" << setw(2) << it->first << "] " << left << setw(40) << it->second << " " << endl;
372  }
373  }
374 }
375 // end lsRuns()
376 
377 
378 // list all events in run
379 void lsEvents() {
380  lcReader->open( position[TOP].second ) ;
381  while ( (event = lcReader->readNextEvent() ) != 0 && !interrupt) {
382  if (event->getRunNumber() == (position[RUN].first)) {
383  cout << "[" << setw(2) << event->getEventNumber() << "] " << setw(3) << (event->getCollectionNames())->size() << " Collections" << endl;
384  }
385  }
386  interrupt = false;
387  lcReader->close() ;
388 }
389 //end lsEvents()
390 
391 
392 // list all collections in event
394  lcReader->open( position[TOP].second ) ;
395  if ((event = lcReader->readEvent( position[RUN].first, position[EVT].first )) != 0) {
396  const vector<string> *colVec = event->getCollectionNames();
397  int i = 0;
399  vector<string>::const_iterator itEnd = colVec->end();
400  for( it = colVec->begin(); it != itEnd ; it++ ){
401  gCol = event->getCollection(*it);
402  cout << "[" << setw(2) << i << "] " << left << setw(25) << *it << " " << setw(20) << gCol->getTypeName() << " " << right << setw(3) << gCol->getNumberOfElements () << endl;
403  i++;
404  }
405  } else {
406  cout << "this event does not exist" << endl;
407  }
408  lcReader->close() ;
409 }
410 // end lsCollections()
411 
419 // ls
420 void fun_ls() {
421  switch( position.size()-1 ){
422  case TOP:
423  printTop();
424  lsRuns();
425  break;
426  case RUN:
427  lsEvents();
428  break;
429  case EVT:
430  lsCollections();
431  break;
432  case COL:
433  string s;
434  stringstream n;
435  n << position[COL].first;
436  n >> s;
437  fun_print(s, "-s");
438  break;
439  }
440 }
441 // end ls
442 
443 
444 // cl (change level) | cd (change directory)
445 void fun_cd(string str) {
446  unsigned n;
447 
448  if (str.size() < 1) {
449  return;
450  }
451 
452  char *cstr, *p;
453  cstr = new char [str.size()+1];
454  strcpy (cstr, str.c_str());
455  p=strtok (cstr,"/");
456  while (p!=NULL)
457  {
458  string next;
459  stringstream sstream;
460  sstream << p;
461  sstream >> next;
462  // moving up
463  if (next == "..") {
464  if (position.size() == 1) {
465  leave(0);
466  }
467  position.pop_back();
468  } else {
469  // moving into next level
470  istringstream i(next);
471  i >> n;
472  switch( position.size()-1 ){
473  case TOP:
474  position.push_back(level(n, "/run_"+next));
475  break;
476  case RUN:
477  position.push_back(level(n, "/evt_"+next));
478  break;
479  case EVT:
480  lcReader->open( position[TOP].second ) ;
481  if ((event = lcReader->readEvent( position[RUN].first, position[EVT].first )) != 0) {
482  const vector<string> *colVec = event->getCollectionNames();
483  if (n < colVec->size()) {
484  position.push_back(level(n, "/"+(*colVec)[n] ));
485  } else {
486  cout << "No collection with number " << n << endl;
487  }
488  }
489  lcReader->close();
490  break;
491  }
492  }
493 
494  p=strtok(NULL,"/");
495  }
496 
497  delete[] cstr;
498 
499 }
500 // end cl | cd
501 
502 
503 // dump data of active level
504 void fun_dump(string arg) {
505  switch( position.size()-1 ){
506  case RUN:
507  // WHY IS THERE NO readRunHeader( int run ) ??
508  lcReader->open( position[TOP].second ) ;
509  while (( runHdr = lcReader->readNextRunHeader() ) != 0 && !interrupt) {
510  int run = runHdr->getRunNumber();
511  if (run == position[RUN].first) {
512  interrupt = true;
513  LCTOOLS::dumpRunHeader(runHdr);
514  }
515  }
516  lcReader->close() ;
517  interrupt = false;
518  break;
519  case EVT:
520  lcReader->open( position[TOP].second ) ;
521  if ((event = lcReader->readEvent( position[RUN].first, position[EVT].first )) != 0) {
522  if(arg == "-d"){
523  LCTOOLS::dumpEventDetailed(event);
524  } else {
526  }
527  }
528  lcReader->close() ;
529  break;
530  case COL:
531  string s;
532  stringstream n;
533  n << position[COL].first;
534  n >> s;
535  fun_print(s, "-d");
536  break;
537  }
538 }
539 // end dump
540 
541 void fun_egg() {
542  for (int i = 0; i < 4; i++ ) {
543  cout << "Glugg...." << endl;
544  sleep(1);
545  }
546  cout << "Ahhh\n" << endl;
547 }
548 
549 
550 
551 // open new file
552 void fun_open(string filename) {
553  position.clear();
554  mapRuns.clear();
555  mapEventsInRun.clear();
556 
557  FILE * pFile;
558  long size;
559 
560  // checking file size, as we do not want to wait for
561  // the shell to map all the events of a large file.
562  pFile = fopen (filename.c_str(),"rb");
563  if (pFile==NULL) perror ("Error opening file");
564  else
565  {
566  fseek (pFile, 0, SEEK_END);
567  size= ftell(pFile);
568  fclose (pFile);
569  if (size > 50000000) {
570  cout << "Large file: not preparing map of events in runs!" << endl;
571  cout << "(Initialising will still take some time though." << endl;
572  cout << " You can skip it using [ctrl]-[c].)" << endl;
573  withEvents = false;
574  }
575  }
576 
577 
578  egg.replace(1,2,2,'e');
579  position.push_back(level(0, filename));
580 
581  lcReader->open( position[TOP].second ) ;
582  while (( runHdr = lcReader->readNextRunHeader() ) != 0 && !interrupt) {
583  int run = runHdr->getRunNumber();
584  mapRuns.insert ( pair<int, string>(run, runHdr->getDescription()) );
585  mapEventsInRun.insert( pair<int, int>(run, 0));
586  }
587  interrupt = false;
588  lcReader->close() ;
589 
590  if (withEvents) {
591  lcReader->open( position[TOP].second ) ;
592  while ( (event = lcReader->readNextEvent()) != 0 && !interrupt) {
593  (mapEventsInRun[event->getRunNumber()])++;
594  numEvents++;
595  }
596  interrupt = false;
597  lcReader->close() ;
598  }
599 }
600 // end open
601 
602 
603 // help output
604 void fun_help() {
605  cout << " COMMANDS:" << endl;
606  cout << " cd | cl <number of OBJECT|..> change into OBJECT | leave object; multiple levels can be given at once" << endl;
607  cout << " e.g.: file.slcio/run1$ cd ../3/1" << endl;
608  cout << " ls list elements on next level | list content of active collection" << endl;
609  cout << " dump [-d] dump data of active level; -d triggers detailed dump of event" << endl;
610  cout << " print | cat [-s] <collection nr> print content of collection given; -s triggers short print-out" << endl;
611  cout << endl;
612  cout << " open <filename> open new file" << endl;
613  cout << " exit | quit exit program" << endl;
614  cout << " help print this help text" << endl;
615  cout << " pager <command> use pager <command> when paging output" << endl;
616  cout << endl;
617  cout << " REDIRECTION:" <<endl;
618  cout << " If '|' or '>' is appended to the a command, the output will be redirected to a file and then"<<endl;
619  cout << " displayed with the pager (see above)." << endl;
620  cout << " If a string is given after the redirect token, it is used as filename and the file is stored." <<endl;
621  cout << " (existing files will get overwritten without prompt). If no filename is given, a temporary " << endl;
622  cout << " file will be used for paging." << endl;
623  cout << " e.g.: file.slcio/run1/evt1$ dump -d > event1.txt "<<endl;
624 }
625 // end help output
626 
638 int main(int argc, char** argv ) {
639  string temp = egg;
640 
641  // Signal handlers
642  signal(SIGINT, int_handler);
643  signal(SIGTERM, term_handler);
644  temp.push_back('r');
645 
646 
647  // checking command and printing help if necessary
648  if (argc != 2) {
649  cout << "usage: lsh <file name>|-h" << endl;
650  exit(1);
651  }
652  temp.insert(1,"b");
653  if (!strcmp(argv[1], "-h")) {
654  fun_help();
655  exit(0);
656  }
657  temp.erase(0,1);
658 
659 
660  // initialisation
661  cout << setprecision(3) << fixed;
662  lcReader = LCFactory::getInstance()->createLCReader( IO::LCReader::directAccess ) ;
663  egg = temp;
664 
665  fun_open(argv[1]); // opening new file and preparing general information
666  printTop();
667 
668 
669 
671  do {
672 // string commandBuf;
673  vector<string> commandVec;
674  commandVec.reserve( 1024 ) ;
675 
677 // /** ohne readline **/
678 // if (!getline(cin, commandBuf)) {
679 // leave(0);
680 // }
681 // if (!commandBuf.size()) {
682 // continue;
683 // }
684 //
685 // string buf;
686 // stringstream sstream(commandBuf);
687 // while (sstream >> buf) {
688 // commandVec.push_back(buf);
689 // }
690 
691 
692  char *line = readline (print_prompt());
693 
694  // exit with CTRL+D
695  if( *line == '\0' ) {
696  free(line);
697  cout << "exit" << endl;
698  leave(0);
699  }
700 
701  if (!(line && *line)) {
702  free(line);
703  cout << endl;
704  continue;
705  }
706  add_history(line);
707 
708  string buf;
709  stringstream sstream(line);
710  while (sstream >> buf) {
711  commandVec.push_back(buf);
712  }
713  free(line);
714 
716  // check if output should be paged
717  pagerInfo data;
718  data.save = false;
719 
720  int cvSize = commandVec.size();
721  if (cvSize > 1) {
722  // if redirect symbol end command, redirect to tmp-file
723  if ((commandVec[cvSize-1] == "|") || (commandVec[cvSize-1] == ">")) {
724  pageOutput = true;
725  commandVec.pop_back();
726  } else
727  // if redirect symbol is followed by a string, redirect to
728  // a file named according to this string
729  //(careful, file will be truncated without warning)
730  if ((commandVec[cvSize-2] == "|") || (commandVec[cvSize-2] == ">")) {
731  pageOutput = true;
732  data.save = true;
733  // strcpy(data.filename, commandVec[cvSize-1].c_str());
734  //fg: cannot use strcpy w/o memory allocation - assign filename directly from vector
735  // as a workaround (works as long as commandVec does not change...)
736  data.filename = &commandVec[cvSize-1][0] ;
737  }
738  }
739 
740 
741  // if the output is paged, but paging failes, we want to
742  // run the command again, without paging
743  // in addition a message should be printed
744  int run = 0;
745  bool outputSuccess;
746  do {
747  if (pageOutput) {
748  begin_paging(&data);
749  }
750 
751 
752  // select action based on command given
753  // -> improvement: move handling of parameters into functions and
754  // pass pointer to commandVec instead of values
755  if ((commandVec[0] == "exit") || (commandVec[0] == "quit")) {
756  leave(0);
757  }
758  if (commandVec[0] == "ls") {
759  fun_ls();
760  }
761  if ((commandVec[0] == "cl") || (commandVec[0] == "cd")) {
762  fun_cd(commandVec[1]);
763  }
764  if ((commandVec[0] == "print") || (commandVec[0] == "cat")) {
765  // add default output flag, if non was given
766  if (commandVec.size() == 2) {
768  it = ++(commandVec.begin());
769  commandVec.insert ( it , "-d" );
770  }
771  fun_print(commandVec[2], commandVec[1]);
772  }
773  if ((commandVec[0] == "dump")) {
774  if (commandVec.size() < 2) {
775  commandVec.push_back("-s");
776  }
777  fun_dump(commandVec[1]);
778  }
779  if ((commandVec[0] == "open") || (commandVec[0] == "file")) {
780  fun_open(commandVec[1]);
781  }
782  if ((commandVec[0] == egg)) {
783  fun_egg();
784  }
785  if ((commandVec[0] == "help")) {
786  fun_help();
787  }
788  if ((commandVec[0] == "pager")) {
789  pager = commandVec[1];
790  }
791  if (!cin) {
792  leave(0);
793  }
794 
795  if (pageOutput) {
796  outputSuccess = end_paging(&data);
797  } else {
798  outputSuccess = true;
799  }
800  pageOutput = false;
801  ++run;
802  } while (!outputSuccess); // repeat until output succesfully printed (max two runs)
803  if (run > 2) {
804  cout << " paging failed - active pager: " << pager << " run: " << run << endl;
805  cout << " You can set another pager with: pager <command>" << endl;
806  }
807 
808  } while (1 == 1);
809 
810 }
Definition: lsh.cc:52
T perror(T...args)
T system(T...args)
map< int, string > mapRuns
Definition: lsh.cc:66
LCCollection * gCol
Definition: lsh.cc:81
bool withEvents
Definition: lsh.cc:69
void begin_paging(pagerInfo *file)
END SIGNAL HANDLERS.
Definition: lsh.cc:146
T endl(T...args)
T left(T...args)
void normalPrintCol(LCCollection *col)
Definition: lsh.cc:217
LCEvent * event
Definition: lsh.cc:80
T end(T...args)
T free(T...args)
void fun_dump(string arg)
Definition: lsh.cc:504
STL class.
T setw(T...args)
void term_handler(int sig)
Definition: lsh.cc:134
int fd_temp
Definition: lsh.cc:54
T fclose(T...args)
STL class.
void fun_cd(string str)
Definition: lsh.cc:445
T push_back(T...args)
const int TOP
Definition: lsh.cc:60
char * filename
Definition: lsh.cc:53
string prompt
Definition: lsh.cc:75
T data(T...args)
vector< level > position
Definition: lsh.cc:64
T exit(T...args)
T replace(T...args)
void simplePrintCol(LCCollection *col)
END PAGER HANDLING.
Definition: lsh.cc:190
int numEvents
Definition: lsh.cc:68
int main(int argc, char **argv)
Simple program that opens existing LCIO files and appends the records needed for direct access - if t...
T next(T...args)
bool end_paging(pagerInfo *file)
Definition: lsh.cc:161
T append(T...args)
T strcmp(T...args)
T fopen(T...args)
void fun_open(string filename)
Definition: lsh.cc:552
T erase(T...args)
void lsRuns()
END PRINT FUNCTIONS.
Definition: lsh.cc:361
T pop_back(T...args)
string pager
Definition: lsh.cc:73
T strtok(T...args)
T str(T...args)
void fun_print(string colNr, string flag)
Definition: lsh.cc:324
T clear(T...args)
T signal(T...args)
int fd_old
Definition: lsh.cc:55
STL class.
T fixed(T...args)
bool pageOutput
Definition: lsh.cc:71
T strcpy(T...args)
T insert(T...args)
T size(T...args)
STL class.
void lsEvents()
Definition: lsh.cc:379
void int_handler(int sig)
END EXIT.
Definition: lsh.cc:129
void lsCollections()
Definition: lsh.cc:393
T begin(T...args)
T ftell(T...args)
static const int directAccess
Configuration flags for the LCReader instance - to be used with LCFactory::createLCReader().
Definition: LCReader.h:41
LCRunHeader * runHdr
Definition: lsh.cc:79
void fun_egg()
Definition: lsh.cc:541
bool interrupt
Definition: lsh.cc:70
void leave(int ret)
END PROMPT.
Definition: lsh.cc:110
T c_str(T...args)
void fun_ls()
END LS FUNCTIONS.
Definition: lsh.cc:420
LCReader * lcReader
Definition: lsh.cc:78
pair< int, string > level
Definition: lsh.cc:50
const int COL
Definition: lsh.cc:63
bool save
Definition: lsh.cc:56
void fun_help()
Definition: lsh.cc:604
const int RUN
Definition: lsh.cc:61
void dumpEvent(EVENT::LCEvent *event)
const int EVT
Definition: lsh.cc:62
map< int, int > mapEventsInRun
Definition: lsh.cc:67
T setprecision(T...args)
const char * print_prompt()
PROMPT.
Definition: lsh.cc:87
T fseek(T...args)
void printTop()
Definition: lsh.cc:313
T reserve(T...args)
string egg
Definition: lsh.cc:74