#include <ReadoutRpcCrate.h>
Inheritance diagram for DayaBay::ReadoutRpcCrate:
Public Types | |
typedef std::map< DayaBay::FecChannelId, DayaBay::ReadoutRpcChannel > | RpcChannelReadouts |
Map of FEC channel data by channel ID. | |
Public Member Functions | |
ReadoutRpcCrate (const DayaBay::Detector &detector, unsigned int triggerNumber, const TimeStamp &triggerTime, const DayaBay::Trigger::TriggerType_t &triggerType) | |
standard constructor | |
ReadoutRpcCrate (const DayaBay::ReadoutRpcCrate &rhs) | |
copy constructor | |
ReadoutRpcCrate () | |
Default Constructor. | |
virtual | ~ReadoutRpcCrate () |
Default Destructor. | |
ReadoutRpcCrate & | operator= (const DayaBay::ReadoutRpcCrate &rhs) |
assignment operator | |
void | addChannel (const DayaBay::FecChannelId &channelId) |
Adds a channel to this readout. | |
ReadoutRpcChannel & | channel (const DayaBay::FecChannelId &channelId) |
Returns the specified channel from this readout. | |
std::ostream & | fillStream (std::ostream &s) const |
Print the crate data. | |
const RpcChannelReadouts & | channelReadout () const |
Retrieve const The set of channels in this readout. | |
void | setChannelReadout (const RpcChannelReadouts &value) |
Update The set of channels in this readout. | |
const DayaBay::Detector & | detector () const |
Retrieve const The detector associated with this readout. | |
void | setDetector (const DayaBay::Detector &value) |
Update The detector associated with this readout. | |
unsigned int | triggerNumber () const |
Retrieve const The count of the trigger command from this detector. | |
void | setTriggerNumber (unsigned int value) |
Update The count of the trigger command from this detector. | |
const TimeStamp & | triggerTime () const |
Retrieve const The absolute time of the trigger command. | |
void | setTriggerTime (const TimeStamp &value) |
Update The absolute time of the trigger command. | |
const DayaBay::Trigger::TriggerType_t & | triggerType () const |
Retrieve const The type of trigger conditions which produced this readout. | |
void | setTriggerType (const DayaBay::Trigger::TriggerType_t &value) |
Update The type of trigger conditions which produced this readout. | |
const DayaBay::RawEvent * | rawEvent () const |
Retrieve const The raw data block for this readout. | |
DayaBay::RawEvent * | rawEvent () |
Retrieve The raw data block for this readout. | |
void | setRawEvent (DayaBay::RawEvent *value) |
Update The raw data block for this readout. | |
const DybDaq::EventReadout * | eventReadout () const |
Retrieve const The raw data block for this readout. | |
void | setEventReadout (DybDaq::EventReadout *value) |
Update The raw data block for this readout. | |
const DayaBay::ReadoutHeader * | header () const |
Retrieve const The readout header associated with this readout. | |
void | setHeader (DayaBay::ReadoutHeader *value) |
Update The readout header associated with this readout. | |
Static Public Member Functions | |
static void * | operator new (size_t size) |
operator new | |
static void * | operator new (size_t size, void *pObj) |
placement operator new it is needed by libstdc++ 3.2.3 (e.g. | |
static void | operator delete (void *p) |
operator delete | |
static void | operator delete (void *p, void *pObj) |
placement operator delete not sure if really needed, but it does not harm | |
Private Attributes | |
RpcChannelReadouts | m_channelReadout |
The set of channels in this readout. |
Definition at line 42 of file ReadoutRpcCrate.h.
DayaBay::ReadoutRpcCrate::ReadoutRpcCrate | ( | const DayaBay::Detector & | detector, | |
unsigned int | triggerNumber, | |||
const TimeStamp & | triggerTime, | |||
const DayaBay::Trigger::TriggerType_t & | triggerType | |||
) | [inline] |
standard constructor
Definition at line 50 of file ReadoutRpcCrate.h.
00053 : Readout(detector, 00054 triggerNumber, 00055 triggerTime, 00056 triggerType) {}
DayaBay::ReadoutRpcCrate::ReadoutRpcCrate | ( | const DayaBay::ReadoutRpcCrate & | rhs | ) |
copy constructor
Definition at line 20 of file ReadoutRpcCrate.cc.
00021 : Readout(rh) 00022 { 00023 DayaBay::ReadoutRpcCrate::RpcChannelReadouts channels = rh.channelReadout(); 00024 DayaBay::ReadoutRpcCrate::RpcChannelReadouts::iterator it, done = channels.end(); 00025 for (it = channels.begin(); it != done; ++it) { 00026 it->second.setReadout(this); 00027 } 00028 this->setChannelReadout(channels); 00029 }
DayaBay::ReadoutRpcCrate::ReadoutRpcCrate | ( | ) | [inline] |
virtual DayaBay::ReadoutRpcCrate::~ReadoutRpcCrate | ( | ) | [inline, virtual] |
DayaBay::ReadoutRpcCrate & DayaBay::ReadoutRpcCrate::operator= | ( | const DayaBay::ReadoutRpcCrate & | rhs | ) |
assignment operator
Definition at line 31 of file ReadoutRpcCrate.cc.
00032 { 00033 if (this == &rh) return *this; 00034 00035 (Readout&)(*this) = (Readout&)(rh); 00036 00037 DayaBay::ReadoutRpcCrate::RpcChannelReadouts channels = rh.channelReadout(); 00038 DayaBay::ReadoutRpcCrate::RpcChannelReadouts::iterator it, done = channels.end(); 00039 for (it = channels.begin(); it != done; ++it) { 00040 it->second.setReadout(this); 00041 } 00042 this->setChannelReadout(channels); 00043 00044 return *this; 00045 }
void DayaBay::ReadoutRpcCrate::addChannel | ( | const DayaBay::FecChannelId & | channelId | ) | [inline] |
Adds a channel to this readout.
Definition at line 151 of file ReadoutRpcCrate.h.
00152 { 00153 00154 m_channelReadout[channelId] = DayaBay::ReadoutRpcChannel(channelId, 00155 this); 00156 00157 }
DayaBay::ReadoutRpcChannel & DayaBay::ReadoutRpcCrate::channel | ( | const DayaBay::FecChannelId & | channelId | ) | [inline] |
Returns the specified channel from this readout.
Definition at line 159 of file ReadoutRpcCrate.h.
00160 { 00161 return m_channelReadout[channelId]; 00162 }
std::ostream & DayaBay::ReadoutRpcCrate::fillStream | ( | std::ostream & | s | ) | const [virtual] |
Print the crate data.
Reimplemented from DayaBay::Readout.
Definition at line 4 of file ReadoutRpcCrate.cc.
00005 { 00006 size_t siz = m_channelReadout.size(); 00007 00008 s << "{ " 00009 << siz << " readouts : " << std::endl; 00010 00011 RpcChannelReadouts::const_iterator it, done = m_channelReadout.end(); 00012 for (it=m_channelReadout.begin(); it != done; ++it) { 00013 s << (it->first) << (it->second) << std::endl; 00014 } 00015 s << "}"; 00016 return s; 00017 }
const DayaBay::ReadoutRpcCrate::RpcChannelReadouts & DayaBay::ReadoutRpcCrate::channelReadout | ( | ) | const [inline] |
Retrieve const The set of channels in this readout.
Definition at line 141 of file ReadoutRpcCrate.h.
00142 { 00143 return m_channelReadout; 00144 }
void DayaBay::ReadoutRpcCrate::setChannelReadout | ( | const RpcChannelReadouts & | value | ) | [inline] |
Update The set of channels in this readout.
Definition at line 146 of file ReadoutRpcCrate.h.
00147 { 00148 m_channelReadout = value; 00149 }
static void* DayaBay::ReadoutRpcCrate::operator new | ( | size_t | size | ) | [inline, static] |
operator new
Reimplemented from DayaBay::Readout.
Definition at line 90 of file ReadoutRpcCrate.h.
00091 { 00092 return ( sizeof(ReadoutRpcCrate) == size ? 00093 boost::singleton_pool<ReadoutRpcCrate, sizeof(ReadoutRpcCrate)>::malloc() : 00094 ::operator new(size) ); 00095 }
static void* DayaBay::ReadoutRpcCrate::operator new | ( | size_t | size, | |
void * | pObj | |||
) | [inline, static] |
placement operator new it is needed by libstdc++ 3.2.3 (e.g.
in std::vector) it is not needed in libstdc++ >= 3.4
Reimplemented from DayaBay::Readout.
Definition at line 100 of file ReadoutRpcCrate.h.
00101 { 00102 return ::operator new (size,pObj); 00103 }
static void DayaBay::ReadoutRpcCrate::operator delete | ( | void * | p | ) | [inline, static] |
operator delete
Reimplemented from DayaBay::Readout.
Definition at line 106 of file ReadoutRpcCrate.h.
00107 { 00108 boost::singleton_pool<ReadoutRpcCrate, sizeof(ReadoutRpcCrate)>::is_from(p) ? 00109 boost::singleton_pool<ReadoutRpcCrate, sizeof(ReadoutRpcCrate)>::free(p) : 00110 ::operator delete(p); 00111 }
static void DayaBay::ReadoutRpcCrate::operator delete | ( | void * | p, | |
void * | pObj | |||
) | [inline, static] |
placement operator delete not sure if really needed, but it does not harm
Reimplemented from DayaBay::Readout.
Definition at line 115 of file ReadoutRpcCrate.h.
00116 { 00117 ::operator delete (p, pObj); 00118 }
const DayaBay::Detector & DayaBay::Readout::detector | ( | ) | const [inline, inherited] |
Retrieve const The detector associated with this readout.
Definition at line 247 of file Readout.h.
00248 { 00249 return m_detector; 00250 }
void DayaBay::Readout::setDetector | ( | const DayaBay::Detector & | value | ) | [inline, inherited] |
Update The detector associated with this readout.
Definition at line 252 of file Readout.h.
00253 { 00254 m_detector = value; 00255 }
unsigned int DayaBay::Readout::triggerNumber | ( | ) | const [inline, inherited] |
Retrieve const The count of the trigger command from this detector.
Definition at line 257 of file Readout.h.
00258 { 00259 return m_triggerNumber; 00260 }
void DayaBay::Readout::setTriggerNumber | ( | unsigned int | value | ) | [inline, inherited] |
Update The count of the trigger command from this detector.
Definition at line 262 of file Readout.h.
00263 { 00264 m_triggerNumber = value; 00265 }
const TimeStamp & DayaBay::Readout::triggerTime | ( | ) | const [inline, inherited] |
Retrieve const The absolute time of the trigger command.
Definition at line 267 of file Readout.h.
00268 { 00269 return m_triggerTime; 00270 }
void DayaBay::Readout::setTriggerTime | ( | const TimeStamp & | value | ) | [inline, inherited] |
Update The absolute time of the trigger command.
Definition at line 272 of file Readout.h.
00273 { 00274 m_triggerTime = value; 00275 }
const DayaBay::Trigger::TriggerType_t & DayaBay::Readout::triggerType | ( | ) | const [inline, inherited] |
Retrieve const The type of trigger conditions which produced this readout.
Definition at line 277 of file Readout.h.
00278 { 00279 return m_triggerType; 00280 }
void DayaBay::Readout::setTriggerType | ( | const DayaBay::Trigger::TriggerType_t & | value | ) | [inline, inherited] |
Update The type of trigger conditions which produced this readout.
Definition at line 282 of file Readout.h.
00283 { 00284 m_triggerType = value; 00285 }
const DayaBay::RawEvent * DayaBay::Readout::rawEvent | ( | ) | const [inline, inherited] |
Retrieve const The raw data block for this readout.
Definition at line 287 of file Readout.h.
00288 { 00289 return m_rawEvent; 00290 }
DayaBay::RawEvent * DayaBay::Readout::rawEvent | ( | ) | [inline, inherited] |
Retrieve The raw data block for this readout.
Definition at line 292 of file Readout.h.
00293 { 00294 return m_rawEvent; 00295 }
void DayaBay::Readout::setRawEvent | ( | DayaBay::RawEvent * | value | ) | [inline, inherited] |
Update The raw data block for this readout.
Definition at line 297 of file Readout.h.
00298 { 00299 m_rawEvent = value; 00300 }
const DybDaq::EventReadout * DayaBay::Readout::eventReadout | ( | ) | const [inline, inherited] |
Retrieve const The raw data block for this readout.
Definition at line 302 of file Readout.h.
00303 { 00304 return m_eventReadout; 00305 }
void DayaBay::Readout::setEventReadout | ( | DybDaq::EventReadout * | value | ) | [inline, inherited] |
Update The raw data block for this readout.
Definition at line 307 of file Readout.h.
00308 { 00309 m_eventReadout = value; 00310 }
const DayaBay::ReadoutHeader * DayaBay::Readout::header | ( | ) | const [inline, inherited] |
void DayaBay::Readout::setHeader | ( | DayaBay::ReadoutHeader * | value | ) | [inline, inherited] |