Back to home page

sPhenix code displayed by LXR

 
 

    


File indexing completed on 2025-08-05 08:20:28

0001 #ifndef __PKTSIZEMON_H__
0002 #define __PKTSIZEMON_H__
0003 
0004 #include <onlmon/OnlMon.h>
0005 
0006 #include <map>
0007 #include <string>
0008 
0009 class Event;
0010 class Packet;
0011 class TH1;
0012 class PktSizeDBodbc;
0013 
0014 class PktSizeMon : public OnlMon
0015 {
0016  public:
0017   PktSizeMon(const std::string &name = "PKTSIZEMON");
0018   virtual ~PktSizeMon();
0019 
0020   int Init();
0021   int process_event(Event *e);
0022   int Reset();
0023   int EndRun(const int runno);
0024   void Print(const std::string &what = "ALL");
0025   int UpdateDB(const int runno = 0);
0026   //  virtual void Verbosity(const int i);
0027 
0028  protected:
0029   int putmapinhisto();
0030   int nevnts;
0031   TH1 *sizehist = nullptr;
0032   Packet *plist[10000]{};
0033   PktSizeDBodbc *db;
0034   std::map<unsigned int, unsigned int> packetsize;
0035   std::map<std::string, std::pair<unsigned int, unsigned int> > granulepacketlimits;
0036   std::map<unsigned int, std::string> dcmgroups;
0037   std::map<std::string, unsigned int> dcmgroupsize;
0038   std::map<unsigned int, std::string> fibergroups;
0039   std::map<std::string, unsigned int> fibergroupsize;
0040 };
0041 
0042 #endif /* __PKTSIZEMON_H__ */