Loading [MathJax]/jax/input/TeX/config.js
ATLAS Offline Software
All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Modules Pages
Public Types | Public Member Functions | Protected Member Functions | Private Attributes | Friends | List of all members
DataHeader Class Reference

This class provides the layout for summary information stored for data written to POOL. More...

#include <DataHeader.h>

Inheritance diagram for DataHeader:
Collaboration diagram for DataHeader:

Public Types

enum  statusFlag { Output, Input, Other }
 

Public Member Functions

 DataHeader ()
 Default Constructor. More...
 
 DataHeader (const DataHeader &rhs)
 Copy Constructor. More...
 
virtual ~DataHeader ()
 Destructor. More...
 
DataHeaderoperator= (const DataHeader &rhs)
 Assignment Operator. More...
 
void setStatus (statusFlag status)
 Set StatusFlag enum for DataHeader. More...
 
bool isInput () const
 Check whether StatusFlag is "Input". More...
 
void setProcessTag (const std::string &processTag)
 Set ProcessTag for DataHeader. More...
 
const std::string & getProcessTag () const
 
int size () const
 
std::vector< DataHeaderElement >::const_iterator begin () const
 
std::vector< DataHeaderElement >::const_iterator end () const
 
const std::vector< DataHeaderElement > & elements () const
 
void insert (const SG::TransientAddress *sgAddress, IOpaqueAddress *tokAddress=0, const std::string &pTag="")
 Insert a new element into the "DataObject" vector. More...
 
void insert (const SG::DataProxy *proxy, IOpaqueAddress *tokAddress=0, const std::string &pTag="")
 Insert a new element into the "DataObject" vector. More...
 
void insert (const DataHeaderElement &dhe)
 Insert a new element into the "DataObject" vector. More...
 
int sizeProvenance () const
 
std::vector< DataHeaderElement >::const_iterator beginProvenance () const
 
std::vector< DataHeaderElement >::const_iterator endProvenance () const
 
void insertProvenance (const DataHeaderElement &dhe)
 Insert a new element into the "Provenance" vector. More...
 
void addHash (IStringPool *pool)
 Add new entry to hash map. More...
 
const std::string & dhFormToken () const
 Form token, to be able to tell when the form changes. More...
 
void setDhFormToken (const std::string &formToken)
 
void setAttributeList (const coral::AttributeList *attrList)
 
const coral::AttributeList * getAttributeList ()
 
void setEvtRefTokenStr (const std::string &tokenStr)
 
const std::string & getEvtRefTokenStr ()
 
void dump (std::ostream &ostr) const
 

Protected Member Functions

virtual void recycle ()
 Called before this object is recycled. More...
 

Private Attributes

std::vector< DataHeaderElementm_dataHeader
 vector with DataHeaderElement to "DataObject". More...
 
std::vector< DataHeaderElementm_inputDataHeader
 vector with DataHeaderElement to upstream DataHeader ("Provenance"). More...
 
statusFlag m_status
 StatusFlag (i.e.: Output, Primary, Input, Manual, Other). More...
 
std::string m_processTag
 ProcessTag (e.g.: "StreamESD", "StreamAOD" ...). More...
 
const coral::AttributeList * m_attrList
 Optional pointer to AttributeList to enable writing of TAG Attributes to Payload files. More...
 
std::string m_evtRefTokenStr
 Optional Token String for Event Reference to enable writing of TAG to Payload files. More...
 
std::string m_dhFormToken
 Token to the DH format object. More...
 

Friends

class DataHeaderCnv_p3
 
class DataHeaderCnv_p4
 
class DataHeaderCnv_p5
 
class DataHeaderCnv_p6
 
class DataHeaderCnv
 

Detailed Description

This class provides the layout for summary information stored for data written to POOL.

Definition at line 124 of file DataHeader.h.

Member Enumeration Documentation

◆ statusFlag

Enumerator
Output 
Input 
Other 

Definition at line 128 of file DataHeader.h.

128 { Output, Input, Other };

Constructor & Destructor Documentation

◆ DataHeader() [1/2]

DataHeader::DataHeader ( )

Default Constructor.

Definition at line 185 of file DataHeader.cxx.

