/[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.1 by kusanagi, Tue Jul 6 12:20:23 2004 UTC revision 2.9 by kusanagi, Thu Mar 3 13:04:41 2005 UTC
# Line 1  Line 1 
1  /** @file  /** @file
2   * $Author: nagni $   * $Author: kusanagi $
3   * $Date: 2004/06/09 23:18:20 $   * $Date: 2005/02/18 18:19:14 $
4   * $Revision: 1.9 $   * $Revision: 2.8 $
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    
15  #include "VarDumpEvent.h"  
16  #include "ArrDumpEvent.h"  #include "endrun/PhysEndRunEvent.h"
17  #include "TabDumpEvent.h"  #include "CalibCalPulse1Event.h"
18    #include "CalibCalPulse2Event.h"
19  #include "CalibCalEvent.h"  #include "physics/TrackerReader.h"
20  #include "CalibTrkEvent.h"  #include "physics/AnticounterReader.h"
21  #include "CalibTrgEvent.h"  #include "physics/CalorimeterReader.h"
22    #include "physics/NeutronDetectorReader.h"
23    #include "physics/S4Reader.h"
24    #include "physics/TofReader.h"
25    #include "physics/TriggerReader.h"
26    #include "CalibTrkBothEvent.h"
27    #include "CalibTrk1Event.h"
28    #include "CalibTrk2Event.h"
29  #include "CalibTrdEvent.h"  #include "CalibTrdEvent.h"
30  #include "CalibTofEvent.h"  #include "CalibTofEvent.h"
31  #include "CalibS4Event.h"  #include "CalibS4Event.h"
32    #include "CalibCalPedEvent.h"
33    #include "Calib1_Ac1Event.h"
34    #include "Calib1_Ac2Event.h"
35    #include "Calib2_Ac1Event.h"
36    #include "Calib2_Ac2Event.h"
37  #include "RunHeaderEvent.h"  #include "RunHeaderEvent.h"
38  #include "RunTrailerEvent.h"  #include "RunTrailerEvent.h"
39  #include "ForcedPktEvent.h"  #include "CalibHeaderEvent.h"
40    #include "CalibTrailerEvent.h"
41    #include "InitHeaderEvent.h"
42    #include "InitTrailerEvent.h"
43    #include "EventTrkEvent.h"
44    #include "TestTrkEvent.h"
45    #include "TestTofEvent.h"
46    #include "log/LogEvent.h"
47    #include "varDump/VarDumpEvent.h"
48    #include "arrDump/ArrDumpEvent.h"
49    #include "tabDump/TabDumpEvent.h"
50    #include "tsbt/TsbTEvent.h"
51    #include "tsbb/TsbBEvent.h"
52  #include "tmtc/TmtcEvent.h"  #include "tmtc/TmtcEvent.h"
53  #include "mcmd/McmdEvent.h"  #include "mcmd/McmdEvent.h"
54  #include "log/LogEvent.h"  #include "ForcedFECmdEvent.h"
55    #include "Ac1InitEvent.h"
56  #include "physics/TrackerReader.h"  #include "CalInitEvent.h"
57    #include "TrkInitEvent.h"
58  #define UINT32 unsigned int  #include "TofInitEvent.h"
59  #define UINT16 unsigned short  #include "TrgInitEvent.h"
60  #define BYTE   unsigned char  #include "NdInitEvent.h"
61    #include "S4InitEvent.h"
62    #include "Ac2InitEvent.h"
63    #include "CalAlarmEvent.h"
64    #include "AcAlarmEvent.h"
65    #include "TrkAlarmEvent.h"
66    #include "TrgAlarmEvent.h"
67    #include "TofAlarmEvent.h"
68    #include "S4AlarmEvent.h"
69    
70  using namespace std;  using namespace std;
71    
72  namespace pamela {  namespace pamela {
73    namespace techmodel {    namespace techmodel {
74      /**  
75       * Event reader algorithm for physics events.  /**********************************************
76       */  * Event reader algorithm for PhysEndRun events.
77    **********************************************/
78        class PhysEndRunReader: public TechmodelAlgorithm {
79        private:
80          /** The PhysEndRun event that is created in the reader. */
81          PhysEndRunEvent* physEndRun;
82        public:
83          PhysEndRunReader(void);
84          virtual void Init(PamelaRun *);
85          virtual void RunEvent(int, long int) throw (WrongCRCException);
86          //this type of RUNEvent should be the future develop.
87          //Pass the buffer not the pointer to file
88          //virtual void RunEvent(int, long int, char[]);
89          virtual std::string GetVersionInfo(void) const;
90        };
91    
92    
93    /**********************************************
94    * Event reader algorithm for CalibCalPulse1 events.
95    **********************************************/
96        class CalibCalPulse1Reader: public TechmodelAlgorithm {
97        private:
98          /** The CalibCalPulse1 event that is created in the reader. */
99          CalibCalPulse1Event* calibCalPulse1;
100        public:
101          CalibCalPulse1Reader(void);
102          virtual void Init(PamelaRun *);
103          virtual void RunEvent(int, long int) throw (Exception);
104          //this type of RUNEvent should be the future develop.
105          //Pass the buffer not the pointer to file
106          //virtual void RunEvent(int, long int, char[]);
107          virtual std::string GetVersionInfo(void) const;
108        };
109    
110    
111    /**********************************************
112    * Event reader algorithm for CalibCalPulse2 events.
113    **********************************************/
114        class CalibCalPulse2Reader: public TechmodelAlgorithm {
115        private:
116          /** The CalibCalPulse2 event that is created in the reader. */
117          CalibCalPulse2Event* calibCalPulse2;
118        public:
119          CalibCalPulse2Reader(void);
120          virtual void Init(PamelaRun *);
121          virtual void RunEvent(int, long int) throw (Exception);
122          //this type of RUNEvent should be the future develop.
123          //Pass the buffer not the pointer to file
124          //virtual void RunEvent(int, long int, char[]);
125          virtual std::string GetVersionInfo(void) const;
126        };
127    
128    
129    /**********************************************
130    * Event reader algorithm for physics events.
131    **********************************************/
132      class PhysicsReader: public TechmodelAlgorithm {      class PhysicsReader: public TechmodelAlgorithm {
133      private:      private:
134        /** The reader for tracker physics events. */        /** The reader for tracker physics events. */
135        tracker::TrackerReader* trackerReader;        tracker::TrackerReader*           trackerReader;
136        /** The reader for anticoincidence physics events. */        anticounter::AnticounterReader*   anticounterReader;
137        //anticoinc::AnticounterReader* AcReader;        calorimeter::CalorimeterReader*   calorimeterReader;
138        /** The reader for calorimeter physics events. */        neutron::NeutronDetectorReader*   neutronReader;
139        //calorimeter::CalorimeterReader* CalorimeterReader;        S4::S4Reader*                     s4Reader;
140          tof::TofReader*                   tofReader;
141          trigger::TriggerReader*           triggerReader;
142      public:      public:
143        PhysicsReader(void);        PhysicsReader(void);
144        virtual void Init(PamelaRun *);        virtual void Init(PamelaRun *);
145        virtual void RunEvent(int, long int);        virtual void RunEvent(int, long int) throw (Exception);
146        virtual std::string GetVersionInfo(void) const;        virtual std::string GetVersionInfo(void) const;
147      };      };
148    
149      /**  
150       * Event reader algorithm for housekeeping events.  /**********************************************
151       */  * Event reader algorithm for CalibTrkBoth events.
152      /*  **********************************************/
153      class HousekeepingReader: public TechmodelAlgorithm {      class CalibTrkBothReader: public TechmodelAlgorithm {
154      private:      private:
155          /** The CalibTrkBoth event that is created in the reader. */
156          CalibTrkBothEvent* calibTrkBoth;
157      public:      public:
158        HousekeepingReader(void);        CalibTrkBothReader(void);
159        virtual void Init(PamelaRun *);        virtual void Init(PamelaRun *);
160        virtual void RunEvent(int);        virtual void RunEvent(int, long int) throw (Exception);
161        virtual string GetVersionInfo(void) const;        //this type of RUNEvent should be the future develop.
162          //Pass the buffer not the pointer to file
163          //virtual void RunEvent(int, long int, char[]);
164          virtual std::string GetVersionInfo(void) const;
165      };      };
     */  
166    
167    
168      /**  /**********************************************
169       * Event reader algorithm for TMTC events.  * Event reader algorithm for CalibTrk1 events.
170       */  **********************************************/
171      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;  
172      private:      private:
173        /** The TMTC event that is created in the reader. */        /** The CalibTrk1 event that is created in the reader. */
174        TmtcEvent* Tmtc;        CalibTrk1Event* calibTrk1;
       float convert_th(int);  
175      public:      public:
176      TmtcReader(void);        CalibTrk1Reader(void);
177      virtual void Init(PamelaRun *);        virtual void Init(PamelaRun *);
178      virtual void RunEvent(int, long int);        virtual void RunEvent(int, long int) throw (Exception);
179      virtual string GetVersionInfo(void) const;        //this type of RUNEvent should be the future develop.
180          //Pass the buffer not the pointer to file
181          //virtual void RunEvent(int, long int, char[]);
182          virtual std::string GetVersionInfo(void) const;
183      };      };
184    
185    
186      /**  /**********************************************
187       * Event reader algorithm for PSCU events.  * Event reader algorithm for CalibTrk2 events.
188       */  **********************************************/
189      class PscuReader: public TechmodelAlgorithm {      class CalibTrk2Reader: public TechmodelAlgorithm {
190      private:      private:
191        /** The PSCU event that is created in the reader. */        /** The CalibTrk2 event that is created in the reader. */
192        PscuEvent* Pscu;        CalibTrk2Event* calibTrk2;
193      public:      public:
194        PscuReader(void);        CalibTrk2Reader(void);
195          virtual void Init(PamelaRun *);
196          virtual void RunEvent(int, long int) throw (Exception);
197          virtual std::string GetVersionInfo(void) const;
198        };
199    
200    
201    /**********************************************
202    * Event reader algorithm for CalibTrd events.
203    **********************************************/
204        class CalibTrdReader: public TechmodelAlgorithm {
205        private:
206          /** The CalibTrd event that is created in the reader. */
207          CalibTrdEvent* calibTrd;
208        public:
209          CalibTrdReader(void);
210          virtual void Init(PamelaRun *);
211          virtual void RunEvent(int, long int) throw (Exception);
212          virtual std::string GetVersionInfo(void) const;
213        };
214    
215    
216    /**********************************************
217    * Event reader algorithm for CalibTof events.
218    **********************************************/
219        class CalibTofReader: public TechmodelAlgorithm {
220        private:
221          /** The CalibTof event that is created in the reader. */
222          CalibTofEvent* CalibTof;
223        public:
224          CalibTofReader(void);
225          virtual void Init(PamelaRun *);
226          virtual void RunEvent(int, long int) throw (Exception);
227          virtual std::string GetVersionInfo(void) const;
228        };
229    
230    
231    /**********************************************
232    * Event reader algorithm for CalibS4 events.
233    **********************************************/
234        class CalibS4Reader: public TechmodelAlgorithm {
235        private:
236          /** The CalibCal event that is created in the reader. */
237          CalibS4Event* calibS4;
238        public:
239          CalibS4Reader(void);
240          virtual void Init(PamelaRun *);
241          virtual void RunEvent(int, long int) throw (WrongCRCException);
242          virtual std::string GetVersionInfo(void) const;
243        };
244    
245    
246    /**********************************************
247    * Event reader algorithm for CalibCalPed events.
248    **********************************************/
249        class CalibCalPedReader: public TechmodelAlgorithm {
250        private:
251          /** The CalibCalPed event that is created in the reader. */
252          CalibCalPedEvent* calibCalPed;
253        public:
254          CalibCalPedReader(void);
255          virtual void Init(PamelaRun *);
256          virtual void RunEvent(int, long int) throw (Exception);
257          virtual std::string GetVersionInfo(void) const;
258        };
259    
260    
261    /***********************************************
262    * Event reader algorithm for Calib1_Ac1 events.
263    **********************************************/
264        class Calib1_Ac1Reader: public TechmodelAlgorithm {
265        private:
266          /** The CalibAc event that is created in the reader. */
267          Calib1_Ac1Event* calib1_Ac1;
268        public:
269          Calib1_Ac1Reader(void);
270          virtual void Init(PamelaRun *);
271          virtual void RunEvent(int, long int) throw (Exception);
272          virtual std::string GetVersionInfo(void) const;
273        };
274    
275    
276    /***********************************************
277    * Event reader algorithm for Calib1_Ac2 events.
278    **********************************************/
279        class Calib1_Ac2Reader: public TechmodelAlgorithm {
280        private:
281          /** The Calib1_Ac2 event that is created in the reader. */
282          Calib1_Ac2Event* calib1_Ac2;
283        public:
284          Calib1_Ac2Reader(void);
285        virtual void Init(PamelaRun *);        virtual void Init(PamelaRun *);
286        virtual void RunEvent(int, long int);        virtual void RunEvent(int, long int) throw (Exception);
287        virtual std::string GetVersionInfo(void) const;        virtual std::string GetVersionInfo(void) const;
288      };      };
289    
290      /**  /***********************************************
291       * Event reader algorithm for VarDump events.  * Event reader algorithm for Calib2_Ac1 events.
292       */  **********************************************/
293        class Calib2_Ac1Reader: public TechmodelAlgorithm {
294        private:
295          /** The Calib2_Ac1 event that is created in the reader. */
296          Calib2_Ac1Event* calib2_Ac1;
297        public:
298          Calib2_Ac1Reader(void);
299          virtual void Init(PamelaRun *);
300          virtual void RunEvent(int, long int) throw (Exception);
301          virtual std::string GetVersionInfo(void) const;
302        };
303    
304    /***********************************************
305    * Event reader algorithm for Calib2_Ac2 events.
306    **********************************************/
307        class Calib2_Ac2Reader: public TechmodelAlgorithm {
308        private:
309          /** The Calib2_Ac2 event that is created in the reader. */
310          Calib2_Ac2Event* calib2_Ac2;
311        public:
312          Calib2_Ac2Reader(void);
313          virtual void Init(PamelaRun *);
314          virtual void RunEvent(int, long int) throw (Exception);
315          virtual std::string GetVersionInfo(void) const;
316        };
317    
318    
319    /**********************************************
320    * Event reader algorithm for RunHeader events.
321    **********************************************/
322        class RunHeaderReader: public TechmodelAlgorithm {
323        private:
324          /** The RunHeader event that is created in the reader. */
325          RunHeaderEvent* RunHeader;
326        public:
327          RunHeaderReader(void);
328          virtual void Init(PamelaRun *);
329          virtual void RunEvent(int, long int) throw (WrongCRCException);
330          virtual std::string GetVersionInfo(void) const;
331        };
332    
333    
334    /**********************************************
335    * Event reader algorithm for RunTrailer events.
336    **********************************************/
337        class RunTrailerReader: public TechmodelAlgorithm {
338        private:
339          /** The RunTrailer event that is created in the reader. */
340          RunTrailerEvent* RunTrailer;
341        public:
342          RunTrailerReader(void);
343          virtual void Init(PamelaRun *);
344          virtual void RunEvent(int, long int) throw (WrongCRCException);
345          virtual std::string GetVersionInfo(void) const;
346        };
347    
348    
349    /**********************************************
350    * Event reader algorithm for CalibHeader events.
351    **********************************************/
352        class CalibHeaderReader: public TechmodelAlgorithm {
353        private:
354          /** The CalibHeader event that is created in the reader. */
355          CalibHeaderEvent* calibHeader;
356        public:
357          CalibHeaderReader(void);
358          virtual void Init(PamelaRun *);
359          virtual void RunEvent(int, long int) throw (WrongCRCException);
360          virtual std::string GetVersionInfo(void) const;
361        };
362    
363    
364    /**********************************************
365    * Event reader algorithm for CalibTrailer events.
366    **********************************************/
367        class CalibTrailerReader: public TechmodelAlgorithm {
368        private:
369          /** The CalibTrailer event that is created in the reader. */
370          CalibTrailerEvent* calibTrailer;
371        public:
372          CalibTrailerReader(void);
373          virtual void Init(PamelaRun *);
374          virtual void RunEvent(int, long int) throw (WrongCRCException);
375          virtual std::string GetVersionInfo(void) const;
376        };
377    
378    
379    /**********************************************
380    * Event reader algorithm for InitHeader events.
381    **********************************************/
382        class InitHeaderReader: public TechmodelAlgorithm {
383        private:
384          /** The InitHeader event that is created in the reader. */
385          InitHeaderEvent* initHeader;
386        public:
387          InitHeaderReader(void);
388          virtual void Init(PamelaRun *);
389          virtual void RunEvent(int, long int) throw (WrongCRCException);
390          virtual std::string GetVersionInfo(void) const;
391        };
392    
393    
394    /**********************************************
395    * Event reader algorithm for InitTrailer events.
396    **********************************************/
397        class InitTrailerReader: public TechmodelAlgorithm {
398        private:
399          /** The InitTrailer event that is created in the reader. */
400          InitTrailerEvent* initTrailer;
401        public:
402          InitTrailerReader(void);
403          virtual void Init(PamelaRun *);
404          virtual void RunEvent(int, long int) throw (WrongCRCException);
405          virtual std::string GetVersionInfo(void) const;
406        };
407    
408    
409    /**********************************************
410    * Event reader algorithm for EventTrk events.
411    **********************************************/
412        class EventTrkReader: public TechmodelAlgorithm {
413        private:
414          /** The EventTrk event that is created in the reader. */
415          EventTrkEvent* eventTrk;
416        public:
417          EventTrkReader(void);
418          virtual void Init(PamelaRun *);
419          virtual void RunEvent(int, long int) throw (Exception);
420          virtual std::string GetVersionInfo(void) const;
421        };
422    
423    
424    /**********************************************
425    * Event reader algorithm for TestTrk events.
426    **********************************************/
427        class TestTrkReader: public TechmodelAlgorithm {
428        private:
429          /** The TestTrk event that is created in the reader. */
430          TestTrkEvent* testTrk;
431        public:
432          TestTrkReader(void);
433          virtual void Init(PamelaRun *);
434          virtual void RunEvent(int, long int) throw (Exception);
435          virtual std::string GetVersionInfo(void) const;
436        };
437    
438    /**********************************************
439    * Event reader algorithm for TestTof events.
440    **********************************************/
441        class TestTofReader: public TechmodelAlgorithm {
442        private:
443          /** The TestTof event that is created in the reader. */
444          TestTofEvent* testTof;
445        public:
446          TestTofReader(void);
447          virtual void Init(PamelaRun *);
448          virtual void RunEvent(int, long int) throw (Exception);
449          virtual std::string GetVersionInfo(void) const;
450        };
451    
452    /**********************************************
453    * Event reader algorithm for Log events.
454    **********************************************/
455        class LogReader: public TechmodelAlgorithm {
456        private:
457          /** The Log event that is created in the reader. */
458          LogEvent* Log;
459        public:
460          LogReader(void);
461          virtual void Init(PamelaRun *);
462          virtual void RunEvent(int, long int) throw (WrongCRCException);
463          virtual std::string GetVersionInfo(void) const;
464        };
465    
466    
467    /***********************************************
468    * Event reader algorithm for VarDump events.
469    **********************************************/
470      class VarDumpReader: public TechmodelAlgorithm {      class VarDumpReader: public TechmodelAlgorithm {
471      private:      private:
472        /** The VarDump event that is created in the reader. */        /** The VarDump event that is created in the reader. */
# Line 118  namespace pamela { Line 474  namespace pamela {
474      public:      public:
475        VarDumpReader(void);        VarDumpReader(void);
476        virtual void Init(PamelaRun *);        virtual void Init(PamelaRun *);
477        virtual void RunEvent(int, long int);        virtual void RunEvent(int, long int) throw (WrongCRCException);
478        virtual std::string GetVersionInfo(void) const;        virtual std::string GetVersionInfo(void) const;
479      };      };
480    
481      /**  
482       * Event reader algorithm for ArrDump events.  /**********************************************
483       */  * Event reader algorithm for ArrDump events.
484    **********************************************/
485      class ArrDumpReader: public TechmodelAlgorithm {      class ArrDumpReader: public TechmodelAlgorithm {
486      private:      private:
487        /** The ArrDump event that is created in the reader. */        /** The ArrDump event that is created in the reader. */
# Line 132  namespace pamela { Line 489  namespace pamela {
489      public:      public:
490        ArrDumpReader(void);        ArrDumpReader(void);
491        virtual void Init(PamelaRun *);        virtual void Init(PamelaRun *);
492        virtual void RunEvent(int, long int);        virtual void RunEvent(int, long int) throw (WrongCRCException);
493        virtual std::string GetVersionInfo(void) const;        virtual std::string GetVersionInfo(void) const;
494      };      };
495    
496      /**  
497       * Event reader algorithm for TabDump events.  /**********************************************
498       */  * Event reader algorithm for TabDump events.
499    **********************************************/
500      class TabDumpReader: public TechmodelAlgorithm {      class TabDumpReader: public TechmodelAlgorithm {
501      private:      private:
502        /** The TabDump event that is created in the reader. */        /** The TabDump event that is created in the reader. */
# Line 146  namespace pamela { Line 504  namespace pamela {
504      public:      public:
505        TabDumpReader(void);        TabDumpReader(void);
506        virtual void Init(PamelaRun *);        virtual void Init(PamelaRun *);
507        virtual void RunEvent(int, long int);        virtual void RunEvent(int, long int) throw (WrongCRCException);
508        virtual std::string GetVersionInfo(void) const;        virtual std::string GetVersionInfo(void) const;
509      };      };
510    
511      /**  
512       * Event reader algorithm for Mcmd events.  /**********************************************
513       */  * Event reader algorithm for TMTC events.
514    **********************************************/
515        class TmtcReader: public TechmodelAlgorithm {
516        //Length in bytes of the subPacket (that is te TmtcRecord excluded subCRC)
517        static const int TMTC_SUB_LENGTH = 36;
518        //Length in bytes of the subPacketCRC
519        static const int TMTC_SUBCRC_LENGTH = 1;
520        //Length in bytes of the PacketCRC
521        static const int TMTC_CRC_LENGTH = 2;
522        private:
523          /** The TMTC event that is created in the reader. */
524          TmtcEvent* Tmtc;
525          //float convert_th(int);
526        public:
527        TmtcReader(void);
528        virtual void Init(PamelaRun *);
529        virtual void RunEvent(int, long int) throw (WrongCRCException);
530        virtual string GetVersionInfo(void) const;
531        };
532    
533    
534    /**********************************************
535    * Event reader algorithm for Mcmd events.
536    **********************************************/
537      class McmdReader: public TechmodelAlgorithm {      class McmdReader: public TechmodelAlgorithm {
538      private:      private:
539        /** The Mcmd event that is created in the reader. */        /** The Mcmd event that is created in the reader. */
# Line 160  namespace pamela { Line 541  namespace pamela {
541      public:      public:
542        McmdReader(void);        McmdReader(void);
543        virtual void Init(PamelaRun *);        virtual void Init(PamelaRun *);
544        virtual void RunEvent(int, long int);        virtual void RunEvent(int, long int) throw (WrongCRCException);
545        virtual std::string GetVersionInfo(void) const;        virtual std::string GetVersionInfo(void) const;
546      };      };
547    
548  /**  
549       * Event reader algorithm for Log events.  /**********************************************
550       */  * Event reader algorithm for ForcedFECmd events.
551      class LogReader: public TechmodelAlgorithm {  **********************************************/
552        class ForcedFECmdReader: public TechmodelAlgorithm {
553      private:      private:
554        /** The Log event that is created in the reader. */        /** The ForcedFECmd event that is created in the reader. */
555        LogEvent* Log;        ForcedFECmdEvent* forcedFECmd;
556      public:      public:
557        LogReader(void);        ForcedFECmdReader(void);
558        virtual void Init(PamelaRun *);        virtual void Init(PamelaRun *);
559        virtual void RunEvent(int, long int);        virtual void RunEvent(int, long int) throw (WrongCRCException);
560        virtual std::string GetVersionInfo(void) const;        virtual std::string GetVersionInfo(void) const;
561      };      };
562    
563  /**  
564       * Event reader algorithm for CalibCal events.  /**********************************************
565       */  * Event reader algorithm for Ac1Init events.
566      class CalibCalReader: public TechmodelAlgorithm {  **********************************************/
567        class Ac1InitReader: public TechmodelAlgorithm {
568      private:      private:
569        /** The CalibCal event that is created in the reader. */        /** The Ac1Init event that is created in the reader. */
570        CalibCalEvent* CalibCal;        Ac1InitEvent* ac1Init;
571      public:      public:
572        CalibCalReader(void);        Ac1InitReader(void);
573        virtual void Init(PamelaRun *);        virtual void Init(PamelaRun *);
574        virtual void RunEvent(int, long int);        virtual void RunEvent(int, long int) throw (WrongCRCException);
575        virtual std::string GetVersionInfo(void) const;        virtual std::string GetVersionInfo(void) const;
576      };      };
577    
578  /**  
579       * Event reader algorithm for CalibTrk events.  /**********************************************
580       */  * Event reader algorithm for CalInit events.
581      class CalibTrkReader: public TechmodelAlgorithm {  **********************************************/
582        class CalInitReader: public TechmodelAlgorithm {
583      private:      private:
584        /** The CalibTrk event that is created in the reader. */        /** The CalInit event that is created in the reader. */
585        CalibTrkEvent* calibTrk;        CalInitEvent* calInit;
586      public:      public:
587        CalibTrkReader(void);        CalInitReader(void);
588        virtual void Init(PamelaRun *);        virtual void Init(PamelaRun *);
589        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[]);  
590        virtual std::string GetVersionInfo(void) const;        virtual std::string GetVersionInfo(void) const;
591      };      };
592    
593  /**  
594       * Event reader algorithm for CalibTrg events.  /**********************************************
595       */  * Event reader algorithm for TrkInit events.
596      class CalibTrgReader: public TechmodelAlgorithm {  **********************************************/
597        class TrkInitReader: public TechmodelAlgorithm {
598      private:      private:
599        /** The CalibTrg event that is created in the reader. */        /** The TrkInit event that is created in the reader. */
600        CalibTrgEvent* calibTrg;        TrkInitEvent* trkInit;
601      public:      public:
602        CalibTrgReader(void);        TrkInitReader(void);
603        virtual void Init(PamelaRun *);        virtual void Init(PamelaRun *);
604        virtual void RunEvent(int, long int);        virtual void RunEvent(int, long int) throw (WrongCRCException);
605        virtual std::string GetVersionInfo(void) const;        virtual std::string GetVersionInfo(void) const;
606      };      };
607    
608  /**  
609       * Event reader algorithm for CalibTrd events.  /**********************************************
610       */  * Event reader algorithm for TofInit events.
611      class CalibTrdReader: public TechmodelAlgorithm {  **********************************************/
612        class TofInitReader: public TechmodelAlgorithm {
613      private:      private:
614        /** The CalibTrd event that is created in the reader. */        /** The TofInit event that is created in the reader. */
615        CalibTrdEvent* CalibTrd;        TofInitEvent* tofInit;
616      public:      public:
617        CalibTrdReader(void);        TofInitReader(void);
618        virtual void Init(PamelaRun *);        virtual void Init(PamelaRun *);
619        virtual void RunEvent(int, long int);        virtual void RunEvent(int, long int) throw (WrongCRCException);
620        virtual std::string GetVersionInfo(void) const;        virtual std::string GetVersionInfo(void) const;
621      };      };
622    
623  /**  
624       * Event reader algorithm for CalibTof events.  /**********************************************
625       */  * Event reader algorithm for TrgInit events.
626      class CalibTofReader: public TechmodelAlgorithm {  **********************************************/
627        class TrgInitReader: public TechmodelAlgorithm {
628      private:      private:
629        /** The CalibTof event that is created in the reader. */        /** The TrgInit event that is created in the reader. */
630        CalibTofEvent* CalibTof;        TrgInitEvent* trgInit;
631      public:      public:
632        CalibTofReader(void);        TrgInitReader(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 CalibS4 events.  * Event reader algorithm for NdInit events.
640       */  **********************************************/
641      class CalibS4Reader: public TechmodelAlgorithm {      class NdInitReader: public TechmodelAlgorithm {
642      private:      private:
643        /** The CalibCal event that is created in the reader. */        /** The NdInit event that is created in the reader. */
644        CalibS4Event* CalibS4;        NdInitEvent* ndInit;
645      public:      public:
646        CalibS4Reader(void);        NdInitReader(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 S4Init events.
654    **********************************************/
655        class S4InitReader: public TechmodelAlgorithm {
656        private:
657          /** The S4Init event that is created in the reader. */
658          S4InitEvent* s4Init;
659        public:
660          S4InitReader(void);
661          virtual void Init(PamelaRun *);
662          virtual void RunEvent(int, long int) throw (WrongCRCException);
663          virtual std::string GetVersionInfo(void) const;
664        };
665    
666  /**  
667       * Event reader algorithm for RunTrailer events.  /**********************************************
668       */  * Event reader algorithm for Ac2Init events.
669      class RunTrailerReader: public TechmodelAlgorithm {  **********************************************/
670        class Ac2InitReader: public TechmodelAlgorithm {
671      private:      private:
672        /** The RunTrailer event that is created in the reader. */        /** The Ac2Init event that is created in the reader. */
673        RunTrailerEvent* RunTrailer;        Ac2InitEvent* ac2Init;
674      public:      public:
675        RunTrailerReader(void);        Ac2InitReader(void);
676        virtual void Init(PamelaRun *);        virtual void Init(PamelaRun *);
677        virtual void RunEvent(int, long int);        virtual void RunEvent(int, long int) throw (WrongCRCException);
678        virtual std::string GetVersionInfo(void) const;        virtual std::string GetVersionInfo(void) const;
679      };      };
680    
681  /**  
682       * Event reader algorithm for RunHeader events.  /**********************************************
683       */  * Event reader algorithm for CalAlarm events.
684      class RunHeaderReader: public TechmodelAlgorithm {  **********************************************/
685        class CalAlarmReader: public TechmodelAlgorithm {
686      private:      private:
687        /** The RunHeader event that is created in the reader. */        /** The CalAlarm event that is created in the reader. */
688        RunHeaderEvent* RunHeader;        CalAlarmEvent* calAlarm;
689      public:      public:
690        RunHeaderReader(void);        CalAlarmReader(void);
691          virtual void Init(PamelaRun *);
692          virtual void RunEvent(int, long int) throw (WrongCRCException);
693          virtual std::string GetVersionInfo(void) const;
694        };
695    
696    /**********************************************
697    * Event reader algorithm for AcAlarm events.
698    **********************************************/
699        class AcAlarmReader: public TechmodelAlgorithm {
700        private:
701          /** The AcAlarm event that is created in the reader. */
702          AcAlarmEvent* acAlarm;
703        public:
704          AcAlarmReader(void);
705          virtual void Init(PamelaRun *);
706          virtual void RunEvent(int, long int) throw (WrongCRCException);
707          virtual std::string GetVersionInfo(void) const;
708        };
709    
710    /**********************************************
711    * Event reader algorithm for TrkAlarm events.
712    **********************************************/
713        class TrkAlarmReader: public TechmodelAlgorithm {
714        private:
715          /** The TrkAlarm event that is created in the reader. */
716          TrkAlarmEvent* trkAlarm;
717        public:
718          TrkAlarmReader(void);
719          virtual void Init(PamelaRun *);
720          virtual void RunEvent(int, long int) throw (WrongCRCException);
721          virtual std::string GetVersionInfo(void) const;
722        };
723    
724    /**********************************************
725    * Event reader algorithm for TrgAlarm events.
726    **********************************************/
727        class TrgAlarmReader: public TechmodelAlgorithm {
728        private:
729          /** The TrgAlarm event that is created in the reader. */
730          TrgAlarmEvent* trgAlarm;
731        public:
732          TrgAlarmReader(void);
733          virtual void Init(PamelaRun *);
734          virtual void RunEvent(int, long int) throw (WrongCRCException);
735          virtual std::string GetVersionInfo(void) const;
736        };
737    
738    /**********************************************
739    * Event reader algorithm for TofAlarm events.
740    **********************************************/
741        class TofAlarmReader: public TechmodelAlgorithm {
742        private:
743          /** The TofAlarm event that is created in the reader. */
744          TofAlarmEvent* tofAlarm;
745        public:
746          TofAlarmReader(void);
747          virtual void Init(PamelaRun *);
748          virtual void RunEvent(int, long int) throw (WrongCRCException);
749          virtual std::string GetVersionInfo(void) const;
750        };
751    
752    /**********************************************
753    * Event reader algorithm for S4Alarm events.
754    **********************************************/
755        class S4AlarmReader: public TechmodelAlgorithm {
756        private:
757          /** The S4Alarm event that is created in the reader. */
758          S4AlarmEvent* s4Alarm;
759        public:
760          S4AlarmReader(void);
761        virtual void Init(PamelaRun *);        virtual void Init(PamelaRun *);
762        virtual void RunEvent(int, long int);        virtual void RunEvent(int, long int) throw (WrongCRCException);
763        virtual std::string GetVersionInfo(void) const;        virtual std::string GetVersionInfo(void) const;
764      };      };
765    
766  /**  /**********************************************
767       * Event reader algorithm for ForcedPkt events.  * Event reader algorithm for TsbT events.
768       */  **********************************************/
769      class ForcedPktReader: public TechmodelAlgorithm {      class TsbTReader: public TechmodelAlgorithm {
770      private:      private:
771        /** The ForcedPkt event that is created in the reader. */        /** The TsbT event that is created in the reader. */
772        ForcedPktEvent* ForcedPkt;        TsbTEvent* TsbT;
773      public:      public:
774        ForcedPktReader(void);        TsbTReader(void);
775        virtual void Init(PamelaRun *);        virtual void Init(PamelaRun *);
776        virtual void RunEvent(int, long int);        virtual void RunEvent(int, long int) throw (WrongCRCException);
777        virtual std::string GetVersionInfo(void) const;        virtual std::string GetVersionInfo(void) const;
778      };      };
779    
780    /**********************************************
781    * Event reader algorithm for TsbB events.
782    **********************************************/
783        class TsbBReader: public TechmodelAlgorithm {
784        private:
785          /** The TsbB event that is created in the reader. */
786          TsbBEvent* TsbB;
787        public:
788          TsbBReader(void);
789          virtual void Init(PamelaRun *);
790          virtual void RunEvent(int, long int) throw (WrongCRCException);
791          virtual std::string GetVersionInfo(void) const;
792        };
793    
794    /**********************************************
795    * Event reader algorithm for PSCU events.
796    **********************************************/
797        class PscuReader: public TechmodelAlgorithm {
798        private:
799          /** The PSCU event that is created in the reader. */
800          PscuEvent* Pscu;
801        public:
802          PscuReader(void);
803          virtual void Init(PamelaRun *);
804          virtual void RunEvent(int, long int) throw (WrongCRCException);
805          virtual std::string GetVersionInfo(void) const;
806        };
807    
808    
809    }    }
810  }  }
811    
812  #endif /* READER_ALGORITHM_H */  #endif /* READER_ALGORITHM_H */
813    
814    
815    
816    

Legend:
Removed from v.1.1  
changed lines
  Added in v.2.9

  ViewVC Help
Powered by ViewVC 1.1.23