![]() |
ATLAS Offline Software
|
This class provides the core BLOB infrastructure. More...
#include <CaloCondBlobBase.h>
Public Member Functions | |
| virtual | ~CaloCondBlobBase () |
| Dtor. | |
| CaloCondBlobBase (const CaloCondBlobBase &other) | |
| Copy Ctor. | |
| CaloCondBlobBase & | operator= (const CaloCondBlobBase &other) |
| Assignment operator. | |
| virtual uint16_t | getType () const |
| Returns CaloCondDrawer::BASE. | |
| virtual void | dump () const |
| Prints the BLOB header summary information to std::cout. | |
| virtual void | dump (std::ostream &stm) const |
| Prints the BLOB header summary information. | |
| long | getBlobSize () const |
| Returns the BLOB size. | |
| uint16_t | getObjType () const |
| Returns the BLOB object type. | |
| uint16_t | getObjVersion () const |
| Returns the BLOB object version. | |
| uint32_t | getObjSizeUint32 () const |
| Returns the size of a data object in units of uint32_t. | |
| uint32_t | getObjSizeByte () const |
| Returns the size of a data object in units of bytes. | |
| uint32_t | getNObjs () const |
| Returns the number of data objects stored int the BLOB. | |
| uint32_t | getNChans () const |
| Returns the number of channels stored in the BLOB. | |
| uint32_t | getNGains () const |
| Returns the number of gains stored for each channel. | |
| uint32_t | getCommentSizeUint32 () const |
| Returns the space occupied by the comment fields in units of uint32_t. | |
| uint32_t | getCommentSizeChar () const |
| Returns the space occupied by the comment fields in units of chars. | |
| unsigned int | getHdrSize () const |
| Returns the size of the header in units of uint32_t. | |
| std::string | getAuthor () const |
| Returns the comment author. | |
| std::string | getComment () const |
| Returns the actual comment. | |
| uint64_t | getTimeStamp () const |
| Returns the unix timestamp of the comment (seconds since 1.1.1970) | |
| std::string | getDate () const |
| Returns the date of the comment as string (derived from timestamp) | |
| std::string | getFullComment () const |
| Returns a formated string build from all comment fields. | |
| const void * | getAddress (unsigned int iEle) const |
| Returns start address of iEle-th basic unit. | |
| void * | getAddress (unsigned int iEle) |
Protected Member Functions | |
| CaloCondBlobBase (const coral::Blob &blob) | |
| Ctor for const blob. | |
| CaloCondBlobBase (coral::Blob &blob) | |
| Ctor for non-const blob. | |
| uint32_t | createBlob (uint16_t objType, uint16_t objVersion, uint32_t objSizeUint32, uint32_t nObjs, uint32_t nChans, uint16_t nGains, const std::string &author="", const std::string &comment="", uint64_t timeStamp=0) |
| (re-)creation of the referenced BLOB object. | |
| void | dumpHeader (std::ostream &stm) const |
| Prints the BLOB header summary information. | |
Protected Attributes | |
| const void * | m_pDataStart |
Private Member Functions | |
| CaloCondBlobBase (coral::Blob *blob_nc, const coral::Blob *blob) | |
| Internal ctor. | |
| const uint32_t * | getBlobStart () const |
| Returns the BLOB start address as uint32_t pointer. | |
| uint32_t * | getBlobStart () |
| Returns the BLOB start address as uint32_t pointer. | |
Static Private Member Functions | |
| static uint32_t | packGainAndNchans (const uint32_t gain, const uint32_t nChans) |
| static uint32_t | unpacknGains (const uint32_t gainAndnChans) |
| static uint32_t | unpacknChans (const uint32_t gainAndnChans) |
Private Attributes | |
| coral::Blob * | m_blob_nc |
| Non-const reference to the BLOB. | |
| const coral::Blob * | m_blob |
| Const reference to the BLOB (always there) | |
| bool | m_isBlobOwner |
| Do I own the BLOB? | |
| unsigned | m_sizeOfObj |
| Chache of some frequently-used numbers. | |
| unsigned | m_nChans |
| unsigned | m_nGains |
This class provides the core BLOB infrastructure.
All data storage classes inherit from this class. It provides the infrastructure to store and retrieve units of conditions data associated with one channel/gain ("data object") by implementing a common BLOB header. This header holds the following information:
A data object contains all conditions data related to one channel/gain (depending on data stored on channel or adc level), for example 5 floats. The conditions data units themselves must be build from objects of 32 bit length, i.e. available types are float, uint32_t and int32_t.
Definition at line 43 of file CaloCondBlobBase.h.
|
virtual |
Dtor.
Definition at line 43 of file CaloCondBlobBase.cxx.
| CaloCondBlobBase::CaloCondBlobBase | ( | const CaloCondBlobBase & | other | ) |
Copy Ctor.
Definition at line 51 of file CaloCondBlobBase.cxx.
|
protected |
Ctor for const blob.
Definition at line 31 of file CaloCondBlobBase.cxx.
|
protected |
Ctor for non-const blob.
Definition at line 36 of file CaloCondBlobBase.cxx.
|
private |
Internal ctor.
Definition at line 13 of file CaloCondBlobBase.cxx.
|
protected |
(re-)creation of the referenced BLOB object.
| objType | Object type |
| objVersion | Object version |
| objSizeUint32 | Size of a data object (in uint32_t) |
| nObjs | Total number of data objects |
| nChans | number of stored channels |
| nGains | number of stored gains |
| author | comment author |
| comment | actual comment |
| timeStamp | unix time stamp (if 0, current time is used) |
Definition at line 84 of file CaloCondBlobBase.cxx.
|
inlinevirtual |
Prints the BLOB header summary information to std::cout.
Reimplemented in CaloCondBlobDat< T >, and CaloCondBlobDat< float >.
Definition at line 56 of file CaloCondBlobBase.h.
|
inlinevirtual |
Prints the BLOB header summary information.
| stm | The output stream to use |
Reimplemented in CaloCondBlobDat< T >.
Definition at line 59 of file CaloCondBlobBase.h.
|
protected |
Prints the BLOB header summary information.
| stm | output stream to use |
Definition at line 229 of file CaloCondBlobBase.cxx.
|
inline |
Definition at line 272 of file CaloCondBlobBase.h.
|
inline |
Returns start address of iEle-th basic unit.
| iEle | sequential basic unit number |
Definition at line 260 of file CaloCondBlobBase.h.
| std::string CaloCondBlobBase::getAuthor | ( | ) | const |
Returns the comment author.
Definition at line 176 of file CaloCondBlobBase.cxx.
|
inline |
|
inlineprivate |
Returns the BLOB start address as uint32_t pointer.
Definition at line 186 of file CaloCondBlobBase.h.
|
inlineprivate |
Returns the BLOB start address as uint32_t pointer.
Definition at line 178 of file CaloCondBlobBase.h.
| std::string CaloCondBlobBase::getComment | ( | ) | const |
Returns the actual comment.
Definition at line 190 of file CaloCondBlobBase.cxx.
|
inline |
Returns the space occupied by the comment fields in units of chars.
Definition at line 84 of file CaloCondBlobBase.h.
|
inline |
Returns the space occupied by the comment fields in units of uint32_t.
Definition at line 250 of file CaloCondBlobBase.h.
| std::string CaloCondBlobBase::getDate | ( | ) | const |
Returns the date of the comment as string (derived from timestamp)
Definition at line 205 of file CaloCondBlobBase.cxx.
| std::string CaloCondBlobBase::getFullComment | ( | ) | const |
Returns a formated string build from all comment fields.
Definition at line 219 of file CaloCondBlobBase.cxx.
|
inline |
Returns the size of the header in units of uint32_t.
Definition at line 86 of file CaloCondBlobBase.h.
|
inline |
Returns the number of channels stored in the BLOB.
Definition at line 232 of file CaloCondBlobBase.h.
|
inline |
Returns the number of gains stored for each channel.
Definition at line 240 of file CaloCondBlobBase.h.
|
inline |
Returns the number of data objects stored int the BLOB.
Definition at line 222 of file CaloCondBlobBase.h.
|
inline |
Returns the size of a data object in units of bytes.
Definition at line 74 of file CaloCondBlobBase.h.
|
inline |
Returns the size of a data object in units of uint32_t.
Definition at line 214 of file CaloCondBlobBase.h.
|
inline |
Returns the BLOB object type.
Definition at line 194 of file CaloCondBlobBase.h.
|
inline |
Returns the BLOB object version.
Definition at line 204 of file CaloCondBlobBase.h.
|
inline |
Returns the unix timestamp of the comment (seconds since 1.1.1970)
Definition at line 284 of file CaloCondBlobBase.h.
|
inlinevirtual |
Returns CaloCondDrawer::BASE.
Reimplemented in CaloCondBlobFlt.
Definition at line 53 of file CaloCondBlobBase.h.
| CaloCondBlobBase & CaloCondBlobBase::operator= | ( | const CaloCondBlobBase & | other | ) |
Assignment operator.
Definition at line 65 of file CaloCondBlobBase.cxx.
|
staticprivate |
Definition at line 139 of file CaloCondBlobBase.cxx.
|
staticprivate |
Definition at line 160 of file CaloCondBlobBase.cxx.
|
staticprivate |
Definition at line 150 of file CaloCondBlobBase.cxx.
|
private |
Const reference to the BLOB (always there)
Definition at line 161 of file CaloCondBlobBase.h.
|
private |
Non-const reference to the BLOB.
(Only present if we were created with a non-const blob.)
Definition at line 158 of file CaloCondBlobBase.h.
|
private |
Do I own the BLOB?
Definition at line 164 of file CaloCondBlobBase.h.
|
private |
Definition at line 168 of file CaloCondBlobBase.h.
|
private |
Definition at line 169 of file CaloCondBlobBase.h.
|
protected |
Definition at line 171 of file CaloCondBlobBase.h.
|
private |
Chache of some frequently-used numbers.
Definition at line 167 of file CaloCondBlobBase.h.