/search.css" rel="stylesheet" type="text/css"/> /search.js">
00001 #ifndef LTBREADOUTFORMAT_LTBFRAME_H 00002 #define LTBREADOUTFORMAT_LTBFRAME_H 00003 00012 #include "LtbReadoutFormat/LtbBuffer.h" 00013 #include "LtbReadoutFormat/LtbTraits.h" 00014 00015 namespace DybDaq { 00016 class LtbBuffer; 00017 class LtbReadout; 00018 class LtbTime; 00019 } 00020 00021 namespace DybDaq { 00022 00023 class LtbFrame : public LtbBuffer { 00024 00025 public: 00026 00027 friend class LtbReadout; 00028 00032 LtbFrame(const unsigned int readoutType, 00033 const unsigned int triggerMask, 00034 const LtbTraits::LtbDateTime& dateTime, 00035 const unsigned int halfNanoseconds, 00036 const int accumulation, 00037 const unsigned int hitSum, 00038 const bool totalEsum, 00039 const bool highEsum, 00040 const bool lowEsum, 00041 const unsigned int energySum, 00042 const unsigned int crossTriggerSource, 00043 const bool accumulationStatus, 00044 const bool validGps, 00045 const bool usingUtc, 00046 const bool validClockSystem, 00047 const bool feeBufferFull, 00048 const bool ltbBufferFull, 00049 const unsigned int blockedTriggerCount, 00050 const LtbTraits& traits); 00051 00055 virtual ~LtbFrame(); 00056 00060 unsigned int frameNumber() const; 00061 00065 unsigned int readoutType() const; 00066 00070 unsigned int triggerMask() const; 00071 00075 bool isTriggerLineSet(const unsigned int line) const; 00076 00080 const LtbTraits::LtbDateTime& dateTime() const; 00081 00085 unsigned int ticks() const; 00086 00090 unsigned int halfNanoseconds() const; 00091 00095 int accumulation() const; 00096 00100 unsigned int hitSum() const; 00101 00105 bool totalEsum() const; 00106 00110 bool highEsum() const; 00111 00115 bool lowEsum() const; 00116 00120 unsigned int energySum() const; 00121 00125 unsigned int crossTriggerSource() const; 00126 00130 bool accumulationStatus() const; 00131 00135 bool validGps() const; 00136 00140 bool usingUtc() const; 00141 00145 bool validClockSystem() const; 00146 00150 bool feeBufferFull() const; 00151 00155 bool ltbBufferFull() const; 00156 00160 unsigned int blockedTriggerCount() const; 00161 00165 virtual unsigned int bufferSize() const; 00166 00171 virtual unsigned int gather(OutputBufferList& outputBuffers) const; 00172 00177 virtual unsigned int inspect(DaqBuffer::Bytes& inspectors) const; 00178 00182 void setTriggerLine(const unsigned int line); 00183 00184 protected: 00185 00189 LtbFrame(const ByteBuffer& byteBuffer, 00190 const LtbTraits& traits); 00191 00192 private: 00193 00197 LtbFrame(); 00198 00202 LtbFrame(LtbFrame& rhs); 00203 00207 LtbFrame& operator=(LtbFrame& rhs); 00208 00209 public: 00210 00214 void setFrameNumber(const unsigned int frameNumber); 00215 00219 void setReadoutType(const unsigned int readoutType); 00220 00224 void setTriggerMask(const unsigned int triggerMask); 00225 00229 void setDateTime(const LtbTraits::LtbDateTime& dataTime); 00230 00234 void setHalfNanoseconds(const unsigned int halfNanoseconds); 00235 00239 void setAccumulation(const int accumulation); 00240 00244 void setHitSum(const unsigned int hitSum); 00245 00249 void setTotalEsum(const bool totalEsum); 00250 00254 void setHighEsum(const bool highEsum); 00255 00259 void setLowEsum(const bool lowEsum); 00260 00264 void setEnergySum(const unsigned int energySum); 00265 00269 void setCrossTriggerSource(const unsigned int crossTriggerSource); 00270 00274 void setAccumulationStatus(const bool accumulationStatus); 00275 00279 void setValidGps(const bool validGps); 00280 00284 void setUsingUtc(const bool usingUtc); 00285 00289 void setValidClockSystem(const bool validClockSystem); 00290 00294 void setFeeBufferFull(const bool feeBufferFull); 00295 00299 void setLtbBufferFull(const bool ltbBufferFull); 00300 00304 void setBlockedTriggerCount(const unsigned int blockedTriggerCount); 00305 00309 LtbTime* m_time; 00310 00311 }; 00312 00313 } 00314 00315 #endif // LTBREADOUTFORMAT_LTBFRAME_H