21#define CHECK_OPTION(ret) \
24 ATH_MSG_ERROR("setOption failed"); \
25 return StatusCode::FAILURE; \
39 return StatusCode::SUCCESS;
48 unsigned int count = ctx.eventID().event_number() + 1;
50 auto coll = std::make_unique<DMTest::PVec>();
51 auto store = std::make_unique<DMTest::PAuxContainer>();
52 coll->setStore (store.get());
58 if (
count == 5) nent = 0;
59 for (
int i=0; i < nent; i++) {
62 p.setPInt (
count * 500 + i+1);
63 p.setPFloat (i + (
float)
count * 0.01);
66 for (
int j=0; j<i; j++)
67 pvi.push_back (j + i*10 +
count*100 - 500);
70 std::vector<float> pvf;
71 for (
int j=0; j<i; j++)
72 pvf.push_back ((
float)j*0.1 + (
float)i*0.01 + (
float)
count*0.001 - 0.5);
73 p.setPVFloat (std::move (pvf));
75 dpInt1(p) =
count*50 + i+1;
79 for (
int j=0; j<i; j++)
80 pvf.push_back ((
float)i*0.1 + (
float)
count*0.01 + (
float)j*0.001);
81 dpvFloat(p) = std::move(pvf);
85 CHECK(
pvec.record (std::move(coll), std::move(store)) );
92 return StatusCode::SUCCESS;
#define ATH_CHECK
Evaluate an expression and check for errors.
Hold information about an option setting request.
Helpers for checking error return status codes and reporting errors.
#define CHECK(...)
Evaluate an expression and check for errors.
Helper class to provide type-safe access to aux data.
Class used for testing xAOD data reading/writing with packed containers.
#define CHECK_OPTION(ret)
Class used for testing xAOD data reading/writing with packed containers.
Class used for testing xAOD data reading/writing with packed containers.
SG::WriteHandleKey< DMTest::PVec > m_pvecKey
virtual StatusCode execute(const EventContext &ctx) const override
Algorithm event processing.
virtual StatusCode initialize() override
Algorithm initialization; called at the beginning of the job.
Hold information about an option setting request.
Helper class to provide type-safe access to aux data.
int count(std::string s, const std::string ®x)
count how many occurances of a regx are in a string