/search.css" rel="stylesheet" type="text/css"/> /search.js">
00001 00002 // ************************************************************************** 00003 // * * 00004 // * ! ! ! A T T E N T I O N ! ! ! * 00005 // * * 00006 // * This file was created automatically by GaudiObjDesc, please do not * 00007 // * delete it or edit it by hand. * 00008 // * * 00009 // * If you want to change this file, first change the corresponding * 00010 // * xml-file and rerun the tools from GaudiObjDesc (or run make if you * 00011 // * are using it from inside a Gaudi-package). * 00012 // * * 00013 // ************************************************************************** 00014 00015 #ifndef ReadoutEvent_ReadoutHeader_H 00016 #define ReadoutEvent_ReadoutHeader_H 1 00017 00018 // Include files 00019 #include "Event/HeaderObject.h" 00020 #include "Event/DaqCrate.h" 00021 #include "GaudiKernel/boost_allocator.h" 00022 #include <ostream> 00023 00024 // Forward declarations 00025 00026 namespace DayaBay 00027 { 00028 00029 // Forward declarations 00030 class Readout; 00031 00032 00033 // Class ID definition 00034 static const CLID CLID_ReadoutHeader = 51601; 00035 00036 // Namespace for locations in TDS 00037 namespace ReadoutHeaderLocation { 00038 static const std::string& Default = "/Event/Readout/ReadoutHeader"; 00039 } 00040 00041 00051 class ReadoutHeader: public HeaderObject 00052 { 00053 public: 00054 00056 static const std::string& defaultLocation() { return ReadoutHeaderLocation::Default; } 00057 virtual const std::string& defLoc() const { return ReadoutHeaderLocation::Default; } 00058 00060 ReadoutHeader() : m_readout(0), 00061 m_daqCrate(0) {} 00062 00064 ~ReadoutHeader(); 00065 00066 // Retrieve pointer to class definition structure 00067 virtual const CLID& clID() const; 00068 static const CLID& classID(); 00069 00071 virtual std::ostream& fillStream(std::ostream& s) const; 00072 00074 const DayaBay::DaqCrate* daqCrate() const; 00075 00078 const DayaBay::Readout* readout() const; 00079 00082 void setReadout(DayaBay::Readout* value); 00083 00086 void setDaqCrate(const DayaBay::DaqCrate* value); 00087 00088 00089 #ifndef GOD_NOALLOC 00090 00091 static void* operator new ( size_t size ) 00092 { 00093 return ( sizeof(ReadoutHeader) == size ? 00094 boost::singleton_pool<ReadoutHeader, sizeof(ReadoutHeader)>::malloc() : 00095 ::operator new(size) ); 00096 } 00097 00101 static void* operator new ( size_t size, void* pObj ) 00102 { 00103 return ::operator new (size,pObj); 00104 } 00105 00107 static void operator delete ( void* p ) 00108 { 00109 boost::singleton_pool<ReadoutHeader, sizeof(ReadoutHeader)>::is_from(p) ? 00110 boost::singleton_pool<ReadoutHeader, sizeof(ReadoutHeader)>::free(p) : 00111 ::operator delete(p); 00112 } 00113 00116 static void operator delete ( void* p, void* pObj ) 00117 { 00118 ::operator delete (p, pObj); 00119 } 00120 #endif 00121 protected: 00122 00123 private: 00124 00125 DayaBay::Readout* m_readout; 00126 const DayaBay::DaqCrate* m_daqCrate; 00127 00128 }; // class ReadoutHeader 00129 00130 inline std::ostream& operator<< (std::ostream& str, const ReadoutHeader& obj) 00131 { 00132 return obj.fillStream(str); 00133 } 00134 00135 } // namespace DayaBay; 00136 00137 // ----------------------------------------------------------------------------- 00138 // end of class 00139 // ----------------------------------------------------------------------------- 00140 00141 // Including forward declarations 00142 #include "Readout.h" 00143 00144 00145 inline DayaBay::ReadoutHeader::~ReadoutHeader() 00146 { 00147 00148 delete m_daqCrate; 00149 delete m_readout; 00150 00151 } 00152 00153 inline const CLID& DayaBay::ReadoutHeader::clID() const 00154 { 00155 return DayaBay::ReadoutHeader::classID(); 00156 } 00157 00158 inline const CLID& DayaBay::ReadoutHeader::classID() 00159 { 00160 return CLID_ReadoutHeader; 00161 } 00162 00163 inline std::ostream& DayaBay::ReadoutHeader::fillStream(std::ostream& s) const 00164 { 00165 HeaderObject::fillStream(s); 00166 s << "{ " << "readout : " << m_readout << std::endl 00167 << "daqCrate : " << m_daqCrate << std::endl << " }"; 00168 return s; 00169 } 00170 00171 00172 inline const DayaBay::Readout* DayaBay::ReadoutHeader::readout() const 00173 { 00174 return m_readout; 00175 } 00176 00177 inline void DayaBay::ReadoutHeader::setReadout(DayaBay::Readout* value) 00178 { 00179 m_readout = value; 00180 } 00181 00182 inline void DayaBay::ReadoutHeader::setDaqCrate(const DayaBay::DaqCrate* value) 00183 { 00184 m_daqCrate = value; 00185 } 00186 00187 00188 #endif ///ReadoutEvent_ReadoutHeader_H