ATLAS Offline Software
ShallowAuxContainer.cxx
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2024 CERN for the benefit of the ATLAS collaboration
3 */
4 
5 // System include(s):
6 #include <iostream>
7 #include <sstream>
8 #include <stdexcept>
9 
10 // EDM include(s):
16 
17 // Local include(s):
19 
20 namespace {
21 
22 
23 } // anonymous namespace
24 
25 
26 namespace xAOD {
27 
32  : m_selection(),
33  m_store( new SG::AuxStoreInternal( standalone ) ),
34  m_storeIO( nullptr ), m_ownsStore( true ), m_locked( false ),
35  m_parentLink(), m_parentIO( nullptr ), m_shallowIO( true ),
36  m_auxids (),
37  m_auxidsValid (false),
38  m_name( "UNKNOWN" ) {
39 
40  m_storeIO = dynamic_cast< SG::IAuxStoreIO* >( m_store );
41  }
42 
44  : SG::IAuxStore(), SG::IAuxStoreIO(), SG::IAuxStoreHolder(),
45  m_store( parent.m_store ), m_storeIO( parent.m_storeIO ),
46  m_ownsStore( false ), m_locked( parent.m_locked ),
47  m_parentLink( parent.m_parentLink ),
48  m_parentIO( parent.m_parentIO ), m_shallowIO( parent.m_shallowIO ),
49  m_auxids (),
50  m_auxidsValid (false)
51  {
52  // Keep the source unmutable during copy
53  guard_t guard( parent.m_mutex );
54  m_selection = parent.m_selection;
55  m_name = parent.m_name;
56  }
57 
64  bool standalone )
65  : m_selection(),
66  m_store( new SG::AuxStoreInternal( standalone ) ),
67  m_storeIO( nullptr ), m_ownsStore( true ), m_locked( false ),
68  m_parentLink( parent ), m_parentIO( nullptr ), m_shallowIO( true ),
69  m_auxids (),
70  m_auxidsValid (false),
71  m_name( "UNKNOWN" ) {
72 
73  m_storeIO = dynamic_cast< SG::IAuxStoreIO* >( m_store );
74  m_parentIO = dynamic_cast< const SG::IAuxStoreIO* >( m_parentLink.cptr() );
75  }
76 
78 
79  if( m_ownsStore && m_store ) {
80  delete m_store;
81  }
82  }
83 
86 
87  // Check if anything needs to be done:
88  if( this == &rhs ) {
89  return *this;
90  }
91 
92  // Keep the source unmutable during copy
93  std::scoped_lock lck{m_mutex, rhs.m_mutex};
94 
95  // Clean up if necessary:
96  if( m_ownsStore && m_store ) {
97  delete m_store;
98  m_store = nullptr;
99  }
100 
101  m_selection = rhs.m_selection;
102  m_ownsStore = false;
103  m_store = rhs.m_store;
104  m_storeIO = rhs.m_storeIO;
105  m_locked = rhs.m_locked;
107  m_parentIO = rhs.m_parentIO;
108  m_shallowIO = rhs.m_shallowIO;
109  m_name = rhs.m_name;
110  m_auxids = rhs.m_auxids;
111  m_auxidsValid= rhs.m_auxidsValid;
112 
113  // Return this object:
114  return *this;
115  }
116 
118 
119  return m_parentLink;
120  }
121 
124 
125  guard_t guard (m_mutex);
126  m_parentLink = link;
127  m_parentIO = dynamic_cast< const SG::IAuxStoreIO* >( m_parentLink.cptr() );
128  m_auxidsValid = false;
129  return;
130  }
131 
133 
134  return m_shallowIO;
135  }
136 
138 
139  guard_t guard (m_mutex);
140  m_shallowIO = value;
141  return;
142  }
143 
145  //
146  // Implementation of the SG::IAuxStoreHolder interface
147  //
148 
150  {
151  return m_store;
152  }
153 
155  {
156  return m_store;
157  }
158 
160 
161  // Check if anything needs to be done:
162  guard_t guard (m_mutex);
163  if( store == m_store ) return;
164 
165  if( m_ownsStore && m_store ) {
166  delete m_store;
167  m_store = nullptr;
168  }
169 
170  // Do the assignment:
171  m_store = store;
172  m_storeIO = dynamic_cast< SG::IAuxStoreIO* >( m_store );
173  m_ownsStore = true;
174  m_auxidsValid = false;
175 
176  return;
177  }
178 
179  //
181 
183  //
184  // Implementation of the SG::IConstAuxStore interface
185  //
186 
187  const void* ShallowAuxContainer::getData( auxid_t auxid ) const {
188 
189  const SG::IAuxTypeVector* v = getVector( auxid );
190  if( v ) {
191  return v->toPtr();
192  }
193  return nullptr;
194  }
195 
197 
198  guard_t guard( m_mutex );
199 
200  // Check if we have this variable ourselves. I use getData(...)
201  // instead of getAuxIDs(), as a dynamic store may not have connected
202  // to all the variables yet that it has available...
203  size_t nids = m_store->getAuxIDs().size();
204  const SG::IAuxTypeVector* result = m_store->getVector( auxid );
205  if( result != nullptr && result->toPtr() != nullptr ) {
206  if( nids != m_store->getAuxIDs().size() ) {
207  remakeAuxIDs();
208  }
209  return result;
210  }
211 
212  // If not, then leave it up to the parent object do deal with this:
213  if( m_parentLink.isValid() ) {
214  nids = m_parentLink->getAuxIDs().size();
215  result = m_parentLink->getVector( auxid );
216  if( result && ( nids != m_parentLink->getAuxIDs().size() ) ) {
217  remakeAuxIDs();
218  }
219  return result;
220  }
221 
222  // Apparently the variable wasn't found:
223  return nullptr;
224  }
225 
228 
229  guard_t guard( m_mutex );
230  if (!m_auxidsValid) {
231  remakeAuxIDs();
232  }
233  return m_auxids;
234  }
235 
238 
239  guard_t guard( m_mutex );
240  if (!m_auxidsValid) {
241  remakeAuxIDs();
242  }
243  return m_decorids;
244  }
245 
247  {
248  guard_t guard( m_mutex );
249  if (m_parentLink.isValid()) {
250  if (m_parentLink->isDecoration (auxid)) {
251  return true;
252  }
253  }
254  return m_store->isDecoration (auxid);
255  }
256 
259  size_t size,
260  size_t capacity ) {
261 
262  guard_t guard( m_mutex );
263 
264  // Check if we already have this variable by any chance.
265  const void* cptr = m_store->getData( auxid );
266 
267  // If the parent has such a variable, then we need to check one more
268  // thing. If it's a decoration on the parent, then we should be allowed
269  // to override it in this (possibly locked) shallow copy. But let's leave
270  // the logic of this up to the parent.
271  if( m_locked && m_parentLink.isValid() &&
272  ( m_parentLink->getAuxIDs().count( auxid ) > 0 ) )
273  {
274  if (!m_parentLink->isDecoration (auxid)) {
275  throw SG::ExcStoreLocked (auxid);
276  }
277  }
278 
279  // If we got this far without any exception, then let the internal store
280  // try to provide the decoration for us:
281  const size_t nids = m_store->getAuxIDs().size();
282  void* result = m_store->getDecoration( auxid, size, capacity );
283  if( result && ( nids != m_store->getAuxIDs().size() ) ) {
284  remakeAuxIDs();
285  }
286 
287  // If we already had this variable before, then don't try to overwrite it
288  // with the parent's payload, and finish here already.
289  if( cptr != nullptr ) {
290  return result;
291  }
292 
293  // If the parent doesn't have this variable, then we're done.
294  if( ! m_parentLink.isValid() ) {
295  return result;
296  }
297  const void* pptr = m_parentLink->getData( auxid );
298  if( pptr == nullptr ) {
299  return result;
300  }
301 
302  // If the variable does exist in the parent, then copy it over to this
303  // store before returning.
304 
305  // Get the registry.
307 
308  // Get the type of this variable.
309  const std::type_info* type = reg.getType( auxid );
310  if( type == nullptr ) {
311  std::ostringstream message;
312  message << "Couldn't find the type of auxiliary ID " << auxid;
313  throw std::runtime_error( message.str() );
314  }
315 
316  // And the allocator type for this variable.
317  const std::type_info* allocType = reg.getAllocType( auxid );
318  if( allocType == nullptr ) {
319  std::ostringstream message;
320  message << "Couldn't find the allocator type of auxiliary ID " << auxid;
321  throw std::runtime_error( message.str() );
322  }
323 
324  // Get the vector factory of this variable.
325  const SG::IAuxTypeVectorFactory* factory =
327  if( factory == nullptr ) {
328  std::ostringstream message;
329  message << "Couldn't find a factory for type " << type->name();
330  throw std::runtime_error( message.str() );
331  }
332 
333  // Copy each element of the parent's decoration.
334  factory->copy( auxid,
335  SG::AuxVectorInterface( *this ), 0,
337 
338  // Now we're done.
339  return result;
340  }
341 
342 
345  {
346  guard_t guard (m_mutex);
347  m_locked = true;
348  m_store->lock();
349  }
350 
351 
354  {
355  guard_t guard (m_mutex);
356  m_store->lockDecoration (auxid);
357  m_auxidsValid = false;
358  }
359 
360  size_t ShallowAuxContainer::size() const {
361 
362  guard_t guard( m_mutex );
363  size_t sz = m_store->size();
364  if( sz > 0 ) {
365  return sz;
366  }
367  if( m_parentLink.isValid() ) {
368  return m_parentLink->size();
369  }
370  return 0;
371  }
372 
375  {
376  guard_t guard (m_mutex);
377  bool ret = m_store->clearDecorations();
378  if (ret) {
379  remakeAuxIDs();
380  }
381  return ret;
382  }
383 
384 
385  //
387 
389  //
390  // Implementation of the SG::IAuxStore interface
391  //
392 
394  size_t capacity ) {
395 
396  guard_t guard (m_mutex);
397 
398  // Check if we already have this variable by any chance.
399  const void* cptr = m_store->getData( auxid );
400 
401  // Create the variable in the dynamic store:
402  void* ptr = m_store->getData( auxid, size, capacity );
403 
404  remakeAuxIDs();
405 
406  // If in some weird way we already had this variable before, then don't
407  // try to overwrite it with the parent's payload, and finish here already.
408  if( cptr != nullptr ) {
409  return ptr;
410  }
411 
412  // If the parent doesn't have this variable, then we're done already:
413  if( ! m_parentLink.isValid() ) {
414  return ptr;
415  }
416  const void* pptr = m_parentLink->getData( auxid );
417  if( ! pptr ) {
418  return ptr;
419  }
420 
421  // If the variable does exist in the parent, then copy it over to this
422  // store before returning.
423 
424  // Get the registry:
426 
427  // Get the type of this variable:
428  const std::type_info* type = reg.getType( auxid );
429  if( type == nullptr ) {
430  std::ostringstream message;
431  message << "Couldn't find the type of auxiliary ID " << auxid;
432  throw std::runtime_error( message.str() );
433  }
434 
435  // And the allocator type for this variable.
436  const std::type_info* allocType = reg.getAllocType( auxid );
437  if( allocType == nullptr ) {
438  std::ostringstream message;
439  message << "Couldn't find the allocator type of auxiliary ID " << auxid;
440  throw std::runtime_error( message.str() );
441  }
442 
443  // First let's get the vector factory of this variable:
444  const SG::IAuxTypeVectorFactory* factory =
446  if( factory == nullptr ) {
447  std::ostringstream message;
448  message << "Couldn't find a factory for type " << type->name();
449  throw std::runtime_error( message.str() );
450  }
451 
452  // Copy each element of the parent's decoration:
453  factory->copy( auxid,
454  SG::AuxVectorInterface( *this ), 0,
456 
457  // Now we're done:
458  return ptr;
459  }
460 
463 
464  // Only the variables in the dynamic store are writable. Maybe not
465  // even all of those...
466  return m_store->getWritableAuxIDs();
467  }
468 
470  {
471  if (size == this->size()) {
472  return false;
473  }
474  // Nope, not allowed...
475  throw std::runtime_error( "Trying to call resize on a shallow copy "
476  "container" );
477  }
478 
479  void ShallowAuxContainer::reserve( size_t /*size*/ ) {
480 
481  // Nope, not allowed...
482  throw std::runtime_error( "Trying to call reserve on a shallow copy "
483  "container" );
484  }
485 
486  void ShallowAuxContainer::shift( size_t /*pos*/, ptrdiff_t /*offs*/ ) {
487 
488  // Nope, not allowed...
489  throw std::runtime_error( "Trying to call shift on a shallow copy "
490  "container" );
491  }
492 
493  bool ShallowAuxContainer::insertMove( size_t /*pos*/,
494  IAuxStore& /*other*/,
495  const SG::auxid_set_t& /*ignore*/) {
496 
497  // Nope, not allowed...
498  throw std::runtime_error( "Trying to call insertMove on a shallow copy "
499  "container" );
500  }
501 
502  //
504 
506  //
507  // Implementation of the SG::IAuxStoreIO interface
508  //
509 
510  const void* ShallowAuxContainer::getIOData( auxid_t auxid ) const {
511 
512  guard_t guard (m_mutex);
513  // Do we have it?
514  if( m_storeIO && m_store->getAuxIDs().test (auxid)) {
515  return m_storeIO->getIOData( auxid );
516  }
517 
518  // Do we have a parent that has it?
519  const SG::IAuxStoreIO* parentIO = m_parentIO;
520  if( ( parentIO == nullptr ) && m_parentLink.isValid() ) {
521  parentIO =
522  dynamic_cast< const SG::IAuxStoreIO* >( m_parentLink.cptr() );
523  }
524  if( parentIO ) {
525  return parentIO->getIOData( auxid );
526  }
527 
528  // If not, then where did this variable come from?!?
529  std::cerr << "ERROR xAOD::ShallowAuxContainer::getIOData Unknown "
530  << "variable ("
532  << ") requested" << std::endl;
533  return nullptr;
534  }
535 
536  const std::type_info* ShallowAuxContainer::getIOType( auxid_t auxid ) const {
537 
538  guard_t guard (m_mutex);
539  // Do we have it?
540  if( m_storeIO && m_store->getAuxIDs().test (auxid)) {
541  return m_storeIO->getIOType( auxid );
542  }
543 
544  // Do we have a parent that has it?
545  const SG::IAuxStoreIO* parentIO = m_parentIO;
546  if( ( parentIO == nullptr ) && m_parentLink.isValid() ) {
547  parentIO =
548  dynamic_cast< const SG::IAuxStoreIO* >( m_parentLink.cptr() );
549  }
550  if( parentIO ) {
551  return parentIO->getIOType( auxid );
552  }
553 
554  // If not, then where did this variable come from?!?
555  std::cerr << "ERROR xAOD::ShallowAuxContainer::getIOType Unknown "
556  << "variable ("
558  << ") requested" << std::endl;
559  return nullptr;
560  }
561 
564 
565  if( m_shallowIO ) {
566  if( m_storeIO ) {
567  return m_store->getAuxIDs();
568  } else {
569  static const auxid_set_t dummy (0);
570  return dummy;
571  }
572  } else {
573  return getAuxIDs();
574  }
575  }
576 
579 
580  if( m_shallowIO ) {
581  if( m_storeIO ) {
583  } else {
584  return auxid_set_t();
585  }
586  } else {
588  }
589  }
590 
591 
592  //
594 
595  const char* ShallowAuxContainer::name() const {
596 
597  return m_name.c_str();
598  }
599 
600  void ShallowAuxContainer::setName( const char* name ) {
601 
602  m_name = name;
603  return;
604  }
605 
608  if( m_parentLink.isValid() ) {
609  ids.insert (m_parentLink->getAuxIDs());
610  }
611  m_auxids = ids;
612 
613  auxid_set_t decors = m_store->getDecorIDs();
614  if( m_parentLink.isValid() ) {
615  ids.insert (m_parentLink->getDecorIDs());
616  }
617  m_decorids = decors;
618 
619  m_auxidsValid = true;
620  }
621 
622 } // namespace xAOD
SG::AuxTypeRegistry::getFactory
const IAuxTypeVectorFactory * getFactory(const std::type_info &ti, const std::type_info &ti_alloc)
Return the vector factory for a given vector element type.
Definition: AuxTypeRegistry.cxx:1110
SGTest::store
TestStore store
Definition: TestStore.cxx:23
xAOD::name
name
Definition: TriggerMenuJson_v1.cxx:29
xAOD::ShallowAuxContainer::operator=
ShallowAuxContainer & operator=(const ShallowAuxContainer &rhs)
Assignment operator.
Definition: ShallowAuxContainer.cxx:85
SG::IConstAuxStore::getData
virtual const void * getData(SG::auxid_t auxid) const =0
Return the data vector for one aux data item.
SG::IConstAuxStore::lockDecoration
virtual void lockDecoration(SG::auxid_t auxid)=0
Lock a decoration.
fitman.sz
sz
Definition: fitman.py:527
get_generator_info.result
result
Definition: get_generator_info.py:21
CxxUtils::ConcurrentBitset::count
bit_t count() const
Count the number of 1 bits in the set.
xAOD::ShallowAuxContainer::lock
virtual void lock() override
Lock the container.
Definition: ShallowAuxContainer.cxx:344
SG
Forward declaration.
Definition: CaloCellPacker_400_500.h:32
SG::IConstAuxStore::getVector
virtual const IAuxTypeVector * getVector(SG::auxid_t auxid) const =0
Return vector interface for one aux data item.
xAOD::ShallowAuxContainer::getIOType
virtual const std::type_info * getIOType(auxid_t auxid) const override
Return the type of the data to be stored for one aux data item.
Definition: ShallowAuxContainer.cxx:536
L1CaloPhase1Monitoring.standalone
standalone
Definition: L1CaloPhase1Monitoring.py:112
SG::AuxTypeRegistry::instance
static AuxTypeRegistry & instance()
Return the singleton registry instance.
Definition: AuxTypeRegistry.cxx:639
AuxVectorInterface.h
Make an AuxVectorData object from either a raw vector or an aux store.
xAOD::ShallowAuxContainer::getDynamicAuxIDs
virtual const auxid_set_t & getDynamicAuxIDs() const override
Get the types(names) of variables created dynamically.
Definition: ShallowAuxContainer.cxx:563
xAOD::ShallowAuxContainer::insertMove
virtual bool insertMove(size_t pos, IAuxStore &other, const SG::auxid_set_t &ignore) override
Insert contents of another store via move.
Definition: ShallowAuxContainer.cxx:493
xAOD::ShallowAuxContainer::parent
const DataLink< SG::IConstAuxStore > & parent() const
Get the parent store.
Definition: ShallowAuxContainer.cxx:117
xAOD::ShallowAuxContainer::ShallowAuxContainer
ShallowAuxContainer(bool standalone=false)
Default constructor.
Definition: ShallowAuxContainer.cxx:31
SG::AuxTypeRegistry::getName
std::string getName(SG::auxid_t auxid) const
Return the name of an aux data item.
Definition: AuxTypeRegistry.cxx:881
SG::ExcStoreLocked
Exception — Attempted to modify auxiliary data in a locked store.
Definition: Control/AthContainers/AthContainers/exceptions.h:183
xAOD::ShallowAuxContainer::getVector
virtual const SG::IAuxTypeVector * getVector(SG::auxid_t auxid) const override final
Return vector interface for one aux data item.
Definition: ShallowAuxContainer.cxx:196
CSV_InDetExporter.new
new
Definition: CSV_InDetExporter.py:145
exceptions.h
Exceptions that can be thrown from AthContainers.
xAOD::ShallowAuxContainer::reserve
virtual void reserve(size_t size) override
Reserve a given size for the arrays.
Definition: ShallowAuxContainer.cxx:479
xAOD::ShallowAuxContainer
Class creating a shallow copy of an existing auxiliary container.
Definition: ShallowAuxContainer.h:54
xAOD::ShallowAuxContainer::guard_t
AthContainers_detail::lock_guard< mutex_t > guard_t
Definition: ShallowAuxContainer.h:202
SG::AuxTypeRegistry::getAllocType
const std::type_info * getAllocType(SG::auxid_t auxid) const
Return the type of the vector allocator.
Definition: AuxTypeRegistry.cxx:964
athena.value
value
Definition: athena.py:124
xAOD::ShallowAuxContainer::name
const char * name() const
Get the name of the container instance.
Definition: ShallowAuxContainer.cxx:595
xAOD
ICaloAffectedTool is abstract interface for tools checking if 4 mom is in calo affected region.
Definition: ICaloAffectedTool.h:24
xAOD::ShallowAuxContainer::lockDecoration
virtual void lockDecoration(SG::auxid_t auxid) override
Lock a decoration.
Definition: ShallowAuxContainer.cxx:353
dbg::ptr
void * ptr(T *p)
Definition: SGImplSvc.cxx:74
xAOD::ShallowAuxContainer::m_selection
AuxSelection m_selection
Dynamic attributes selection implementation.
Definition: ShallowAuxContainer.h:182
ShallowAuxContainer.h
xAOD::ShallowAuxContainer::m_shallowIO
bool m_shallowIO
Flag for whether to do "shallow IO" or not.
Definition: ShallowAuxContainer.h:198
SG::IAuxStoreIO::getIOType
virtual const std::type_info * getIOType(SG::auxid_t auxid) const =0
Return the type of the data to be stored for one aux data item.
xAOD::ShallowAuxContainer::setParent
void setParent(const DataLink< SG::IConstAuxStore > &link)
Set the parent store.
Definition: ShallowAuxContainer.cxx:123
xAOD::ShallowAuxContainer::size
virtual size_t size() const override
Get the size of the container.
Definition: ShallowAuxContainer.cxx:360
ReweightUtils.message
message
Definition: ReweightUtils.py:15
SG::IConstAuxStore::size
virtual size_t size() const =0
Return the number of elements in the store.
xAOD::ShallowAuxContainer::m_ownsStore
bool m_ownsStore
Flag deciding if the object owns the dynamic store or not.
Definition: ShallowAuxContainer.h:189
SG::IAuxStoreIO
Interface providing I/O for a generic auxiliary store.
Definition: IAuxStoreIO.h:44
SG::AuxTypeRegistry
Handle mappings between names and auxid_t.
Definition: AuxTypeRegistry.h:61
python.setupRTTAlg.size
int size
Definition: setupRTTAlg.py:39
xAOD::ShallowAuxContainer::setShallowIO
void setShallowIO(bool value)
Set whether only the overriden parameters should be written out.
Definition: ShallowAuxContainer.cxx:137
xAOD::ShallowAuxContainer::getDecoration
virtual void * getDecoration(auxid_t auxid, size_t size, size_t capacity) override
Return the data vector for one aux data decoration item.
Definition: ShallowAuxContainer.cxx:258
xAOD::ShallowAuxContainer::m_name
std::string m_name
Name of the container in memory. Set externally.
Definition: ShallowAuxContainer.h:212
SG::auxid_t
size_t auxid_t
Identifier for a particular aux data item.
Definition: AuxTypes.h:27
SG::AuxTypeRegistry::getType
const std::type_info * getType(SG::auxid_t auxid) const
Return the type of an aux data item.
Definition: AuxTypeRegistry.cxx:908
xAOD::ShallowAuxContainer::m_parentLink
DataLink< SG::IConstAuxStore > m_parentLink
Link to the parent object.
Definition: ShallowAuxContainer.h:194
CxxUtils::ConcurrentBitset::size
bit_t size() const
Count the number of 1 bits in the set.
SG::IConstAuxStore::clearDecorations
virtual bool clearDecorations()=0
Clear all decorations.
xAOD::ShallowAuxContainer::m_mutex
mutex_t m_mutex
Definition: ShallowAuxContainer.h:203
xAOD::ShallowAuxContainer::getDecorIDs
virtual const auxid_set_t & getDecorIDs() const override
Get the types(names) of decorations handled by this container.
Definition: ShallowAuxContainer.cxx:237
SG::IAuxTypeVectorFactory
Interface for factory objects that create vectors.
Definition: IAuxTypeVectorFactory.h:50
xAOD::ShallowAuxContainer::m_storeIO
SG::IAuxStoreIO * m_storeIO
The IO interface to the internal auxiliary store.
Definition: ShallowAuxContainer.h:187
test_pyathena.parent
parent
Definition: test_pyathena.py:15
xAOD::ShallowAuxContainer::getStore
virtual SG::IAuxStore * getStore() override
Get the currently used internal store object.
Definition: ShallowAuxContainer.cxx:149
python.xAODType.dummy
dummy
Definition: xAODType.py:4
SG::IConstAuxStore::getDecoration
virtual void * getDecoration(auxid_t auxid, size_t size, size_t capacity)=0
Return the data vector for one aux data decoration item.
xAOD::ShallowAuxContainer::shallowIO
bool shallowIO() const
Check whether only the overriden parameters will be written out or not.
Definition: ShallowAuxContainer.cxx:132
SG::IAuxTypeVectorFactory::copy
virtual void copy(SG::auxid_t auxid, AuxVectorData &dst, size_t dst_index, const AuxVectorData &src, size_t src_index, size_t n) const =0
Copy elements between vectors.
xAOD::ShallowAuxContainer::getIOData
virtual const void * getIOData(auxid_t auxid) const override
Get a pointer to the data being stored for one aux data item.
Definition: ShallowAuxContainer.cxx:510
xAOD::ShallowAuxContainer::shift
virtual void shift(size_t pos, ptrdiff_t offs) override
Shift the contents of the stored arrays.
Definition: ShallowAuxContainer.cxx:486
xAOD::ShallowAuxContainer::getWritableAuxIDs
virtual const auxid_set_t & getWritableAuxIDs() const override
Return a set of writable data identifiers.
Definition: ShallowAuxContainer.cxx:462
xAOD::ShallowAuxContainer::getAuxIDs
virtual const auxid_set_t & getAuxIDs() const override
Get the types(names) of variables handled by this container.
Definition: ShallowAuxContainer.cxx:227
python.subdetectors.mmg.ids
ids
Definition: mmg.py:8
xAOD::ShallowAuxContainer::isDecoration
virtual bool isDecoration(auxid_t auxid) const override
Test if a variable is a decoration.
Definition: ShallowAuxContainer.cxx:246
xAOD::ShallowAuxContainer::m_parentIO
const SG::IAuxStoreIO * m_parentIO
Optional pointer to the IO interface of the parent object.
Definition: ShallowAuxContainer.h:196
xAOD::ShallowAuxContainer::m_locked
bool m_locked
Flag keeping track of whether this object is locked or not.
Definition: ShallowAuxContainer.h:191
SG::IAuxStoreIO::getIOData
virtual const void * getIOData(SG::auxid_t auxid) const =0
Return a pointer to the data to be stored for one aux data item.
xAOD::ShallowAuxContainer::setName
void setName(const char *name)
Set the name of the container instance.
Definition: ShallowAuxContainer.cxx:600
SG::IAuxStore::getWritableAuxIDs
virtual const SG::auxid_set_t & getWritableAuxIDs() const =0
Return a set of identifiers for writable data items in this store.
SG::IAuxStore
Interface for non-const operations on an auxiliary store.
Definition: IAuxStore.h:48
python.PyAthena.v
v
Definition: PyAthena.py:154
SG::AuxVectorInterface
Make an AuxVectorData object from either a raw array or an aux store.
Definition: AuxVectorInterface.h:33
SG::IAuxStore::getData
virtual void * getData(auxid_t auxid, size_t size, size_t capacity)=0
Return the data vector for one aux data item.
IAuxTypeVectorFactory.h
Interface for factory objects that create vectors.
python.CaloScaleNoiseConfig.type
type
Definition: CaloScaleNoiseConfig.py:78
SG::IAuxTypeVector
Abstract interface for manipulating vectors of arbitrary types.
Definition: IAuxTypeVector.h:42
SG::IConstAuxStore::getDecorIDs
virtual const SG::auxid_set_t & getDecorIDs() const =0
Return a set of identifiers for decorations in this store.
AuxTypeRegistry.h
Handle mappings between names and auxid_t.
SG::IConstAuxStore::lock
virtual void lock()=0
Lock the container.
SG::auxid_set_t
A set of aux data identifiers.
Definition: AuxTypes.h:47
xAOD::ShallowAuxContainer::auxid_set_t
SG::auxid_set_t auxid_set_t
The aux ID set type definition.
Definition: ShallowAuxContainer.h:60
xAOD::ShallowAuxContainer::m_store
SG::IAuxStore * m_store
Internal dynamic auxiliary store object.
Definition: ShallowAuxContainer.h:185
SG::IConstAuxStore::isDecoration
virtual bool isDecoration(auxid_t auxid) const =0
Test if a particular variable is tagged as a decoration.
xAOD::AuxSelection::getSelectedAuxIDs
virtual SG::auxid_set_t getSelectedAuxIDs(const SG::auxid_set_t &fullset) const
Return which variables were selected to be written out.
Definition: AuxSelection.cxx:62
xAOD::ShallowAuxContainer::setStore
virtual void setStore(SG::IAuxStore *store) override
Set a different internal store object.
Definition: ShallowAuxContainer.cxx:159
xAOD::ShallowAuxContainer::auxid_t
SG::auxid_t auxid_t
The aux ID type definition.
Definition: ShallowAuxContainer.h:58
AuxStoreInternal.h
An auxiliary data store that holds data internally.
xAOD::ShallowAuxContainer::getData
virtual const void * getData(auxid_t auxid) const override
Get a pointer to a given array.
Definition: ShallowAuxContainer.cxx:187
xAOD::ShallowAuxContainer::getSelectedAuxIDs
virtual auxid_set_t getSelectedAuxIDs() const override
Get the IDs of the selected dynamic Aux variables (for writing)
Definition: ShallowAuxContainer.cxx:578
xAOD::ShallowAuxContainer::~ShallowAuxContainer
~ShallowAuxContainer()
Destructor.
Definition: ShallowAuxContainer.cxx:77
xAOD::ShallowAuxContainer::resize
virtual bool resize(size_t size) override
Resize the arrays to a given size.
Definition: ShallowAuxContainer.cxx:469
xAOD::ShallowAuxContainer::remakeAuxIDs
void remakeAuxIDs() const
Definition: ShallowAuxContainer.cxx:606
SG::IConstAuxStore::getAuxIDs
virtual const SG::auxid_set_t & getAuxIDs() const =0
Return a set of identifiers for existing data items in this store.
CxxUtils::ConcurrentBitset::test
bool test(bit_t bit) const
Test to see if a bit is set.
xAOD::ShallowAuxContainer::clearDecorations
virtual bool clearDecorations() override
Clear all decorations.
Definition: ShallowAuxContainer.cxx:374