Algorithm for creating test aux data.
More...
#include <xAODTestWriteCInfoTool.h>
Algorithm for creating test aux data.
Definition at line 34 of file xAODTestWriteCInfoTool.h.
◆ xAODTestWriteCInfoTool()
DMTest::xAODTestWriteCInfoTool::xAODTestWriteCInfoTool |
( |
const std::string & |
type, |
|
|
const std::string & |
name, |
|
|
const IInterface * |
parent |
|
) |
| |
Constructor.
- Parameters
-
type | The tool type. |
name | The tool name. |
parent | The tool's parent. |
Definition at line 29 of file xAODTestWriteCInfoTool.cxx.
◆ doit()
StatusCode DMTest::xAODTestWriteCInfoTool::doit |
( |
const EventContext & |
ctx | ) |
const |
|
overridevirtual |
Tool event processing.
Definition at line 56 of file xAODTestWriteCInfoTool.cxx.
58 unsigned int count = ctx.eventID().event_number() + 1;
62 auto cinfo = std::make_unique<DMTest::C>();
63 auto info_store = std::make_unique<DMTest::CInfoAuxContainer>();
64 cinfo->setStore (info_store.get());
66 static const C::Accessor<int> anInt2 (
"anInt2");
67 static const C::Accessor<ElementLink<DMTest::CVec> > cEL (
"cEL");
69 cinfo->setAnInt (
count * 1000);
70 cinfo->setAFloat ((
float)
count * 0.1);
71 anInt2(*cinfo) =
count * 2000;
74 cEL(*cinfo).toIndexedElement (*cvec,
count % cvec->size());
78 std::unique_ptr<const DMTest::C> cinfo_c (std::move (cinfo));
79 std::unique_ptr<const DMTest::CInfoAuxContainer> info_store_c (std::move (info_store));
80 if (cinfoH.put (std::move(cinfo_c), std::move(info_store_c)) ==
nullptr) {
82 return StatusCode::FAILURE;
85 return StatusCode::SUCCESS;
◆ initialize()
StatusCode DMTest::xAODTestWriteCInfoTool::initialize |
( |
| ) |
|
|
overridevirtual |
◆ m_cinfoKey
◆ m_cvecKey
The documentation for this class was generated from the following files: