source: trunk/MagicSoft/Mars/mreport/MReportFileRead.h@ 6136

Last change on this file since 6136 was 4575, checked in by tbretz, 20 years ago
*** empty log message ***
File size: 1.5 KB
Line 
1#ifndef MARS_MReportFileRead
2#define MARS_MReportFileRead
3
4#ifndef MARS_MTask
5#include "MTask.h"
6#endif
7#ifndef MARS_MTime
8#include "MTime.h"
9#endif
10
11/*// gcc 3.2
12//class ifstream;
13#include <iosfwd>
14*/
15
16class THashTable;
17
18class MTime;
19class MReport;
20class MReportHelp;
21
22class MReportFileRead : public MTask
23{
24private:
25 TString fFileName; // Name of the input file
26
27 THashTable *fList; // List of possible reports to be interpreted
28
29 MTime fStart; // Time range which should be read from file
30 MTime fStop; // Time range which should be read from file
31
32 ULong_t fNumLine; // line counter
33
34 Int_t fVersion; // File format version
35
36 enum { kHasNoHeader = BIT(14) };
37
38 Int_t PreProcess(MParList *pList);
39 Int_t Process();
40 Int_t PostProcess();
41
42 virtual Int_t CheckFileHeader() { return 0; }
43 MReport *GetReport(const TString &str) const;
44 MReport *GetReport(MReportHelp *help) const;
45 MReportHelp *GetReportHelp(const TString &str) const;
46
47protected:
48 ifstream *fIn; //! buffered input stream (file to read from)
49 void SetVersion(Int_t v) { fVersion = v; }
50
51public:
52 MReportFileRead(const char *filename, const char *name=NULL, const char *title=NULL);
53 ~MReportFileRead();
54
55 void SetHasNoHeader() { SetBit(kHasNoHeader); }
56 void SetTimeStart(const MTime &tm) { fStart = tm; }
57 void SetTimeStop(const MTime &tm) { fStop = tm; }
58
59 Bool_t AddToList(const char *name) const;
60
61 ClassDef(MReportFileRead, 0)// Task to read general report file
62};
63
64#endif
Note: See TracBrowser for help on using the repository browser.