source: fact/tools/rootmacros/PulseTemplates/configfile.h@ 14442

Last change on this file since 14442 was 13861, checked in by Jens Buss, 12 years ago
Initial commit: class for reading an interpreting a selfdefined rc filse
  • Property svn:executable set to *
File size: 3.4 KB
Line 
1/** A one line description of the class.
2 *
3 * #include "XX.h" <BR>
4 * -llib
5 *
6 * A longer description.
7 *
8 * @see something
9 */
10
11#ifndef CONFIGFILE_H
12#define CONFIGFILE_H
13
14// SYSTEM INCLUDES
15#include "TString.h"
16
17#include <iostream>
18#include <fstream>
19
20
21//
22
23// PROJECT INCLUDES
24//
25
26// LOCAL INCLUDES
27//
28
29// FORWARD REFERENCES
30//
31
32
33class configfile
34{
35public:
36// LIFECYCLE
37
38 /** Default constructor.
39 */
40 configfile( TString, TString );
41
42
43// /** Copy constructor.
44// *
45// * @param from The value to copy to this object.
46// */
47// XX(const XX& from);
48
49
50 /** Destructor.
51 */
52 ~configfile();
53
54
55// OPERATORS
56
57// /** Assignment operator.
58// *
59// * @param from THe value to assign to this object.
60// *
61// * @return A reference to this object.
62// */
63// XX& operator=(const XX& from);
64
65// OPERATIONS
66
67 void DefineTokens( );
68 void CheckKeywords( TString, const char*, int );
69 bool CheckIfRcReadable( std::ifstream& rcFile );
70 void SetParamFromRc( std::ifstream& rcFile );
71 void PrintSetParameters();
72
73// ACCESS
74// INQUIRY
75
76 TString mRcFileName;
77
78 TString mDataFileName;
79 TString mDrsFileName;
80 TString mInputFile;
81 TString mInputPath;
82 TString mOutputFile;
83 TString mOutputPath;
84
85 int mFirstPixel;
86 int mNumPixel;
87 int mPixelSetSize;
88 int mFirstEvent;
89 int mNumEvents;
90 int mMaxOrder;
91
92 float mGainMean;
93 float mBSLMean;
94
95 int mAmplWindowWidth;
96 int mAvg1;
97 int mAvg2;
98 int mOverlayWindowLeft;
99 int mOverlayWindowRight;
100
101 TString mHistoOptions;
102 int mRefreshRate;
103 int mVerbLevel; // different verbosity levels can be implemented here
104// int mCmdVerbLevel; // different verbosity levels can be implemented here
105 bool mDbgPixel;
106 bool mSave;
107// bool mCmdSave;
108 bool mProduceGraphic;
109// bool mCmdProduceGraphic;
110 bool mFitData;
111 bool mPrintStats;
112 bool mSpikeDebug;
113 bool mTestMode;
114
115protected:
116
117private:
118 TString mProcessType;
119 const char* mDataFileNameRC;
120 const char* mDrsFileNameRC;
121 const char* mInputFileRC;
122 const char* mInputPathRC;
123 const char* mOutputFileRC;
124 const char* mOutputPathRC;
125
126 const char* mFirstPixelRC;
127 const char* mNumPixelRC;
128 const char* mPixelSetSizeRC;
129 const char* mFirstEventRC;
130 const char* mNumEventsRC;
131 const char* mMaxOrderRC;
132
133 const char* mGainMeanRC;
134 const char* mBSLMeanRC;
135
136 const char* mAmplWindowWidthRC;
137 const char* mAvg1RC;
138 const char* mAvg2RC;
139 const char* mOverlayWindowLeftRC;
140 const char* mOverlayWindowRightRC;
141
142 const char* mHistoOptionsRC;
143 const char* mRefreshRateRC;
144 const char* mVerbLevelRC;
145 const char* mDbgPixelRC;
146 const char* mSaveRC;
147 const char* mProduceGraphicRC;
148 const char* mFitDataRC;
149 const char* mPrintStatsRC;
150 const char* mSpikeDebugRC;
151 const char* mTestModeRC;
152};
153
154// INLINE METHODS
155//
156
157// EXTERNAL REFERENCES
158//
159
160#endif // CONFIGFILE_H
Note: See TracBrowser for help on using the repository browser.