ATLAS Offline Software
ViewCreatorFSROITool.cxx
Go to the documentation of this file.
1 
2 /*
3 Copyright (C) 2002-2022 CERN for the benefit of the ATLAS collaboration
4 */
5 
7 #include "ViewCreatorFSROITool.h"
8 
9 using namespace TrigCompositeUtils;
10 
11 ViewCreatorFSROITool::ViewCreatorFSROITool(const std::string& type, const std::string& name, const IInterface* parent)
12  : base_class(type, name, parent)
13  {}
14 
15 
18 
19  if ( !m_roiupdater.empty() ) ATH_CHECK( m_roiupdater.retrieve() );
20 
21  return StatusCode::SUCCESS;
22 }
23 
24 
26 
28 
29  if ( m_roiupdater.empty() ) {
30  roisWriteHandle->push_back( new TrigRoiDescriptor( RoiDescriptor::FULLSCAN ) );
31  }
32  else {
33  roisWriteHandle->push_back( m_roiupdater->execute( ctx ) );
34  }
35 
36  const ElementLink<TrigRoiDescriptorCollection> roiEL = ElementLink<TrigRoiDescriptorCollection>( *roisWriteHandle, /*index =*/ 0, ctx );
37 
38  for ( Decision* outputDecision : decisions ) {
39  outputDecision->setObjectLink( roiString(), roiEL );
40  }
41 
42  return StatusCode::SUCCESS;
43 }
ViewCreatorFSROITool::ViewCreatorFSROITool
ViewCreatorFSROITool(const std::string &type, const std::string &name, const IInterface *parent)
Definition: ViewCreatorFSROITool.cxx:11
ViewCreatorFSROITool::m_roisWriteHandleKey
SG::WriteHandleKey< TrigRoiDescriptorCollection > m_roisWriteHandleKey
ROI Write Handle key for the FS ROI colletion.
Definition: ViewCreatorFSROITool.h:38
EL::StatusCode
::StatusCode StatusCode
StatusCode definition for legacy code.
Definition: PhysicsAnalysis/D3PDTools/EventLoop/EventLoop/StatusCode.h:22
ViewCreatorFSROITool::attachROILinks
virtual StatusCode attachROILinks(TrigCompositeUtils::DecisionContainer &decisions, const EventContext &ctx) const override
Tool interface method.
Definition: ViewCreatorFSROITool.cxx:25
ViewCreatorFSROITool::initialize
virtual StatusCode initialize() override
Definition: ViewCreatorFSROITool.cxx:16
test_pyathena.parent
parent
Definition: test_pyathena.py:15
ATH_CHECK
#define ATH_CHECK
Definition: AthCheckMacros.h:40
ViewCreatorFSROITool.h
SG::VarHandleKey::initialize
StatusCode initialize(bool used=true)
If this object is used as a property, then this should be called during the initialize phase.
Definition: AthToolSupport/AsgDataHandles/Root/VarHandleKey.cxx:103
TrigCompositeUtils::createAndStoreNoAux
SG::WriteHandle< CONT > createAndStoreNoAux(const SG::WriteHandleKey< CONT > &key, const EventContext &ctx=Gaudi::Hive::currentContext())
Creates and right away records the Container CONT with the key.
xAOD::TrigComposite_v1
Class used to describe composite objects in the HLT.
Definition: TrigComposite_v1.h:52
DataVector
Derived DataVector<T>.
Definition: DataVector.h:794
xAOD::decisions
decisions
Definition: TrigComposite_v1.cxx:101
name
std::string name
Definition: Control/AthContainers/Root/debug.cxx:228
DataVector::push_back
value_type push_back(value_type pElem)
Add an element to the end of the collection.
SG::WriteHandle< TrigRoiDescriptorCollection >
python.CaloScaleNoiseConfig.type
type
Definition: CaloScaleNoiseConfig.py:78
RoiDescriptor::FULLSCAN
static constexpr bool FULLSCAN
convenient
Definition: RoiDescriptor.h:45
TrigCompositeUtils
Definition: Event/xAOD/xAODTrigger/xAODTrigger/TrigComposite.h:19
TrigCompositeUtils::roiString
const std::string & roiString()
Definition: TrigCompositeUtilsRoot.cxx:876
TrigRoiDescriptor
Athena::TPCnvVers::Current TrigRoiDescriptor
Definition: TrigSteeringEventTPCnv.cxx:68
ViewCreatorFSROITool::m_roiupdater
ToolHandle< IRoiUpdaterTool > m_roiupdater
Definition: ViewCreatorFSROITool.h:41
TrigRoiDescriptorCollection.h