23 return StatusCode::SUCCESS;
29 return StatusCode::SUCCESS;
37 if (!inputJetsHandle.
isValid() ) {
39 return StatusCode::FAILURE;
46 std::unique_ptr<JetContainer> copiedjets(shallowcopy.first);
47 std::unique_ptr<xAOD::ShallowAuxContainer> shallowaux(shallowcopy.second);
49 if(copiedjets.get() ==
nullptr || shallowaux.get() ==
nullptr) {
51 return StatusCode::FAILURE;
53 ATH_CHECK( jetsOut.
record(std::move(copiedjets), std::move(shallowaux)) );
55 return StatusCode::SUCCESS;
#define ATH_CHECK
Evaluate an expression and check for errors.
Gaudi::Details::PropertyBase & declareProperty(Gaudi::Property< T, V, H > &t)
An algorithm that can be simultaneously executed in multiple threads.
StatusCode initialize() override
SG::ReadHandleKey< JetContainer > m_jetInContainerKey
StatusCode execute(const EventContext &ctx) const override
StatusCode finalize() override
L1JetCopyAlgorithm(const std::string &name, ISvcLocator *pSvcLocator)
SG::WriteHandleKey< JetContainer > m_jetOutContainerKey
virtual bool isValid() override final
Can the handle be successfully dereferenced?
StatusCode record(std::unique_ptr< T > data)
Record a const object to the store.
std::pair< std::unique_ptr< T >, std::unique_ptr< ShallowAuxContainer > > shallowCopyContainer(const T &cont, const EventContext &ctx)
Function making a shallow copy of a constant container.