ATLAS Offline Software
Loading...
Searching...
No Matches
SelectionWriteAccessorInvert.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
13
15
16//
17// method implementations
18//
19
20namespace CP
21{
22 SelectionWriteAccessorInvert ::
23 SelectionWriteAccessorInvert (std::unique_ptr<ISelectionWriteAccessor> val_base)
24 : m_base (std::move (val_base))
25 {}
26
27
28
29 void SelectionWriteAccessorInvert ::
30 setBits (const SG::AuxElement& element,
32 const CP::SystematicSet *sys) const
33 {
34 m_base->setBool (element, selection != selectionAccept(), sys);
35 }
36
37
38
39 void SelectionWriteAccessorInvert ::
40 setBool (const SG::AuxElement& element,
41 bool selection,
42 const CP::SystematicSet *sys) const
43 {
44 m_base->setBool (element, !selection, sys);
45 }
46
47
48
49 std::string SelectionWriteAccessorInvert ::
50 label () const
51 {
52 return m_base->label() + ",invert";
53 }
54
55
56
57 StatusCode SelectionWriteAccessorInvert ::
58 fillSystematics (const ISystematicsSvc& svc,
59 const CP::SystematicSet& fullAffecting,
60 const std::vector<CP::SystematicSet>& sysList,
61 const std::string& objectName)
62 {
63 return m_base->fillSystematics (svc, fullAffecting, sysList, objectName);
64 }
65}
the interface for the central systematics service
std::unique_ptr< ISelectionWriteAccessor > m_base
the base selection accessors I invert
Class to wrap a set of SystematicVariations.
Base class for elements of a container that can have aux data.
Definition AuxElement.h:483
const std::string selection
Select isolated Photons, Electrons and Muons.
uint32_t SelectionType
the type for selection decorations that are meant to hold a asg::AcceptData
constexpr SelectionType selectionAccept()
the selection decoration to apply for objects that are selected
STL namespace.