ATLAS Offline Software
Loading...
Searching...
No Matches
TrigSpacePointCountsCnvTool.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// $Id:$
6
7// EDM include(s):
11// Local include(s):
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< ITrigSpacePointCountsCnvTool >( this );
23 }
24
25
37
38 // A small sanity check. The output container should really be empty...
39 if( !xaod->empty() ) {
40 ATH_MSG_WARNING( "The output xAOD container is not empty (size=="
41 << xaod->size() << ")" );
42 }
43
44
47
48 ATH_MSG_VERBOSE("AOD TrigSpacePointCountsCollection size:: "<< aod->size());
49
50 for(; tspc_iter != tspc_iter_end; ++tspc_iter){
51 // Add a new muon RoI object to the output:
53 xaod->push_back( xtspc );
54
55 // Now fill it with data:
56 xtspc->setContentsPixelClusEndcapC((*tspc_iter)->pixelClusEndcapC().contents());
57 xtspc->setContentsPixelClusBarrel((*tspc_iter)->pixelClusBarrel().contents());
58 xtspc->setContentsPixelClusEndcapA((*tspc_iter)->pixelClusEndcapA().contents());
59 xtspc->setPixelClusTotBins((*tspc_iter)->pixelClusEndcapC().nbins_x());
60 xtspc->setPixelClusTotMin((*tspc_iter)->pixelClusEndcapC().min_x());
61 xtspc->setPixelClusTotMax((*tspc_iter)->pixelClusEndcapC().max_x());
62 xtspc->setPixelClusSizeBins((*tspc_iter)->pixelClusEndcapC().nbins_y());
63 xtspc->setPixelClusSizeMin((*tspc_iter)->pixelClusEndcapC().min_y());
64 xtspc->setPixelClusSizeMax((*tspc_iter)->pixelClusEndcapC().max_y());
65 xtspc->setSctSpEndcapC((*tspc_iter)->sctSpEndcapC());
66 xtspc->setSctSpBarrel((*tspc_iter)->sctSpBarrel());
67 xtspc->setSctSpEndcapA((*tspc_iter)->sctSpEndcapA());
68
69 ATH_MSG_VERBOSE("AOD vs xAOD pixelClusEndcapC::contents::size:: "<<(*tspc_iter)->pixelClusEndcapC().contents().size()<< " "<<xtspc->contentsPixelClusEndcapC().size() );
70 ATH_MSG_VERBOSE("AOD vs xAOD pixelClusBarrel::contents::size:: "<<(*tspc_iter)->pixelClusBarrel().contents().size()<< " "<<xtspc->contentsPixelClusBarrel().size() );
71 ATH_MSG_VERBOSE("AOD vs xAOD pixelClusEndcapA::contents::size:: "<<(*tspc_iter)->pixelClusEndcapA().contents().size()<< " "<<xtspc->contentsPixelClusEndcapC().size() );
72 ATH_MSG_VERBOSE("AOD vs xAOD pixelClusTotBins:: "<< (*tspc_iter)->pixelClusEndcapC().nbins_x()<< " " <<xtspc->pixelClusTotBins() );
73 ATH_MSG_VERBOSE("AOD vs xAOD pixelClusTotMin:: "<< (*tspc_iter)->pixelClusEndcapC().min_x()<< " " <<xtspc->pixelClusTotMin() );
74 ATH_MSG_VERBOSE("AOD vs xAOD pixelClusTotMax:: "<< (*tspc_iter)->pixelClusEndcapC().max_x()<< " " <<xtspc->pixelClusTotMax() );
75 ATH_MSG_VERBOSE("AOD vs xAOD pixelClusSizeBins:: "<< (*tspc_iter)->pixelClusEndcapC().nbins_y()<< " " <<xtspc->pixelClusSizeBins() );
76 ATH_MSG_VERBOSE("AOD vs xAOD pixelClusSizeMin:: "<< (*tspc_iter)->pixelClusEndcapC().min_y()<< " " <<xtspc->pixelClusSizeMin() );
77 ATH_MSG_VERBOSE("AOD vs xAOD pixelClusSizeMax:: "<< (*tspc_iter)->pixelClusEndcapC().max_y()<< " " <<xtspc->pixelClusSizeMax() );
78 ATH_MSG_VERBOSE("AOD vs xAOD sctSpEndcapC:: "<<(*tspc_iter)->sctSpEndcapC() << " " << xtspc->sctSpEndcapC() );
79 ATH_MSG_VERBOSE("AOD vs xAOD sctSpBarrel:: "<<(*tspc_iter)->sctSpBarrel() << " " << xtspc->sctSpBarrel() );
80 ATH_MSG_VERBOSE("AOD vs xAOD sctSpEndcapA:: "<<(*tspc_iter)->sctSpEndcapA() << " " << xtspc->sctSpEndcapA() );
81 }
82 // Return gracefully:
83 return StatusCode::SUCCESS;
84 }
85
86} // namespace xAODMaker
#define ATH_MSG_VERBOSE(x)
#define ATH_MSG_WARNING(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 TrigSpacePointCountsCollection *aod, xAOD::TrigSpacePointCountsContainer *xaod) const override
Function that fills an existing xAOD::TrigSpacePointCountsContainer.
TrigSpacePointCountsCnvTool(const std::string &type, const std::string &name, const IInterface *parent)
Regular AlgTool constructor.
void setPixelClusSizeBins(unsigned int val_N)
void setPixelClusSizeMax(float val_max)
unsigned int sctSpEndcapA() const
void setPixelClusTotMax(float val_max)
unsigned int pixelClusTotBins() const
unsigned int sctSpBarrel() const
unsigned int pixelClusSizeBins() const
const std::vector< float > & contentsPixelClusEndcapC() const
getters
unsigned int sctSpEndcapC() const
void setSctSpBarrel(unsigned int setB)
void setPixelClusSizeMin(float val_min)
void setContentsPixelClusEndcapA(const std::vector< float > &contentsPixelClusEndcapA)
void setContentsPixelClusEndcapC(const std::vector< float > &contentsPixelClusEndcapC)
void setPixelClusTotMin(float val_min)
void setSctSpEndcapC(unsigned int sctEC)
void setSctSpEndcapA(unsigned int setEA)
const std::vector< float > & contentsPixelClusBarrel() const
void setContentsPixelClusBarrel(const std::vector< float > &contentsPixelClusBarrel)
void setPixelClusTotBins(unsigned int val_N)
TrigSpacePointCountsContainer_v1 TrigSpacePointCountsContainer