ATLAS Offline Software
Toggle main menu visibility
Loading...
Searching...
No Matches
PhysicsAnalysis
Algorithms
SelectionHelpers
Root
SelectionReadAccessorChar.cxx
Go to the documentation of this file.
1
/*
2
Copyright (C) 2002-2019 CERN for the benefit of the ATLAS collaboration
3
*/
4
6
7
8
//
9
// includes
10
//
11
12
#include <
SelectionHelpers/SelectionReadAccessorChar.h
>
13
14
#include <
PATInterfaces/SystematicSet.h
>
15
#include <
SystematicsHandles/ISysHandleBase.h
>
16
17
//
18
// method implementations
19
//
20
21
namespace
CP
22
{
23
SelectionReadAccessorChar ::
24
SelectionReadAccessorChar (
const
std::string&
name
)
25
:
m_constAccessor
(
name
),
m_label
(
name
)
26
{}
27
28
29
30
SelectionType
SelectionReadAccessorChar ::
31
getBits (
const
SG::AuxElement
& element,
32
const
CP::SystematicSet
*
/*sys*/
)
const
33
{
34
if
(
m_constAccessor
(element))
35
return
selectionAccept
();
36
else
37
return
0;
38
}
39
40
41
42
bool
SelectionReadAccessorChar ::
43
getBool (
const
SG::AuxElement
& element,
44
const
CP::SystematicSet
*
/*sys*/
)
const
45
{
46
return
m_constAccessor
(element);
47
}
48
49
50
51
std::string SelectionReadAccessorChar ::
52
label ()
const
53
{
54
return
m_label
;
55
}
56
57
58
59
bool
SelectionReadAccessorChar ::
60
isBool ()
const
61
{
62
return
true
;
63
}
64
65
66
67
CP::SystematicSet
SelectionReadAccessorChar ::
68
getInputAffecting (
const
ISystematicsSvc
&
/*svc*/
,
69
const
std::string&
/*objectName*/
)
const
70
{
71
return
CP::SystematicSet
();
72
}
73
74
75
76
StatusCode SelectionReadAccessorChar ::
77
fillSystematics (
const
ISystematicsSvc
& svc,
78
const
std::vector<CP::SystematicSet>&
/*sysList*/
,
79
ISysObjectHandleBase
& objectHandle)
80
{
81
using namespace
msgSelectionHelpers;
82
83
ANA_CHECK
(objectHandle.
addDecorationDependency
(svc,
m_label
,
false
));
84
return
StatusCode::SUCCESS;
85
}
86
}
ANA_CHECK
#define ANA_CHECK(EXP)
check whether the given expression was successful
Definition
Control/AthToolSupport/AsgMessaging/AsgMessaging/MessageCheck.h:324
ISysHandleBase.h
SelectionReadAccessorChar.h
SystematicSet.h
CP::ISysObjectHandleBase
a ISysHandleBase for a handle to a specific object/container
Definition
ISysHandleBase.h:58
CP::ISysObjectHandleBase::addDecorationDependency
virtual StatusCode addDecorationDependency(const ISystematicsSvc &svc, const std::string &decoName, bool decoWrite)=0
add dependency information for the given decoration
CP::ISystematicsSvc
the interface for the central systematics service
Definition
ISystematicsSvc.h:26
CP::SelectionReadAccessorChar::m_label
std::string m_label
the label of the accessor
Definition
SelectionReadAccessorChar.h:65
CP::SelectionReadAccessorChar::m_constAccessor
SG::ConstAccessor< char > m_constAccessor
the underlying accessor
Definition
SelectionReadAccessorChar.h:61
CP::SystematicSet
Class to wrap a set of SystematicVariations.
Definition
SystematicSet.h:31
CP
Select isolated Photons, Electrons and Muons.
Definition
Control/xAODRootAccess/xAODRootAccess/TEvent.h:27
CP::SelectionType
uint32_t SelectionType
the type for selection decorations that are meant to hold a asg::AcceptData
Definition
SelectionHelpers.h:26
CP::selectionAccept
constexpr SelectionType selectionAccept()
the selection decoration to apply for objects that are selected
Definition
SelectionHelpers.h:35
SG::AuxElement
AuxElement(SG::AuxVectorData *container, size_t index)
Base class for elements of a container that can have aux data.
xAOD::name
name
Definition
TriggerMenuJson_v1.cxx:29
Generated on
for ATLAS Offline Software by
1.17.0