185  : m_dataHeader(),
188  m_processTag(),
189  m_attrList(0),
190  m_evtRefTokenStr() {
191 }

◆ DataHeader() [2/2]

DataHeader::DataHeader ( const DataHeader rhs)

Copy Constructor.

Definition at line 193 of file DataHeader.cxx.

193  :
194  DataObject (rhs),
197  m_status(rhs.m_status),
199  m_attrList(rhs.m_attrList),
200  m_evtRefTokenStr() {
201 }

◆ ~DataHeader()

DataHeader::~DataHeader ( )
virtual

Destructor.

Definition at line 203 of file DataHeader.cxx.

203  {
204 }

Member Function Documentation

◆ addHash()

void DataHeader::addHash ( IStringPool pool)

Add new entry to hash map.

Definition at line 279 of file DataHeader.cxx.

279  {
281  last = m_dataHeader.end(); iter != last; ++iter) {
282  iter->addHash(pool);
283  }
285  last = m_inputDataHeader.end(); iter != last; ++iter) {
286  iter->addHash(pool);
287  }
288 }

◆ begin()

std::vector< DataHeaderElement >::const_iterator DataHeader::begin ( ) const
Returns
a const_iterator at the begin() of the "DataObject" vector.

Definition at line 237 of file DataHeader.cxx.

237  {
238  return(m_dataHeader.begin());
239 }

◆ beginProvenance()

std::vector< DataHeaderElement >::const_iterator DataHeader::beginProvenance ( ) const
Returns
a const_iterator at the begin() of the "Provenance" vector.

Definition at line 267 of file DataHeader.cxx.

267  {
268  return(m_inputDataHeader.begin());
269 }

◆ dhFormToken()

const std::string & DataHeader::dhFormToken ( ) const

Form token, to be able to tell when the form changes.

Definition at line 290 of file DataHeader.cxx.

291 {
292  return m_dhFormToken;
293 }

◆ dump()

void DataHeader::dump ( std::ostream &  ostr) const

Definition at line 319 of file DataHeader.cxx.

320 {
321  using namespace std;
322  ostr << "--- DataHeader Dump ---" << endl;
323  for( auto& el : m_dataHeader ) {
324  el.dump(ostr);
325  }
326  for( auto& el : m_inputDataHeader ) {
327  el.dump(ostr);
328  }
329  ostr << "Status: " << m_status << endl;
330  ostr << "Proc tag: " << m_processTag << endl;
331  ostr << "evtRef: " << m_evtRefTokenStr << endl;
332  ostr << "attrListPtr: " << m_attrList << endl;
333  if( m_attrList ) ostr << "attrListSize: " << m_attrList->size() << endl;
334  ostr << "--- DataHeader End ---" << endl;
335 }

◆ elements()

const std::vector< DataHeaderElement > & DataHeader::elements ( ) const
Returns
the "DataObject" vector.

Definition at line 245 of file DataHeader.cxx.

245  {
246  return m_dataHeader;
247 }

◆ end()

std::vector< DataHeaderElement >::const_iterator DataHeader::end ( ) const
Returns
a const_iterator at the end() of the "DataObject" vector.

Definition at line 241 of file DataHeader.cxx.

241  {
242  return(m_dataHeader.end());
243 }

◆ endProvenance()

std::vector< DataHeaderElement >::const_iterator DataHeader::endProvenance ( ) const
Returns
a const_iterator at the end() of the "Provenance" vector.

Definition at line 271 of file DataHeader.cxx.

271  {
272  return(m_inputDataHeader.end());
273 }

◆ getAttributeList()

const coral::AttributeList * DataHeader::getAttributeList ( )

Definition at line 304 of file DataHeader.cxx.

304  {
305  return(m_attrList);
306 }

◆ getEvtRefTokenStr()

const std::string & DataHeader::getEvtRefTokenStr ( )

Definition at line 312 of file DataHeader.cxx.

312  {
313  return(m_evtRefTokenStr);
314 }

◆ getProcessTag()

const std::string & DataHeader::getProcessTag ( ) const
Returns
the string containing ProcessTag for the DataHeader.

Definition at line 229 of file DataHeader.cxx.

229  {
230  return(m_processTag);
231 }

◆ insert() [1/3]

