|
ATLAS Offline Software
|
Go to the documentation of this file.
26 const std::string&
name,
27 const IInterface*
parent ) :
37 "Pointer to the McVtxFilterTool to be able to select additional "
38 "vertices on some decay pattern(s) criterion(s)" );
42 "Pointer to the TruthIsolationTool to be able to compute "
43 "transverse energy isolations for various isolation cones cuts. "
44 "See McParticleEvent/TruthParticleParameters.h for cone cuts." );
49 "Switch to compute or not the Et-isolations for TruthParticle "
50 "(and their underlying @c HepMC::GenParticle).\n"
51 "Default is to not compute these Et-isolations (and save CPU)." );
53 declareInterface<ITruthParticleFilterTool>(
this);
71 ATH_MSG_ERROR(
"Creation of algTool IMcVtxFilterTool FAILED !");
72 return StatusCode::FAILURE;
96 return StatusCode::FAILURE;
102 return StatusCode::SUCCESS;
114 return StatusCode::FAILURE;
117 return StatusCode::SUCCESS;
127 if (!mcEventsReadHandle.
isValid()){
129 return StatusCode::FAILURE;
134 ATH_CHECK(mcEventsOutputWriteHandle.
record(std::make_unique<McEventCollection>()));
136 if (!mcEventsOutputWriteHandle.
isValid()){
137 ATH_MSG_ERROR(
"Invalid WriteHamdle for McEventCollection with key ["
139 return StatusCode::FAILURE;
147 return StatusCode::FAILURE;
151 if ( this->
buildMcAod( mcEventsReadHandle.
ptr(), mcEventsOutputWriteHandle.
ptr() ).isFailure() ) {
153 return StatusCode::FAILURE;
164 "isolation energies !");
167 return StatusCode::SUCCESS;
BooleanProperty m_doEtIsolation
Switch to compute or not the Et-isolations for TruthParticle (and their underlying HepMC::GenParticle...
Gaudi::Details::PropertyBase & declareProperty(Gaudi::Property< T > &t)
virtual StatusCode buildMcAod(const McEventCollection *in, McEventCollection *filtered)=0
This method will check the validity of the input McEventCollection and build a filtered one from the ...
virtual StatusCode finalizeTool()
#define ATH_MSG_VERBOSE(x)
const std::string & key() const
Return the StoreGate ID for the referenced object.
virtual StatusCode initializeTool()
I/O operators.
SG::ReadHandleKey< McEventCollection > m_mcEventsReadHandleKey
ReadHandleKey for the input McEventCollection one wants to filter.
::StatusCode StatusCode
StatusCode definition for legacy code.
pointer_type ptr()
Dereference the pointer.
McVtxFilterTool_t m_mcVtxFilterTool
Pointer to the McVtxFilterTool to be able to select additional vertices on some decay pattern criteri...
IsolTool_t m_isolationTool
Pointer to the TruthIsolationTool to be able to compute transverse energy isolations for various isol...
ToolHandle< ITruthIsolationTool > IsolTool_t
StatusCode initialize(bool used=true)
If this object is used as a property, then this should be called during the initialize phase.
ToolHandle< IMcVtxFilterTool > McVtxFilterTool_t
virtual bool isValid() override final
Can the handle be successfully dereferenced?
TruthParticleFilterBaseTool()
Default constructor:
virtual bool isValid() override final
Can the handle be successfully dereferenced?
virtual ~TruthParticleFilterBaseTool()
Destructor:
StatusCode initialize()
Athena Algorithm's Hooks.
const_pointer_type ptr()
Dereference the pointer.
StatusCode record(std::unique_ptr< T > data)
Record a const object to the store.
#define ATH_MSG_WARNING(x)
SG::WriteHandleKey< McEventCollection > m_mcEventsOutputWriteHandleKey
Location of the output McEventCollection which has been filtered.