/[PAMELA software]/yoda/event/EventCounter.h
ViewVC logotype

Annotation of /yoda/event/EventCounter.h

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.1 - (hide annotations) (download)
Tue Jul 6 12:20:23 2004 UTC (20 years, 4 months ago) by kusanagi
Branch: MAIN
File MIME type: text/plain
Initial revision

1 kusanagi 1.1 /** @file
2     * $Source: /home/cvspamela/yoda/event/EventCounter.h,v $
3     * $Id: EventCounter.h,v 1.7 2004/04/22 15:51:03 nagni Exp $
4     * $Author: nagni $
5     *
6     * Header file for the EventCounter class.
7     */
8     #ifndef EVENTCOUNTER_H
9     #define EVENTCOUNTER_H
10    
11     #include <map>
12     //#include <root/TObject.h>
13     #include <TObject.h> //Substituted by Maurizio 05 Feb 2004
14    
15     #include "PscuHeader.h"
16    
17     namespace pamela {
18     /**
19     * Event counter. Contains the event numbers of the last read event of
20     * each event type.
21     */
22     class EventCounter : public TObject {
23     private:
24     int RunNumber; /**< Run number */
25    
26     // New Packets.
27     int Pscu;
28     int Physics;
29     int Forced_Pkt;
30     int Calib_Trk;
31     int Calib_Trg;
32     int Calib_Cal;
33     int Calib_Trd;
34     int Calib_Tof;
35     int Calib_S4;
36     int Run_Header;
37     int Run_Trailer;
38     int Alarm;
39     int Khb;
40     int Log;
41     int VarDump;
42     int ArrDump;
43     int TabDump;
44     int Tmtc;
45     int Mcmd;
46     int HA_Header_E5;
47    
48     typedef std::map<const pamela::PacketType *, int *> CounterMap;
49     CounterMap CMap; //!
50     public:
51     EventCounter(int = 0);
52     /** Get the run number for the last read event of this type. */
53     int Get(pamela::PacketType const *) const;
54     /** Get the run number for the next event of this type. */
55     int Next(pamela::PacketType const *) const;
56     int GetRunNumber(void) const { return RunNumber; }
57     void Increment(pamela::PacketType const *);
58     void PrintCounters() const ;
59     ClassDef(EventCounter, 1)
60     };
61     }
62    
63     #endif /* EVENTCOUNTER_H */

  ViewVC Help
Powered by ViewVC 1.1.23