ATLAS Offline Software
PhysicsAnalysis
Algorithms
AsgAnalysisAlgorithms
AsgAnalysisAlgorithms
AsgMaskSelectionTool.h
Go to the documentation of this file.
1
/*
2
Copyright (C) 2002-2024 CERN for the benefit of the ATLAS collaboration
3
*/
4
6
7
8
9
#ifndef ASG_ANALYSIS_ALGORITHMS__ASG_MASK_SELECTION_TOOL_H
10
#define ASG_ANALYSIS_ALGORITHMS__ASG_MASK_SELECTION_TOOL_H
11
12
#include <
AsgTools/AsgTool.h
>
13
#include <
PATCore/IAsgSelectionTool.h
>
14
#include <
SelectionHelpers/ISelectionReadAccessor.h
>
15
#include <
xAODBase/IParticle.h
>
16
#include "
AsgTools/PropertyWrapper.h
"
17
#include <memory>
18
#include <string>
19
#include <vector>
20
21
namespace
CP
22
{
27
28
class
AsgMaskSelectionTool
final
29
:
public
asg::AsgTool
,
virtual
public
IAsgSelectionTool
30
{
31
//
32
// public interface
33
//
34
35
// Create a proper constructor for Athena
36
ASG_TOOL_CLASS
(
AsgMaskSelectionTool
,
IAsgSelectionTool
)
37
38
39
40
public
:
45
using
asg::AsgTool::AsgTool
;
46
47
48
49
//
50
// inherited interface
51
//
52
53
virtual
StatusCode
initialize
()
override
;
54
55
virtual
const
asg::AcceptInfo
&
getAcceptInfo
( )
const override
;
56
57
virtual
asg::AcceptData
accept
(
const
xAOD::IParticle
*
part
)
const override
;
58
59
60
61
//
62
// private interface
63
//
64
67
private
:
68
Gaudi::Property<std::vector<std::string>>
m_selVars
{
this
,
"selectionVars"
, {},
"list of variables to use as selection criteria"
};
69
Gaudi::Property<std::vector<unsigned int>>
m_selMasks
{
this
,
"selectionMasks"
, {},
"list of masks, one per variable, for applying the selection"
};
70
std::vector<std::unique_ptr<ISelectionReadAccessor> >
m_acc_selVars
;
71
73
74
76
private
:
77
asg::AcceptInfo
m_accept
;
78
};
79
}
80
81
#endif
LArG4FSStartPointFilter.part
part
Definition:
LArG4FSStartPointFilter.py:21
CP::AsgMaskSelectionTool::m_selMasks
Gaudi::Property< std::vector< unsigned int > > m_selMasks
Definition:
AsgMaskSelectionTool.h:69
asg::AsgTool
Base class for the dual-use tool implementation classes.
Definition:
AsgTool.h:47
PropertyWrapper.h
IParticle.h
CP::AsgMaskSelectionTool::getAcceptInfo
virtual const asg::AcceptInfo & getAcceptInfo() const override
Declare the interface ID for this pure-virtual interface class to the Athena framework.
Definition:
AsgMaskSelectionTool.cxx:52
CP::AsgMaskSelectionTool::accept
virtual asg::AcceptData accept(const xAOD::IParticle *part) const override
The main accept method: the actual cuts are applied here.
Definition:
AsgMaskSelectionTool.cxx:58
CP::AsgMaskSelectionTool::initialize
virtual StatusCode initialize() override
Dummy implementation of the initialisation function.
Definition:
AsgMaskSelectionTool.cxx:25
IAsgSelectionTool
Definition:
IAsgSelectionTool.h:28
xAOD::IParticle
Class providing the definition of the 4-vector interface.
Definition:
Event/xAOD/xAODBase/xAODBase/IParticle.h:41
IAsgSelectionTool.h
CP::AsgMaskSelectionTool::m_acc_selVars
std::vector< std::unique_ptr< ISelectionReadAccessor > > m_acc_selVars
Definition:
AsgMaskSelectionTool.h:70
CP
Select isolated Photons, Electrons and Muons.
Definition:
Control/xAODRootAccess/xAODRootAccess/TEvent.h:48
asg::AsgTool::AsgTool
AsgTool(const std::string &name)
Constructor specifying the tool instance's name.
Definition:
AsgTool.cxx:58
asg::AcceptInfo
Definition:
AcceptInfo.h:28
EL::StatusCode
::StatusCode StatusCode
StatusCode definition for legacy code.
Definition:
PhysicsAnalysis/D3PDTools/EventLoop/EventLoop/StatusCode.h:22
CP::AsgMaskSelectionTool
an IAsgSelectionTool that cuts on int decorations with mask
Definition:
AsgMaskSelectionTool.h:30
CP::AsgMaskSelectionTool::m_accept
asg::AcceptInfo m_accept
the asg::AcceptInfo we are using
Definition:
AsgMaskSelectionTool.h:77
CP::AsgMaskSelectionTool::m_selVars
Gaudi::Property< std::vector< std::string > > m_selVars
tool properties
Definition:
AsgMaskSelectionTool.h:68
ASG_TOOL_CLASS
#define ASG_TOOL_CLASS(CLASSNAME, INT1)
Definition:
AsgToolMacros.h:68
ISelectionReadAccessor.h
AsgTool.h
asg::AcceptData
Definition:
AcceptData.h:30
Generated on Thu Nov 7 2024 21:10:14 for ATLAS Offline Software by
1.8.18