00001 #ifndef PXXHitPayload__H__ 00002 #define PXXHitPayload__H__ 00003 00010 00011 #include "payloads-unpacker/payloads/PXXVTriggerPayload.h" 00012 #include "payloads-unpacker/payloads/PXXIHitPayload.h" 00013 #include "payloads-unpacker/payloads/PXXDOMID8B.h" 00014 #include "payloads-unpacker/payloads/PXXSourceID4B.h" 00015 00016 class PXXHitPayload : public PXXVTriggerPayload, public PXXIHitPayload 00017 { 00018 public: 00019 00020 SET_LOGGER("PXXHitPayload"); 00021 00025 PXXHitPayload(const PXXPayloadEnvelope &envelope); 00026 //------------------------------------------------------------------------------ 00027 00031 PXXHitPayload(); 00032 //------------------------------------------------------------------------------ 00033 00037 virtual ~PXXHitPayload(); 00038 //------------------------------------------------------------------------------ 00039 00043 virtual Int32b_t GetTriggerType() const; 00044 //------------------------------------------------------------------------------ 00045 00049 virtual Int32b_t GetTriggerConfigID() const; 00050 //------------------------------------------------------------------------------ 00051 00056 virtual const PXXISourceID& GetSourceID(); 00057 //------------------------------------------------------------------------------ 00058 00062 virtual const PXXIDOMID &GetDOMID(); 00063 //------------------------------------------------------------------------------ 00064 00068 virtual Double64b_t GetIntegratedCharge() const { return -1.0; } 00069 //------------------------------------------------------------------------------ 00070 00074 virtual const PXXIUTCTime &GetHitTimeUTC() { return GetPayloadTimeUTC(); } 00075 //------------------------------------------------------------------------------ 00076 00080 virtual Short16b_t GetTriggerMode() const; 00081 //------------------------------------------------------------------------------ 00082 00083 00087 virtual void WriteProperties(); 00088 //------------------------------------------------------------------------------ 00089 00090 private: 00091 00103 virtual Int32b_t ReadData(); 00104 //------------------------------------------------------------------------------ 00105 00106 00107 private: 00108 00109 Int32b_t fITriggerType_; // type of the trigger 00110 Int32b_t fITriggerConfigID_; // ID of the trigger 00111 PXXSourceID4B fTSourceID_; // ID of the Source 00112 PXXDOMID8B fTDOMID_; // dom ID 00113 Short16b_t fSTriggerMode_; // 00114 Double64b_t fDIntegratedCharge_; // Integrated Charge 00115 00116 ClassDef(PXXHitPayload, 0) // interface to HitPayload 00117 00118 }; 00119 00120 #ifdef __USEROOT__ // compile with ROOT 00121 typedef PXXHitPayload* PXXHitPayloadPtr; 00122 #else // compile with IceTray 00123 typedef shared_ptr<PXXHitPayload> PXXHitPayloadPtr; 00124 #endif 00125 00126 #endif // PXXHitPayload_H