void DataHeader::insert ( const DataHeaderElement dhe)

Insert a new element into the "DataObject" vector.

Parameters
dhe[IN] reference to the DataHeaderElement to be inserted.

Definition at line 259 of file DataHeader.cxx.

259  {
260  m_dataHeader.push_back(dhe);
261 }

◆ insert() [2/3]

void DataHeader::insert ( const SG::DataProxy proxy,
IOpaqueAddress *  tokAddress = 0,
const std::string &  pTag = "" 
)

Insert a new element into the "DataObject" vector.

Parameters
proxy[IN] pointer to the DataProxy for the DataObject.
pTag[IN] string to overwrite key member of the DataHeaderElement

Definition at line 255 of file DataHeader.cxx.

255  {
256  m_dataHeader.emplace_back(proxy, tokAddress, pTag);
257 }

◆ insert() [3/3]

void DataHeader::insert ( const SG::TransientAddress sgAddress,
IOpaqueAddress *  tokAddress = 0,
const std::string &  pTag = "" 
)

Insert a new element into the "DataObject" vector.

Parameters
sgAddress[IN] pointer to the TransientAddress of the DataObject.
pTag[IN] string to overwrite key member of the DataHeaderElement

Definition at line 249 of file DataHeader.cxx.

249  {
250  if (sgAddress != 0) {
251  m_dataHeader.emplace_back(sgAddress, tokAddress, pTag);
252  }
253 }

◆ insertProvenance()

void DataHeader::insertProvenance ( const DataHeaderElement dhe)

Insert a new element into the "Provenance" vector.

Parameters
dhe[IN] reference to the DataHeaderElement to be inserted.

Definition at line 275 of file DataHeader.cxx.

275  {
276  m_inputDataHeader.push_back(dhe);
277 }

◆ isInput()

bool DataHeader::isInput ( ) const

Check whether StatusFlag is "Input".

Definition at line 221 of file DataHeader.cxx.

221  {
222  return(m_status == statusFlag(Input));
223 }

◆ operator=()

DataHeader & DataHeader::operator= ( const DataHeader rhs)

Assignment Operator.

Definition at line 206 of file DataHeader.cxx.

206  {
207  if (this != &rhs) {
210  m_status = rhs.m_status;
212  m_attrList = rhs.m_attrList;
213  }
214  return(*this);
215 }

◆ recycle()

void DataHeader::recycle ( )
protectedvirtual

Called before this object is recycled.

Definition at line 337 of file DataHeader.cxx.

338 {
339 }

◆ setAttributeList()

void DataHeader::setAttributeList ( const coral::AttributeList *  attrList)

Definition at line 300 of file DataHeader.cxx.

300  {
301  m_attrList = attrList;
302 }

◆ setDhFormToken()

void DataHeader::setDhFormToken ( const std::string &  formToken)

Definition at line 295 of file DataHeader.cxx.

296 {
297  m_dhFormToken = formToken;
298 }

◆ setEvtRefTokenStr()

void DataHeader::setEvtRefTokenStr ( const std::string &  tokenStr)

Definition at line 308 of file DataHeader.cxx.

308  {
309  m_evtRefTokenStr = tokenStr;
310 }

◆ setProcessTag()

void DataHeader::setProcessTag ( const std::string &  processTag)

Set ProcessTag for DataHeader.

Parameters
processTag[IN] string containing ProcessTag.

Definition at line 225 of file DataHeader.cxx.

225  {
226  m_processTag = processTag;
227 }

◆ setStatus()

void DataHeader::setStatus ( statusFlag  status)

Set StatusFlag enum for DataHeader.

Definition at line 217 of file DataHeader.cxx.

217  {
218  m_status = status;
219 }

◆ size()

int DataHeader::size ( ) const
Returns
the number of elements in the "DataObject" vector.

Definition at line 233 of file DataHeader.cxx.

233  {
234  return(m_dataHeader.size());
235 }

◆ sizeProvenance()

int DataHeader::sizeProvenance ( ) const
Returns
the number of elements in the "Provenance" vector.

Definition at line 263 of file DataHeader.cxx.

263  {
264  return(m_inputDataHeader.size());
265 }

Friends And Related Function Documentation

◆ DataHeaderCnv

