CMS 3D CMS Logo

DQMEventMessage.h

Go to the documentation of this file.
00001 #ifndef IOPool_Streamer_DQMEventMessage_h
00002 #define IOPool_Streamer_DQMEventMessage_h
00003 
00037 #include "IOPool/Streamer/interface/MsgTools.h"
00038 #include "IOPool/Streamer/interface/MsgHeader.h"
00039 #include "boost/shared_ptr.hpp"
00040 #include <TObject.h>
00041 #include <map>
00042 
00043 #include "DataFormats/Provenance/interface/Timestamp.h"
00044 
00045 
00046 // ------------------ dqm event message ----------------
00047 
00048 namespace DQMEvent
00049 {
00050   typedef std::map< std::string, std::vector<TObject *> >
00051       TObjectTable;
00052 }
00053 
00054 struct DQMEventHeader
00055 {
00056   Header header_;
00057   char_uint32 protocolVersion_;
00058   char_uint32 headerSize_;
00059   char_uint32 runNumber_;
00060   char_uint32 eventNumber_;
00061   char_uint64 timeStamp_;
00062   char_uint32 lumiSection_;
00063   char_uint32 updateNumber_;
00064   char_uint32 compressionFlag_;
00065   char_uint32 fuProcessId_;
00066   char_uint32 fuGuid_;
00067   char_uint32 reserved_;
00068 };
00069 
00070 class DQMEventMsgView
00071 {
00072  public:
00073   DQMEventMsgView(void* buf);
00074 
00075   uint32 code() const { return head_.code(); }
00076   uint32 size() const { return head_.size(); }
00077 
00078   uint8* startAddress() const { return buf_; }
00079   uint8* eventAddress() const { return eventAddr_; }
00080   uint32 eventLength() const { return eventLen_; }
00081 
00082   uint32 protocolVersion() const;
00083   uint32 headerSize() const;
00084   uint32 runNumber() const;
00085   uint32 eventNumberAtUpdate() const;
00086   uint32 lumiSection() const;
00087   uint32 updateNumber() const;
00088   uint32 compressionFlag() const;
00089   uint32 fuProcessId() const;
00090   uint32 fuGuid() const;
00091   uint32 reserved() const;
00092 
00093   edm::Timestamp timeStamp() const;
00094 
00095   std::string releaseTag() const { return releaseTag_; }
00096   std::string topFolderName() const { return folderName_; }
00097 
00098   uint32 subFolderCount() const { return subFolderCount_; }
00099   boost::shared_ptr< std::vector<std::string> > subFolderNames() const;
00100 
00101   std::string subFolderName(uint32 const subFolderIndex) const;
00102   uint32 meCount(std::string const& subFolderName) const;
00103   uint32 meCount(uint32 const subFolderIndex) const;
00104 
00105  private:
00106   uint8* buf_;
00107   HeaderView head_;
00108   std::string releaseTag_;
00109   std::string folderName_;
00110   uint8* eventAddr_;
00111   uint32 eventLen_;
00112   uint32 subFolderCount_;
00113   std::map<std::string, uint32> subFolderIndexTable_;
00114   boost::shared_ptr< std::vector<std::string> > nameListPtr_;
00115   std::vector<uint32> meCountList_;
00116 };
00117 
00118 #endif

Generated on Tue Jun 9 17:39:16 2009 for CMSSW by  doxygen 1.5.4