28 ISvcLocator *pSvcLocator)
61 return StatusCode::SUCCESS;
71 std::ostringstream
ss;
73 if (!cvecDecor.
isPresent())
return StatusCode::FAILURE;
74 for (
const C* celt : *cvecDecor) {
75 ss <<
" " << cvecDecor(*celt);
82 if (!cinfoDecor.
isPresent())
return StatusCode::FAILURE;
88 if (!cinfoBaseDecor.
isPresent())
return StatusCode::FAILURE;
94 if (!objDecor.
isPresent())
return StatusCode::FAILURE;
100 testKey = testKey.
key() +
"_test";
102 if (!cinfoDecorTest.
isPresent())
return StatusCode::FAILURE;
105 return StatusCode::SUCCESS;
114 return StatusCode::SUCCESS;
#define ATH_CHECK
Evaluate an expression and check for errors.
Class used for testing xAOD data reading/writing.
Class used for testing xAOD data reading/writing.
Helpers for checking error return status codes and reporting errors.
Handle class for reading a decoration on an object.
Gaudi::Details::PropertyBase & declareProperty(Gaudi::Property< T, V, H > &t)
An algorithm that can be simultaneously executed in multiple threads.
xAODTestReadDecor(const std::string &name, ISvcLocator *pSvcLocator)
Constructor.
std::string m_readPrefix
Parameter: Prefix for names read from SG.
SG::ReadDecorHandleKey< C > m_cinfoDecorKey
virtual StatusCode execute(const EventContext &ctx) const override
Algorithm event processing.
virtual StatusCode finalize() override
Algorithm finalization; called at the end of the job.
std::string m_decorName
Parameter: Name of the decoration.
virtual StatusCode initialize() override
Algorithm initialization; called at the beginning of the job.
SG::ReadDecorHandleKey< SG::AuxElement > m_objDecorKey
SG::ReadDecorHandleKey< CVec > m_cvecDecorKey
Handles for reading decorations.
std::string m_cvecName
Parameter: Root names of the objects.
SG::ReadDecorHandleKey< C > m_cinfoBaseDecorKey
Property holding a SG store/key/clid/attr name from which a ReadDecorHandle is made.
Handle class for reading a decoration on an object.
bool isPresent() const
Is the referenced container present in SG?
const std::string & key() const
Return the StoreGate ID for the referenced object.
Algorithm to test reading decorations using handles.