/[PAMELA software]/yoda/techmodel/ReaderAlgorithms.h
ViewVC logotype

Diff of /yoda/techmodel/ReaderAlgorithms.h

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.3 by kusanagi, Tue Jul 6 14:07:27 2004 UTC revision 2.2 by kusanagi, Fri Dec 3 22:08:01 2004 UTC
# Line 1  Line 1 
1  /** @file  /** @file
2   * $Author: kusanagi $   * $Author: kusanagi $
3   * $Date: 2004/07/06 13:31:18 $   * $Date: 2004/09/24 11:57:49 $
4   * $Revision: 1.2 $   * $Revision: 2.1 $
5   *   *
6   * Header file for the algorithms used to read the techmodel data file.   * Header file for the algorithms used to read the techmodel data file.
7   */   */
# Line 12  Line 12 
12  #include "TechmodelAlgorithm.h"  #include "TechmodelAlgorithm.h"
13  #include "PscuEvent.h"  #include "PscuEvent.h"
14    
 #include "VarDumpEvent.h"  
 #include "ArrDumpEvent.h"  
 #include "TabDumpEvent.h"  
15    
16  #include "CalibCalEvent.h"  #include "PhysEndRunEvent.h"
17  #include "CalibCalPedEvent.h"  #include "CalibCalPulse1Event.h"
18    #include "CalibCalPulse2Event.h"
19    #include "physics/TrackerReader.h"
20    #include "physics/AnticounterReader.h"
21    #include "physics/CalorimeterReader.h"
22    #include "physics/NeutronDetectorReader.h"
23    #include "CalibTrkBothEvent.h"
24  #include "CalibTrk1Event.h"  #include "CalibTrk1Event.h"
25  #include "CalibTrk2Event.h"  #include "CalibTrk2Event.h"
26  #include "CalibTrdEvent.h"  #include "CalibTrdEvent.h"
27  #include "CalibTofEvent.h"  #include "CalibTofEvent.h"
28  #include "CalibS4Event.h"  #include "CalibS4Event.h"
29    #include "CalibCalPedEvent.h"
30    #include "CalibAcEvent.h"
31  #include "RunHeaderEvent.h"  #include "RunHeaderEvent.h"
32  #include "RunTrailerEvent.h"  #include "RunTrailerEvent.h"
33  #include "ForcedPktEvent.h"  #include "CalibHeaderEvent.h"
34    #include "CalibTrailerEvent.h"
35    #include "InitHeaderEvent.h"
36    #include "InitTrailerEvent.h"
37    #include "EventTrkEvent.h"
38    #include "TestTrkEvent.h"
39    #include "TestTofEvent.h"
40    #include "log/LogEvent.h"
41    #include "varDump/VarDumpEvent.h"
42    #include "arrDump/ArrDumpEvent.h"
43    #include "tabDump/TabDumpEvent.h"
44  #include "tmtc/TmtcEvent.h"  #include "tmtc/TmtcEvent.h"
45  #include "mcmd/McmdEvent.h"  #include "mcmd/McmdEvent.h"
46  #include "log/LogEvent.h"  #include "ForcedFECmdEvent.h"
47    #include "AcInitEvent.h"
48  #include "physics/TrackerReader.h"  #include "CalInitEvent.h"
49    #include "TrkInitEvent.h"
50  #define UINT32 unsigned int  #include "TofInitEvent.h"
51  #define UINT16 unsigned short  #include "TrgInitEvent.h"
52  #define BYTE   unsigned char  #include "NdInitEvent.h"
53    #include "CalAlarmEvent.h"
54    #include "AcAlarmEvent.h"
55    #include "TrkAlarmEvent.h"
56    #include "TrgAlarmEvent.h"
57    #include "TofAlarmEvent.h"
58    
59  using namespace std;  using namespace std;
60    
61  namespace pamela {  namespace pamela {
62    namespace techmodel {    namespace techmodel {
63      /**  
64       * Event reader algorithm for physics events.  /**********************************************
65       */  * Event reader algorithm for PhysEndRun events.
66    **********************************************/
67        class PhysEndRunReader: public TechmodelAlgorithm {
68        private:
69          /** The PhysEndRun event that is created in the reader. */
70          PhysEndRunEvent* physEndRun;
71        public:
72          PhysEndRunReader(void);
73          virtual void Init(PamelaRun *);
74          virtual void RunEvent(int, long int) throw (WrongCRCException);
75          //this type of RUNEvent should be the future develop.
76          //Pass the buffer not the pointer to file
77          //virtual void RunEvent(int, long int, char[]);
78          virtual std::string GetVersionInfo(void) const;
79        };
80    
81    
82    /**********************************************
83    * Event reader algorithm for CalibCalPulse1 events.
84    **********************************************/
85        class CalibCalPulse1Reader: public TechmodelAlgorithm {
86        private:
87          /** The CalibCalPulse1 event that is created in the reader. */
88          CalibCalPulse1Event* calibCalPulse1;
89        public:
90          CalibCalPulse1Reader(void);
91          virtual void Init(PamelaRun *);
92          virtual void RunEvent(int, long int) throw (Exception);
93          //this type of RUNEvent should be the future develop.
94          //Pass the buffer not the pointer to file
95          //virtual void RunEvent(int, long int, char[]);
96          virtual std::string GetVersionInfo(void) const;
97        };
98    
99    
100    /**********************************************
101    * Event reader algorithm for CalibCalPulse2 events.
102    **********************************************/
103        class CalibCalPulse2Reader: public TechmodelAlgorithm {
104        private:
105          /** The CalibCalPulse2 event that is created in the reader. */
106          CalibCalPulse2Event* calibCalPulse2;
107        public:
108          CalibCalPulse2Reader(void);
109          virtual void Init(PamelaRun *);
110          virtual void RunEvent(int, long int) throw (Exception);
111          //this type of RUNEvent should be the future develop.
112          //Pass the buffer not the pointer to file
113          //virtual void RunEvent(int, long int, char[]);
114          virtual std::string GetVersionInfo(void) const;
115        };
116    
117    
118    /**********************************************
119    * Event reader algorithm for physics events.
120    **********************************************/
121      class PhysicsReader: public TechmodelAlgorithm {      class PhysicsReader: public TechmodelAlgorithm {
122      private:      private:
123        /** The reader for tracker physics events. */        /** The reader for tracker physics events. */
124        tracker::TrackerReader* trackerReader;        tracker::TrackerReader*           trackerReader;
125        /** The reader for anticoincidence physics events. */        anticounter::AnticounterReader*   anticounterReader;
126        //anticoinc::AnticounterReader* AcReader;        calorimeter::CalorimeterReader*   calorimeterReader;
127        /** The reader for calorimeter physics events. */        neutron::NeutronDetectorReader*   neutronReader;
       //calorimeter::CalorimeterReader* CalorimeterReader;  
128      public:      public:
129        PhysicsReader(void);        PhysicsReader(void);
130        virtual void Init(PamelaRun *);        virtual void Init(PamelaRun *);
131        virtual void RunEvent(int, long int);        virtual void RunEvent(int, long int) throw (Exception);
132        virtual std::string GetVersionInfo(void) const;        virtual std::string GetVersionInfo(void) const;
133      };      };
134    
135      /**  
136       * Event reader algorithm for housekeeping events.  /**********************************************
137       */  * Event reader algorithm for CalibTrkBoth events.
138      /*  **********************************************/
139      class HousekeepingReader: public TechmodelAlgorithm {      class CalibTrkBothReader: public TechmodelAlgorithm {
140      private:      private:
141          /** The CalibTrkBoth event that is created in the reader. */
142          CalibTrkBothEvent* calibTrkBoth;
143      public:      public:
144        HousekeepingReader(void);        CalibTrkBothReader(void);
145        virtual void Init(PamelaRun *);        virtual void Init(PamelaRun *);
146        virtual void RunEvent(int);        virtual void RunEvent(int, long int) throw (Exception);
147        virtual string GetVersionInfo(void) const;        //this type of RUNEvent should be the future develop.
148          //Pass the buffer not the pointer to file
149          //virtual void RunEvent(int, long int, char[]);
150          virtual std::string GetVersionInfo(void) const;
151      };      };
     */  
152    
153    
154      /**  /**********************************************
155       * Event reader algorithm for TMTC events.  * Event reader algorithm for CalibTrk1 events.
156       */  **********************************************/
157      class TmtcReader: public TechmodelAlgorithm {      class CalibTrk1Reader: public TechmodelAlgorithm {
     //Length in bytes of the subPacket (that is te TmtcRecord excluded subCRC)  
     static const int TMTC_SUB_LENGTH = 57;  
     //Length in bytes of the subPacketCRC  
     static const int TMTC_SUBCRC_LENGTH = 1;  
     //Length in bytes of the PacketCRC  
     static const int TMTC_CRC_LENGTH = 2;  
158      private:      private:
159        /** The TMTC event that is created in the reader. */        /** The CalibTrk1 event that is created in the reader. */
160        TmtcEvent* Tmtc;        CalibTrk1Event* calibTrk1;
       float convert_th(int);  
161      public:      public:
162      TmtcReader(void);        CalibTrk1Reader(void);
163      virtual void Init(PamelaRun *);        virtual void Init(PamelaRun *);
164      virtual void RunEvent(int, long int);        virtual void RunEvent(int, long int) throw (Exception);
165      virtual string GetVersionInfo(void) const;        //this type of RUNEvent should be the future develop.
166          //Pass the buffer not the pointer to file
167          //virtual void RunEvent(int, long int, char[]);
168          virtual std::string GetVersionInfo(void) const;
169      };      };
170    
171    
172      /**  /**********************************************
173       * Event reader algorithm for PSCU events.  * Event reader algorithm for CalibTrk2 events.
174       */  **********************************************/
175      class PscuReader: public TechmodelAlgorithm {      class CalibTrk2Reader: public TechmodelAlgorithm {
176      private:      private:
177        /** The PSCU event that is created in the reader. */        /** The CalibTrk2 event that is created in the reader. */
178        PscuEvent* Pscu;        CalibTrk2Event* calibTrk2;
179      public:      public:
180        PscuReader(void);        CalibTrk2Reader(void);
181          virtual void Init(PamelaRun *);
182          virtual void RunEvent(int, long int) throw (Exception);
183          virtual std::string GetVersionInfo(void) const;
184        };
185    
186    
187    /**********************************************
188    * Event reader algorithm for CalibTrd events.
189    **********************************************/
190        class CalibTrdReader: public TechmodelAlgorithm {
191        private:
192          /** The CalibTrd event that is created in the reader. */
193          CalibTrdEvent* calibTrd;
194        public:
195          CalibTrdReader(void);
196          virtual void Init(PamelaRun *);
197          virtual void RunEvent(int, long int) throw (Exception);
198          virtual std::string GetVersionInfo(void) const;
199        };
200    
201    
202    /**********************************************
203    * Event reader algorithm for CalibTof events.
204    **********************************************/
205        class CalibTofReader: public TechmodelAlgorithm {
206        private:
207          /** The CalibTof event that is created in the reader. */
208          CalibTofEvent* CalibTof;
209        public:
210          CalibTofReader(void);
211          virtual void Init(PamelaRun *);
212          virtual void RunEvent(int, long int) throw (Exception);
213          virtual std::string GetVersionInfo(void) const;
214        };
215    
216    
217    /**********************************************
218    * Event reader algorithm for CalibS4 events.
219    **********************************************/
220        class CalibS4Reader: public TechmodelAlgorithm {
221        private:
222          /** The CalibCal event that is created in the reader. */
223          CalibS4Event* CalibS4;
224        public:
225          CalibS4Reader(void);
226        virtual void Init(PamelaRun *);        virtual void Init(PamelaRun *);
227        virtual void RunEvent(int, long int);        virtual void RunEvent(int, long int) throw (Exception);
228        virtual std::string GetVersionInfo(void) const;        virtual std::string GetVersionInfo(void) const;
229      };      };
230    
231      /**  
232       * Event reader algorithm for VarDump events.  /**********************************************
233       */  * Event reader algorithm for CalibCalPed events.
234    **********************************************/
235        class CalibCalPedReader: public TechmodelAlgorithm {
236        private:
237          /** The CalibCalPed event that is created in the reader. */
238          CalibCalPedEvent* calibCalPed;
239        public:
240          CalibCalPedReader(void);
241          virtual void Init(PamelaRun *);
242          virtual void RunEvent(int, long int) throw (Exception);
243          virtual std::string GetVersionInfo(void) const;
244        };
245    
246    
247    /***********************************************
248    * Event reader algorithm for CalibAc events.
249    **********************************************/
250        class CalibAcReader: public TechmodelAlgorithm {
251        private:
252          /** The CalibAc event that is created in the reader. */
253          CalibAcEvent* CalibAc;
254        public:
255          CalibAcReader(void);
256          virtual void Init(PamelaRun *);
257          virtual void RunEvent(int, long int) throw (Exception);
258          virtual std::string GetVersionInfo(void) const;
259        };
260    
261    
262    /**********************************************
263    * Event reader algorithm for RunHeader events.
264    **********************************************/
265        class RunHeaderReader: public TechmodelAlgorithm {
266        private:
267          /** The RunHeader event that is created in the reader. */
268          RunHeaderEvent* RunHeader;
269        public:
270          RunHeaderReader(void);
271          virtual void Init(PamelaRun *);
272          virtual void RunEvent(int, long int) throw (WrongCRCException);
273          virtual std::string GetVersionInfo(void) const;
274        };
275    
276    
277    /**********************************************
278    * Event reader algorithm for RunTrailer events.
279    **********************************************/
280        class RunTrailerReader: public TechmodelAlgorithm {
281        private:
282          /** The RunTrailer event that is created in the reader. */
283          RunTrailerEvent* RunTrailer;
284        public:
285          RunTrailerReader(void);
286          virtual void Init(PamelaRun *);
287          virtual void RunEvent(int, long int) throw (WrongCRCException);
288          virtual std::string GetVersionInfo(void) const;
289        };
290    
291    
292    /**********************************************
293    * Event reader algorithm for CalibHeader events.
294    **********************************************/
295        class CalibHeaderReader: public TechmodelAlgorithm {
296        private:
297          /** The CalibHeader event that is created in the reader. */
298          CalibHeaderEvent* calibHeader;
299        public:
300          CalibHeaderReader(void);
301          virtual void Init(PamelaRun *);
302          virtual void RunEvent(int, long int) throw (WrongCRCException);
303          virtual std::string GetVersionInfo(void) const;
304        };
305    
306    
307    /**********************************************
308    * Event reader algorithm for CalibTrailer events.
309    **********************************************/
310        class CalibTrailerReader: public TechmodelAlgorithm {
311        private:
312          /** The CalibTrailer event that is created in the reader. */
313          CalibTrailerEvent* calibTrailer;
314        public:
315          CalibTrailerReader(void);
316          virtual void Init(PamelaRun *);
317          virtual void RunEvent(int, long int) throw (WrongCRCException);
318          virtual std::string GetVersionInfo(void) const;
319        };
320    
321    
322    /**********************************************
323    * Event reader algorithm for InitHeader events.
324    **********************************************/
325        class InitHeaderReader: public TechmodelAlgorithm {
326        private:
327          /** The InitHeader event that is created in the reader. */
328          InitHeaderEvent* initHeader;
329        public:
330          InitHeaderReader(void);
331          virtual void Init(PamelaRun *);
332          virtual void RunEvent(int, long int) throw (WrongCRCException);
333          virtual std::string GetVersionInfo(void) const;
334        };
335    
336    
337    /**********************************************
338    * Event reader algorithm for InitTrailer events.
339    **********************************************/
340        class InitTrailerReader: public TechmodelAlgorithm {
341        private:
342          /** The InitTrailer event that is created in the reader. */
343          InitTrailerEvent* initTrailer;
344        public:
345          InitTrailerReader(void);
346          virtual void Init(PamelaRun *);
347          virtual void RunEvent(int, long int) throw (WrongCRCException);
348          virtual std::string GetVersionInfo(void) const;
349        };
350    
351    
352    /**********************************************
353    * Event reader algorithm for EventTrk events.
354    **********************************************/
355        class EventTrkReader: public TechmodelAlgorithm {
356        private:
357          /** The EventTrk event that is created in the reader. */
358          EventTrkEvent* eventTrk;
359        public:
360          EventTrkReader(void);
361          virtual void Init(PamelaRun *);
362          virtual void RunEvent(int, long int) throw (Exception);
363          virtual std::string GetVersionInfo(void) const;
364        };
365    
366    
367    /**********************************************
368    * Event reader algorithm for TestTrk events.
369    **********************************************/
370        class TestTrkReader: public TechmodelAlgorithm {
371        private:
372          /** The TestTrk event that is created in the reader. */
373          TestTrkEvent* testTrk;
374        public:
375          TestTrkReader(void);
376          virtual void Init(PamelaRun *);
377          virtual void RunEvent(int, long int) throw (Exception);
378          virtual std::string GetVersionInfo(void) const;
379        };
380    
381    /**********************************************
382    * Event reader algorithm for TestTof events.
383    **********************************************/
384        class TestTofReader: public TechmodelAlgorithm {
385        private:
386          /** The TestTof event that is created in the reader. */
387          TestTofEvent* testTof;
388        public:
389          TestTofReader(void);
390          virtual void Init(PamelaRun *);
391          virtual void RunEvent(int, long int) throw (Exception);
392          virtual std::string GetVersionInfo(void) const;
393        };
394    
395    /**********************************************
396    * Event reader algorithm for Log events.
397    **********************************************/
398        class LogReader: public TechmodelAlgorithm {
399        private:
400          /** The Log event that is created in the reader. */
401          LogEvent* Log;
402        public:
403          LogReader(void);
404          virtual void Init(PamelaRun *);
405          virtual void RunEvent(int, long int) throw (WrongCRCException);
406          virtual std::string GetVersionInfo(void) const;
407        };
408    
409    
410    /***********************************************
411    * Event reader algorithm for VarDump events.
412    **********************************************/
413      class VarDumpReader: public TechmodelAlgorithm {      class VarDumpReader: public TechmodelAlgorithm {
414      private:      private:
415        /** The VarDump event that is created in the reader. */        /** The VarDump event that is created in the reader. */
# Line 119  namespace pamela { Line 417  namespace pamela {
417      public:      public:
418        VarDumpReader(void);        VarDumpReader(void);
419        virtual void Init(PamelaRun *);        virtual void Init(PamelaRun *);
420        virtual void RunEvent(int, long int);        virtual void RunEvent(int, long int) throw (WrongCRCException);
421        virtual std::string GetVersionInfo(void) const;        virtual std::string GetVersionInfo(void) const;
422      };      };
423    
424      /**  
425       * Event reader algorithm for ArrDump events.  /**********************************************
426       */  * Event reader algorithm for ArrDump events.
427    **********************************************/
428      class ArrDumpReader: public TechmodelAlgorithm {      class ArrDumpReader: public TechmodelAlgorithm {
429      private:      private:
430        /** The ArrDump event that is created in the reader. */        /** The ArrDump event that is created in the reader. */
# Line 133  namespace pamela { Line 432  namespace pamela {
432      public:      public:
433        ArrDumpReader(void);        ArrDumpReader(void);
434        virtual void Init(PamelaRun *);        virtual void Init(PamelaRun *);
435        virtual void RunEvent(int, long int);        virtual void RunEvent(int, long int) throw (WrongCRCException);
436        virtual std::string GetVersionInfo(void) const;        virtual std::string GetVersionInfo(void) const;
437      };      };
438    
439      /**  
440       * Event reader algorithm for TabDump events.  /**********************************************
441       */  * Event reader algorithm for TabDump events.
442    **********************************************/
443      class TabDumpReader: public TechmodelAlgorithm {      class TabDumpReader: public TechmodelAlgorithm {
444      private:      private:
445        /** The TabDump event that is created in the reader. */        /** The TabDump event that is created in the reader. */
# Line 147  namespace pamela { Line 447  namespace pamela {
447      public:      public:
448        TabDumpReader(void);        TabDumpReader(void);
449        virtual void Init(PamelaRun *);        virtual void Init(PamelaRun *);
450        virtual void RunEvent(int, long int);        virtual void RunEvent(int, long int) throw (WrongCRCException);
451        virtual std::string GetVersionInfo(void) const;        virtual std::string GetVersionInfo(void) const;
452      };      };
453    
454      /**  
455       * Event reader algorithm for Mcmd events.  /**********************************************
456       */  * Event reader algorithm for TMTC events.
457    **********************************************/
458        class TmtcReader: public TechmodelAlgorithm {
459        //Length in bytes of the subPacket (that is te TmtcRecord excluded subCRC)
460        static const int TMTC_SUB_LENGTH = 57;
461        //Length in bytes of the subPacketCRC
462        static const int TMTC_SUBCRC_LENGTH = 1;
463        //Length in bytes of the PacketCRC
464        static const int TMTC_CRC_LENGTH = 2;
465        private:
466          /** The TMTC event that is created in the reader. */
467          TmtcEvent* Tmtc;
468          float convert_th(int);
469        public:
470        TmtcReader(void);
471        virtual void Init(PamelaRun *);
472        virtual void RunEvent(int, long int) throw (WrongCRCException);
473        virtual string GetVersionInfo(void) const;
474        };
475    
476    
477    /**********************************************
478    * Event reader algorithm for Mcmd events.
479    **********************************************/
480      class McmdReader: public TechmodelAlgorithm {      class McmdReader: public TechmodelAlgorithm {
481      private:      private:
482        /** The Mcmd event that is created in the reader. */        /** The Mcmd event that is created in the reader. */
# Line 161  namespace pamela { Line 484  namespace pamela {
484      public:      public:
485        McmdReader(void);        McmdReader(void);
486        virtual void Init(PamelaRun *);        virtual void Init(PamelaRun *);
487        virtual void RunEvent(int, long int);        virtual void RunEvent(int, long int) throw (WrongCRCException);
488        virtual std::string GetVersionInfo(void) const;        virtual std::string GetVersionInfo(void) const;
489      };      };
490    
491  /**  
492       * Event reader algorithm for Log events.  /**********************************************
493       */  * Event reader algorithm for ForcedFECmd events.
494      class LogReader: public TechmodelAlgorithm {  **********************************************/
495        class ForcedFECmdReader: public TechmodelAlgorithm {
496      private:      private:
497        /** The Log event that is created in the reader. */        /** The ForcedFECmd event that is created in the reader. */
498        LogEvent* Log;        ForcedFECmdEvent* forcedFECmd;
499      public:      public:
500        LogReader(void);        ForcedFECmdReader(void);
501        virtual void Init(PamelaRun *);        virtual void Init(PamelaRun *);
502        virtual void RunEvent(int, long int);        virtual void RunEvent(int, long int) throw (WrongCRCException);
503        virtual std::string GetVersionInfo(void) const;        virtual std::string GetVersionInfo(void) const;
504      };      };
505    
506  /**  
507       * Event reader algorithm for CalibCal events.  /**********************************************
508       */  * Event reader algorithm for AcInit events.
509      class CalibCalReader: public TechmodelAlgorithm {  **********************************************/
510        class AcInitReader: public TechmodelAlgorithm {
511      private:      private:
512        /** The CalibCal event that is created in the reader. */        /** The AcInit event that is created in the reader. */
513        CalibCalEvent* CalibCal;        AcInitEvent* acInit;
514      public:      public:
515        CalibCalReader(void);        AcInitReader(void);
516        virtual void Init(PamelaRun *);        virtual void Init(PamelaRun *);
517        virtual void RunEvent(int, long int);        virtual void RunEvent(int, long int) throw (WrongCRCException);
518        virtual std::string GetVersionInfo(void) const;        virtual std::string GetVersionInfo(void) const;
519      };      };
520    
521  /**  
522       * Event reader algorithm for CalibCalPed events.  /**********************************************
523       */  * Event reader algorithm for CalInit events.
524      class CalibCalPedReader: public TechmodelAlgorithm {  **********************************************/
525        class CalInitReader: public TechmodelAlgorithm {
526      private:      private:
527        /** The CalibCalPed event that is created in the reader. */        /** The CalInit event that is created in the reader. */
528        CalibCalPedEvent* CalibCalPed;        CalInitEvent* calInit;
529      public:      public:
530        CalibCalPedReader(void);        CalInitReader(void);
531        virtual void Init(PamelaRun *);        virtual void Init(PamelaRun *);
532        virtual void RunEvent(int, long int);        virtual void RunEvent(int, long int) throw (WrongCRCException);
533        virtual std::string GetVersionInfo(void) const;        virtual std::string GetVersionInfo(void) const;
534      };      };
535    
536    
537  /**  /**********************************************
538       * Event reader algorithm for CalibTrk1 events.  * Event reader algorithm for TrkInit events.
539       */  **********************************************/
540      class CalibTrk1Reader: public TechmodelAlgorithm {      class TrkInitReader: public TechmodelAlgorithm {
541      private:      private:
542        /** The CalibTrk1 event that is created in the reader. */        /** The TrkInit event that is created in the reader. */
543        CalibTrk1Event* calibTrk1;        TrkInitEvent* trkInit;
544      public:      public:
545        CalibTrk1Reader(void);        TrkInitReader(void);
546        virtual void Init(PamelaRun *);        virtual void Init(PamelaRun *);
547        virtual void RunEvent(int, long int);        virtual void RunEvent(int, long int) throw (WrongCRCException);
       //this type of RUNEvent should be the future develop.  
       //Pass the buffer not the pointer to file  
       //virtual void RunEvent(int, long int, char[]);  
548        virtual std::string GetVersionInfo(void) const;        virtual std::string GetVersionInfo(void) const;
549      };      };
550    
551  /**  
552       * Event reader algorithm for CalibTrk2 events.  /**********************************************
553       */  * Event reader algorithm for TofInit events.
554      class CalibTrk2Reader: public TechmodelAlgorithm {  **********************************************/
555        class TofInitReader: public TechmodelAlgorithm {
556      private:      private:
557        /** The CalibTrk2 event that is created in the reader. */        /** The TofInit event that is created in the reader. */
558        CalibTrk2Event* calibTrk2;        TofInitEvent* tofInit;
559      public:      public:
560        CalibTrk2Reader(void);        TofInitReader(void);
561        virtual void Init(PamelaRun *);        virtual void Init(PamelaRun *);
562        virtual void RunEvent(int, long int);        virtual void RunEvent(int, long int) throw (WrongCRCException);
563        virtual std::string GetVersionInfo(void) const;        virtual std::string GetVersionInfo(void) const;
564      };      };
565    
566  /**  
567       * Event reader algorithm for CalibTrd events.  /**********************************************
568       */  * Event reader algorithm for TrgInit events.
569      class CalibTrdReader: public TechmodelAlgorithm {  **********************************************/
570        class TrgInitReader: public TechmodelAlgorithm {
571      private:      private:
572        /** The CalibTrd event that is created in the reader. */        /** The TrgInit event that is created in the reader. */
573        CalibTrdEvent* CalibTrd;        TrgInitEvent* trgInit;
574      public:      public:
575        CalibTrdReader(void);        TrgInitReader(void);
576        virtual void Init(PamelaRun *);        virtual void Init(PamelaRun *);
577        virtual void RunEvent(int, long int);        virtual void RunEvent(int, long int) throw (WrongCRCException);
578        virtual std::string GetVersionInfo(void) const;        virtual std::string GetVersionInfo(void) const;
579      };      };
580    
581  /**  /**********************************************
582       * Event reader algorithm for CalibTof events.  * Event reader algorithm for NdInit events.
583       */  **********************************************/
584      class CalibTofReader: public TechmodelAlgorithm {      class NdInitReader: public TechmodelAlgorithm {
585      private:      private:
586        /** The CalibTof event that is created in the reader. */        /** The NdInit event that is created in the reader. */
587        CalibTofEvent* CalibTof;        NdInitEvent* ndInit;
588      public:      public:
589        CalibTofReader(void);        NdInitReader(void);
590        virtual void Init(PamelaRun *);        virtual void Init(PamelaRun *);
591        virtual void RunEvent(int, long int);        virtual void RunEvent(int, long int) throw (WrongCRCException);
592        virtual std::string GetVersionInfo(void) const;        virtual std::string GetVersionInfo(void) const;
593      };      };
594    
595  /**  
596       * Event reader algorithm for CalibS4 events.  /**********************************************
597       */  * Event reader algorithm for CalAlarm events.
598      class CalibS4Reader: public TechmodelAlgorithm {  **********************************************/
599        class CalAlarmReader: public TechmodelAlgorithm {
600      private:      private:
601        /** The CalibCal event that is created in the reader. */        /** The CalAlarm event that is created in the reader. */
602        CalibS4Event* CalibS4;        CalAlarmEvent* calAlarm;
603      public:      public:
604        CalibS4Reader(void);        CalAlarmReader(void);
605        virtual void Init(PamelaRun *);        virtual void Init(PamelaRun *);
606        virtual void RunEvent(int, long int);        virtual void RunEvent(int, long int) throw (WrongCRCException);
607        virtual std::string GetVersionInfo(void) const;        virtual std::string GetVersionInfo(void) const;
608      };      };
609    
610    /**********************************************
611    * Event reader algorithm for AcAlarm events.
612    **********************************************/
613        class AcAlarmReader: public TechmodelAlgorithm {
614        private:
615          /** The AcAlarm event that is created in the reader. */
616          AcAlarmEvent* acAlarm;
617        public:
618          AcAlarmReader(void);
619          virtual void Init(PamelaRun *);
620          virtual void RunEvent(int, long int) throw (WrongCRCException);
621          virtual std::string GetVersionInfo(void) const;
622        };
623    
624  /**  /**********************************************
625       * Event reader algorithm for RunTrailer events.  * Event reader algorithm for TrkAlarm events.
626       */  **********************************************/
627      class RunTrailerReader: public TechmodelAlgorithm {      class TrkAlarmReader: public TechmodelAlgorithm {
628      private:      private:
629        /** The RunTrailer event that is created in the reader. */        /** The TrkAlarm event that is created in the reader. */
630        RunTrailerEvent* RunTrailer;        TrkAlarmEvent* trkAlarm;
631      public:      public:
632        RunTrailerReader(void);        TrkAlarmReader(void);
633        virtual void Init(PamelaRun *);        virtual void Init(PamelaRun *);
634        virtual void RunEvent(int, long int);        virtual void RunEvent(int, long int) throw (WrongCRCException);
635        virtual std::string GetVersionInfo(void) const;        virtual std::string GetVersionInfo(void) const;
636      };      };
637    
638  /**  /**********************************************
639       * Event reader algorithm for RunHeader events.  * Event reader algorithm for TrgAlarm events.
640       */  **********************************************/
641      class RunHeaderReader: public TechmodelAlgorithm {      class TrgAlarmReader: public TechmodelAlgorithm {
642      private:      private:
643        /** The RunHeader event that is created in the reader. */        /** The TrgAlarm event that is created in the reader. */
644        RunHeaderEvent* RunHeader;        TrgAlarmEvent* trgAlarm;
645      public:      public:
646        RunHeaderReader(void);        TrgAlarmReader(void);
647        virtual void Init(PamelaRun *);        virtual void Init(PamelaRun *);
648        virtual void RunEvent(int, long int);        virtual void RunEvent(int, long int) throw (WrongCRCException);
649        virtual std::string GetVersionInfo(void) const;        virtual std::string GetVersionInfo(void) const;
650      };      };
651    
652  /**  /**********************************************
653       * Event reader algorithm for ForcedPkt events.  * Event reader algorithm for TofAlarm events.
654       */  **********************************************/
655      class ForcedPktReader: public TechmodelAlgorithm {      class TofAlarmReader: public TechmodelAlgorithm {
656      private:      private:
657        /** The ForcedPkt event that is created in the reader. */        /** The TofAlarm event that is created in the reader. */
658        ForcedPktEvent* ForcedPkt;        TofAlarmEvent* tofAlarm;
659      public:      public:
660        ForcedPktReader(void);        TofAlarmReader(void);
661        virtual void Init(PamelaRun *);        virtual void Init(PamelaRun *);
662        virtual void RunEvent(int, long int);        virtual void RunEvent(int, long int) throw (WrongCRCException);
663        virtual std::string GetVersionInfo(void) const;        virtual std::string GetVersionInfo(void) const;
664      };      };
665    
666    /**********************************************
667    * Event reader algorithm for PSCU events.
668    **********************************************/
669        class PscuReader: public TechmodelAlgorithm {
670        private:
671          /** The PSCU event that is created in the reader. */
672          PscuEvent* Pscu;
673        public:
674          PscuReader(void);
675          virtual void Init(PamelaRun *);
676          virtual void RunEvent(int, long int) throw (WrongCRCException);
677          virtual std::string GetVersionInfo(void) const;
678        };
679    
680    
681    }    }
682  }  }
683    

Legend:
Removed from v.1.3  
changed lines
  Added in v.2.2

  ViewVC Help
Powered by ViewVC 1.1.23