00001 #ifndef RTMREADOUTFORMAT_RTMDATA_H
00002 #define RTMREADOUTFORMAT_RTMDATA_H
00003
00004 #include "RtmReadoutFormat/RtmBuffer.h"
00005
00006
00007 namespace DybDaq{
00008 class RtmReadout;
00009 }
00010
00011
00012 namespace DybDaq {
00013
00014 class RtmData : public RtmBuffer
00015 {
00016
00017 public :
00018
00019 friend class RtmReadout;
00020
00021
00022 virtual ~RtmData();
00023
00024
00025 unsigned int rpcCFId() const;
00026
00027
00028 bool transErr() const;
00029
00030
00031 bool romAlmostFull() const;
00032
00033
00034 bool rtmAlmostFull() const;
00035
00036
00037 bool fullFlag() const;
00038
00039
00040 bool validGPS() const;
00041
00042
00043 bool validCLK() const;
00044
00045
00046 bool usingUTC() const;
00047
00048
00049 unsigned int second() const;
00050
00051
00052 unsigned int nanoSecond() const;
00053
00054
00055 unsigned int accumulation() const;
00056
00057
00058 unsigned int triggerRot() const;
00059
00060
00061 unsigned int triggerMap() const;
00062
00063
00064
00065 virtual unsigned int bufferSize() const;
00066
00067 protected:
00068
00069
00070 virtual unsigned int formatComponent() const;
00071
00072 private :
00073
00074
00075 RtmData(const unsigned int rpcCFId,
00076 const bool transErr,
00077 const bool romAlmostFull,
00078 const bool rtmAlmostFull,
00079 const bool fullFlag,
00080 const bool validGPS,
00081 const bool validCLK,
00082 const bool usingUTC,
00083 const unsigned int second,
00084 const unsigned int nanoSecond,
00085 const unsigned int accumulation,
00086 const unsigned int triggerRot,
00087 const unsigned int triggerMap,
00088 const RtmTraits& traits);
00089
00090 RtmData(const ByteBuffer& byteBuffer,
00091 const RtmTraits& traits);
00092
00093
00094 RtmData();
00095 RtmData(const RtmData&);
00096 RtmData& operator=(const RtmData&);
00097
00098
00099
00100 void setRpcCFId(const unsigned int rpcCFId);
00101
00102 void setTransErr(const bool transErr);
00103
00104 void setRomAlmostFull(const bool romAlmostFull);
00105
00106 void setRtmAlmostFull(const bool rtmAlmostFull);
00107
00108 void setFullFlag(const bool fullFlag);
00109
00110 void setValidGPS(const bool validGPS);
00111
00112 void setValidCLK(const bool validCLK);
00113
00114 void setUsingUTC(const bool usingUTC);
00115
00116 void setSecond(const unsigned int second);
00117
00118 void setNanoSecond(const unsigned int nanoSecond);
00119
00120 void setAccumulation(const unsigned int accumulation);
00121
00122 void setTriggerRot(const unsigned int triggerRot);
00123
00124 void setTriggerMap(const unsigned int triggerMap);
00125
00126 };
00127
00128 }
00129
00130 #endif