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

the SelectionAccesor for inverting a selection decoration More...

#include <SelectionReadAccessorInvert.h>

Inheritance diagram for CP::SelectionReadAccessorInvert:
Collaboration diagram for CP::SelectionReadAccessorInvert:

Public Member Functions

 SelectionReadAccessorInvert (std::unique_ptr< ISelectionReadAccessor > val_base)
 
virtual SelectionType getBits (const SG::AuxElement &element, const CP::SystematicSet *sys) const override
 get the selection decoration More...
 
virtual bool getBool (const SG::AuxElement &element, const CP::SystematicSet *sys) const override
 get the selection decoration More...
 
virtual std::string label () const override
 get the label of the accessor More...
 
virtual bool isBool () const override
 whether this accessor returns a simple boolean More...
 
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...
 

Private Attributes

std::unique_ptr< ISelectionReadAccessorm_base
 the base selection accessors I invert More...
 

Detailed Description

the SelectionAccesor for inverting a selection decoration

Definition at line 20 of file SelectionReadAccessorInvert.h.

Constructor & Destructor Documentation

◆ SelectionReadAccessorInvert()

CP::SelectionReadAccessorInvert::SelectionReadAccessorInvert ( std::unique_ptr< ISelectionReadAccessor val_base)

Definition at line 22 of file SelectionReadAccessorInvert.cxx.

24  : m_base (std::move (val_base))
25  {}

Member Function Documentation

◆ fillSystematics()

StatusCode CP::SelectionReadAccessorInvert::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 75 of file SelectionReadAccessorInvert.cxx.

79  {
80  return m_base->fillSystematics (svc, sysList, objectName);
81  }

◆ getBits()

SelectionType CP::SelectionReadAccessorInvert::getBits ( const SG::AuxElement element,
const CP::SystematicSet sys 
) const
overridevirtual

get the selection decoration

Implements CP::ISelectionReadAccessor.

Definition at line 29 of file SelectionReadAccessorInvert.cxx.

32  {
33  if (m_base->getBool (element, sys) == false)
34  return selectionAccept();
35  else
36  return 0;
37  }

◆ getBool()

bool CP::SelectionReadAccessorInvert::getBool ( const SG::AuxElement element,
const CP::SystematicSet sys 
) const
overridevirtual

get the selection decoration

Implements CP::ISelectionReadAccessor.

Definition at line 41 of file SelectionReadAccessorInvert.cxx.

44  {
45  return m_base->getBool (element, sys) == false;
46  }

◆ getInputAffecting()

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

get the systematics when reading from the decoration

Implements CP::ISelectionReadAccessor.

Definition at line 66 of file SelectionReadAccessorInvert.cxx.

69  {
70  return m_base->getInputAffecting (svc, objectName);
71  }

◆ isBool()

bool CP::SelectionReadAccessorInvert::isBool ( ) const
overridevirtual

whether this accessor returns a simple boolean

Implements CP::ISelectionReadAccessor.

Definition at line 58 of file SelectionReadAccessorInvert.cxx.

60  {
61  return true;
62  }

◆ label()

std::string CP::SelectionReadAccessorInvert::label ( ) const
overridevirtual

get the label of the accessor

Implements CP::ISelectionReadAccessor.

Definition at line 50 of file SelectionReadAccessorInvert.cxx.

52  {
53  return m_base->label() + ",invert";
54  }

Member Data Documentation

◆ m_base

std::unique_ptr<ISelectionReadAccessor> CP::SelectionReadAccessorInvert::m_base
private

the base selection accessors I invert

Definition at line 63 of file SelectionReadAccessorInvert.h.


The documentation for this class was generated from the following files:
mapkey::sys
@ sys
Definition: TElectronEfficiencyCorrectionTool.cxx:42
Handler::svc
AthROOTErrorHandlerSvc * svc
Definition: AthROOTErrorHandlerSvc.cxx:10
CP::SelectionReadAccessorInvert::m_base
std::unique_ptr< ISelectionReadAccessor > m_base
the base selection accessors I invert
Definition: SelectionReadAccessorInvert.h:63
CP::selectionAccept
constexpr SelectionType selectionAccept()
the selection decoration to apply for objects that are selected
Definition: SelectionHelpers.h:35