ATLAS Offline Software
Public Member Functions | Private Attributes | List of all members
CP::SelectionAccessorExprNot Class Reference

SelectionAccessor which implements a logical NOT. More...

#include <SelectionAccessorExprNot.h>

Inheritance diagram for CP::SelectionAccessorExprNot:
Collaboration diagram for CP::SelectionAccessorExprNot:

Public Member Functions

 SelectionAccessorExprNot (std::unique_ptr< ISelectionReadAccessor > child)
 
virtual bool getBool (const SG::AuxElement &element, const CP::SystematicSet *sys) const override
 
virtual std::string label () const override
 
virtual CP::SystematicSet getInputAffecting (const ISystematicsSvc &svc, const std::string &objectName) const override
 get the systematics when reading from the decoration More...
 
virtual StatusCode fillSystematics (const ISystematicsSvc &svc, const std::vector< CP::SystematicSet > &sysList, const std::string &objectName) override
 fill the systematic variations More...
 
virtual SelectionType getBits (const SG::AuxElement &element, const CP::SystematicSet *sys) const override
 get the selection decoration More...
 
virtual bool isBool () const override
 whether this accessor returns a simple boolean More...
 

Private Attributes

std::unique_ptr< ISelectionReadAccessorm_child
 

Detailed Description

SelectionAccessor which implements a logical NOT.

Definition at line 15 of file SelectionAccessorExprNot.h.

Constructor & Destructor Documentation

◆ SelectionAccessorExprNot()

CP::SelectionAccessorExprNot::SelectionAccessorExprNot ( std::unique_ptr< ISelectionReadAccessor child)
Parameters
childThe selection accessor that is to be negated

Definition at line 11 of file SelectionAccessorExprNot.cxx.

13  : m_child(std::move(child)) {}

Member Function Documentation

◆ fillSystematics()

StatusCode CP::SelectionAccessorExprNot::fillSystematics ( const ISystematicsSvc svc,
const std::vector< CP::SystematicSet > &  sysList,
const std::string &  objectName 
)
overridevirtual

fill the systematic variations

Implements CP::ISelectionReadAccessor.

Definition at line 31 of file SelectionAccessorExprNot.cxx.

35 {
36  return m_child->fillSystematics (svc, sysList, objectName);
37 }

◆ getBits()

SelectionType CP::SelectionAccessorExprBase::getBits ( const SG::AuxElement element,
const CP::SystematicSet sys 
) const
overridevirtualinherited

get the selection decoration

Implements CP::ISelectionReadAccessor.

Definition at line 9 of file SelectionAccessorExprBase.cxx.

11  {
12  return getBool(element,sys) ? selectionAccept() : selectionReject();
13 }

◆ getBool()

bool CP::SelectionAccessorExprNot::getBool ( const SG::AuxElement element,
const CP::SystematicSet sys 
) const
overridevirtual
Parameters
elementAuxElement to evaluate the selection on
Returns
Result of the negated result of child

Implements CP::ISelectionReadAccessor.

Definition at line 15 of file SelectionAccessorExprNot.cxx.

16  {
17  return !m_child->getBool(element,sys);
18 }

◆ getInputAffecting()

CP::SystematicSet CP::SelectionAccessorExprNot::getInputAffecting ( const ISystematicsSvc svc,
const std::string &  objectName 
) const
overridevirtual

get the systematics when reading from the decoration

Implements CP::ISelectionReadAccessor.

Definition at line 24 of file SelectionAccessorExprNot.cxx.

27 {
28  return m_child->getInputAffecting (svc, objectName);
29 }

◆ isBool()

bool CP::SelectionAccessorExprBase::isBool ( ) const
overridevirtualinherited

whether this accessor returns a simple boolean

Implements CP::ISelectionReadAccessor.

Definition at line 17 of file SelectionAccessorExprBase.cxx.

19 {
20  return true;
21 }

◆ label()

std::string CP::SelectionAccessorExprNot::label ( ) const
overridevirtual
Returns
Returns a readable and parseable representation

Implements CP::ISelectionReadAccessor.

Definition at line 20 of file SelectionAccessorExprNot.cxx.

20  {
21  return "!" + m_child->label();
22 }

Member Data Documentation

◆ m_child

std::unique_ptr<ISelectionReadAccessor> CP::SelectionAccessorExprNot::m_child
private

Definition at line 38 of file SelectionAccessorExprNot.h.


The documentation for this class was generated from the following files:
mapkey::sys
@ sys
Definition: TElectronEfficiencyCorrectionTool.cxx:42
CP::selectionReject
constexpr SelectionType selectionReject()
the selection decoration to apply for objects that are rejected
Definition: SelectionHelpers.h:44
Handler::svc
AthROOTErrorHandlerSvc * svc
Definition: AthROOTErrorHandlerSvc.cxx:10
CP::ISelectionReadAccessor::getBool
virtual bool getBool(const SG::AuxElement &element, const CP::SystematicSet *sys=nullptr) const =0
get the selection decoration
CP::selectionAccept
constexpr SelectionType selectionAccept()
the selection decoration to apply for objects that are selected
Definition: SelectionHelpers.h:35
CP::SelectionAccessorExprNot::m_child
std::unique_ptr< ISelectionReadAccessor > m_child
Definition: SelectionAccessorExprNot.h:38