friend class DataHeaderCnv
friend

Definition at line 209 of file DataHeader.h.

◆ DataHeaderCnv_p3

friend class DataHeaderCnv_p3
friend

Definition at line 205 of file DataHeader.h.

◆ DataHeaderCnv_p4

friend class DataHeaderCnv_p4
friend

Definition at line 206 of file DataHeader.h.

◆ DataHeaderCnv_p5

friend class DataHeaderCnv_p5
friend

Definition at line 207 of file DataHeader.h.

◆ DataHeaderCnv_p6

friend class DataHeaderCnv_p6
friend

Definition at line 208 of file DataHeader.h.

Member Data Documentation

◆ m_attrList

const coral::AttributeList* DataHeader::m_attrList
private

Optional pointer to AttributeList to enable writing of TAG Attributes to Payload files.

Definition at line 220 of file DataHeader.h.

◆ m_dataHeader

std::vector<DataHeaderElement> DataHeader::m_dataHeader
private

vector with DataHeaderElement to "DataObject".

Definition at line 212 of file DataHeader.h.

◆ m_dhFormToken

std::string DataHeader::m_dhFormToken
private

Token to the DH format object.

Definition at line 224 of file DataHeader.h.

◆ m_evtRefTokenStr

std::string DataHeader::m_evtRefTokenStr
private

Optional Token String for Event Reference to enable writing of TAG to Payload files.

Definition at line 222 of file DataHeader.h.

◆ m_inputDataHeader

std::vector<DataHeaderElement> DataHeader::m_inputDataHeader
private

vector with DataHeaderElement to upstream DataHeader ("Provenance").

Definition at line 214 of file DataHeader.h.

◆ m_processTag

std::string DataHeader::m_processTag
private

ProcessTag (e.g.: "StreamESD", "StreamAOD" ...).

Definition at line 218 of file DataHeader.h.

◆ m_status

statusFlag DataHeader::m_status
private

StatusFlag (i.e.: Output, Primary, Input, Manual, Other).

Definition at line 216 of file DataHeader.h.


The documentation for this class was generated from the following files:
xAOD::iterator
JetConstituentVector::iterator iterator
Definition: JetConstituentVector.cxx:68
StateLessPT_NewConfig.proxy
proxy
Definition: StateLessPT_NewConfig.py:395
DataHeader::m_attrList
const coral::AttributeList * m_attrList
Optional pointer to AttributeList to enable writing of TAG Attributes to Payload files.
Definition: DataHeader.h:220
DataHeader::Input
@ Input
Definition: DataHeader.h:128
pool
pool namespace
Definition: libname.h:15
DataHeader::statusFlag
statusFlag
Definition: DataHeader.h:128
DataHeader::m_dhFormToken
std::string m_dhFormToken
Token to the DH format object.
Definition: DataHeader.h:224
DataHeader::Output
@ Output
Definition: DataHeader.h:128
plotIsoValidation.el
el
Definition: plotIsoValidation.py:197
jobOptions.pTag
string pTag
Definition: jobOptions.py:28
DataHeader::m_status
statusFlag m_status
StatusFlag (i.e.: Output, Primary, Input, Manual, Other).
Definition: DataHeader.h:216
DataHeader::m_dataHeader
std::vector< DataHeaderElement > m_dataHeader
vector with DataHeaderElement to "DataObject".
Definition: DataHeader.h:212
DataHeader::Other
@ Other
Definition: DataHeader.h:128
DataHeader::m_processTag
std::string m_processTag
ProcessTag (e.g.: "StreamESD", "StreamAOD" ...).
Definition: DataHeader.h:218
merge.status
status
Definition: merge.py:17
NswErrorCalibData::Input
Helper struct to be parsed to the object to derive the specific error of the cluster.
Definition: NswErrorCalibData.h:25
DataHeader::m_inputDataHeader
std::vector< DataHeaderElement > m_inputDataHeader
vector with DataHeaderElement to upstream DataHeader ("Provenance").
Definition: DataHeader.h:214
DataHeader::m_evtRefTokenStr
std::string m_evtRefTokenStr
Optional Token String for Event Reference to enable writing of TAG to Payload files.
Definition: DataHeader.h:222