ATLAS Offline Software
AuxStoreTest.h
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2017 CERN for the benefit of the ATLAS collaboration
3 */
4 
5 
6 #ifndef APRTEST_AUXSTORE
7 #define APRTEST_AUXSTORE
8 
11 
12 
13 namespace APRTest
14 {
15 
17  {
18  IAuxStore* m_extra_store = 0;
19  public:
20  int m_data = 0;
21 
22  virtual ~AuxStore() {}
23 
24 
25  virtual void setStore( IAuxStore* store ) override {
27  }
28 
30 
31  virtual void* getData(SG::auxid_t auxid, size_t size, size_t capacity ) override;
32  virtual const void* getData(SG::auxid_t auxid ) const override;
33 
34  virtual IAuxStore* getStore() override { return (IAuxStore*)this; }
35  virtual const IAuxStore* getStore() const override { return (IAuxStore*)this; }
36 
37  virtual AuxStoreType getStoreType() const override { return AST_ContainerStore; }
38 
39  virtual size_t size() const override
41 
42 
43  };
44 
45  inline
46  void* AuxStore::getData(SG::auxid_t auxid, size_t size, size_t capacity )
47  {
48  return m_extra_store? m_extra_store->getData( auxid, size, capacity)
49  : SG::AuxStoreInternal::getData( auxid, size, capacity);
50  }
51 
52  inline
53  const void* AuxStore::getData(SG::auxid_t auxid) const
54  {
55  return m_extra_store? m_extra_store->getData( auxid)
57  }
58 
59 
61  public:
62  AClassWithDict(int v=54321) { _val=v; };
63  int _val;
64  };
65 
66 }
67 
68 #endif
store
StoreGateSvc * store
Definition: fbtTestBasics.cxx:69
IAuxStoreHolder.h
APRTest::AuxStore::size
virtual size_t size() const override
Return the number of elements in the store.
Definition: AuxStoreTest.h:39
SG::AuxStoreInternal::getData
virtual const void * getData(SG::auxid_t auxid) const override
Return the data vector for one aux data item.
Definition: AuxStoreInternal.cxx:83
APRTest::AClassWithDict::_val
int _val
Definition: AuxStoreTest.h:62
APRTest::AClassWithDict
Definition: AuxStoreTest.h:60
APRTest::AuxStore::setStore
virtual void setStore(IAuxStore *store) override
Definition: AuxStoreTest.h:25
APRTest::AuxStore::getData
virtual void * getData(SG::auxid_t auxid, size_t size, size_t capacity) override
Return the data vector for one aux data item.
Definition: AuxStoreTest.h:46
APRTest
Definition: AuxStoreTest.h:14
python.setupRTTAlg.size
int size
Definition: setupRTTAlg.py:39
SG::IAuxStoreHolder::AuxStoreType
AuxStoreType
Type of the auxiliary store.
Definition: IAuxStoreHolder.h:66
SG::auxid_t
size_t auxid_t
Identifier for a particular aux data item.
Definition: AuxTypes.h:27
APRTest::AuxStore::~AuxStore
virtual ~AuxStore()
Definition: AuxStoreTest.h:22
APRTest::AuxStore::getStore
virtual const IAuxStore * getStore() const override
Definition: AuxStoreTest.h:35
APRTest::AuxStore::getStoreType
virtual AuxStoreType getStoreType() const override
Return the type of the store object.
Definition: AuxStoreTest.h:37
SG::AuxStoreInternal::size
virtual size_t size() const override
Return the number of elements in the store.
Definition: AuxStoreInternal.cxx:576
APRTest::AuxStore::getStore
virtual IAuxStore * getStore() override
Return the pointer to the store object currently in use.
Definition: AuxStoreTest.h:34
APRTest::AuxStore::m_extra_store
IAuxStore * m_extra_store
Definition: AuxStoreTest.h:18
APRTest::AuxStore::m_data
int m_data
Definition: AuxStoreTest.h:20
SG::AuxStoreInternal
An auxiliary data store that holds data internally.
Definition: AuxStoreInternal.h:43
python.PyAthena.v
v
Definition: PyAthena.py:157
APRTest::AuxStore
Definition: AuxStoreTest.h:17
APRTest::AClassWithDict::AClassWithDict
AClassWithDict(int v=54321)
Definition: AuxStoreTest.h:62
AuxStoreInternal.h
An auxiliary data store that holds data internally.
SG::IAuxStoreHolder
Interface for objects taking part in direct ROOT I/O.
Definition: IAuxStoreHolder.h:36
SG::IAuxStoreHolder::AST_ContainerStore
@ AST_ContainerStore
The store describes a container.
Definition: IAuxStoreHolder.h:68