ATLAS Offline Software
Loading...
Searching...
No Matches
RODHeaderCnvTool.cxx
Go to the documentation of this file.
1/*
2 Copyright (C) 2002-2021 CERN for the benefit of the ATLAS collaboration
3*/
4
5
6// EDM include(s):
10
11// Local include(s):
12#include "RODHeaderCnvTool.h"
13
14namespace xAODMaker {
15
17 const std::string& name,
18 const IInterface* parent )
19 : AthAlgTool( type, name, parent ) {
20
21 // Declare the interface(s) provided by the tool:
22 declareInterface< IRODHeaderCnvTool >( this );
23 }
24
36
37 // A small sanity check. The output container should really be empty...
38 if( !xaod->empty() ) {
39 ATH_MSG_WARNING( "The output xAOD container is not empty (size=="
40 << xaod->size() << ")" );
41 }
42
43 // Loop over the ESD objects:
46 for( ; itr != end; ++itr ) {
47
49 xaod->push_back( x );
50 x->initialize((*itr)->version(), (*itr)->sourceID(), (*itr)->run(),
51 (*itr)->l1ID(), (*itr)->bunchCrossing(), (*itr)->l1TriggerType(),
52 (*itr)->detEventType(), (*itr)->statusWords(), (*itr)->payloadSize()
53 );
54 }
55
56 // Return gracefully:
57 return StatusCode::SUCCESS;
58 }
59
60} // namespace xAODMaker
#define ATH_MSG_WARNING(x)
DataVector< LVL1::RODHeader > RODHeaderCollection
Container class for RODHeaders.
#define x
AthAlgTool(const std::string &type, const std::string &name, const IInterface *parent)
Constructor with parameters:
DataModel_detail::const_iterator< DataVector > const_iterator
Definition DataVector.h:838
value_type push_back(value_type pElem)
Add an element to the end of the collection.
const_iterator end() const noexcept
Return a const_iterator pointing past the end of the collection.
const_iterator begin() const noexcept
Return a const_iterator pointing at the beginning of the collection.
size_type size() const noexcept
Returns the number of elements in the collection.
bool empty() const noexcept
Returns true if the collection is empty.
virtual StatusCode convert(const DataVector< LVL1::RODHeader > *esd, xAOD::RODHeaderContainer *xaod) override
Function that fills an existing xAOD::EmTauRoIContainer.
RODHeaderCnvTool(const std::string &type, const std::string &name, const IInterface *parent)
Regular AlgTool constructor.
RODHeaderContainer_v2 RODHeaderContainer
Define the latest version of the RODHeader container.
RODHeader_v2 RODHeader
Define the latest version of the RODHeader class.