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

#include <PrescaleTool.h>

Inheritance diagram for DerivationFramework::PrescaleTool:
Collaboration diagram for DerivationFramework::PrescaleTool:

Public Member Functions

 PrescaleTool (const std::string &t, const std::string &n, const IInterface *p)
 
StatusCode initialize ()
 
StatusCode finalize ()
 
virtual bool eventPassesFilter () const
 

Private Attributes

Gaudi::Property< unsigned int > m_prescale {this, "Prescale", 1}
 

Detailed Description

Definition at line 20 of file PrescaleTool.h.

Constructor & Destructor Documentation

◆ PrescaleTool()

DerivationFramework::PrescaleTool::PrescaleTool ( const std::string &  t,
const std::string &  n,
const IInterface *  p 
)

Definition at line 18 of file PrescaleTool.cxx.

20  :
21  base_class(t,n,p)
22  {
23  }

Member Function Documentation

◆ eventPassesFilter()

bool DerivationFramework::PrescaleTool::eventPassesFilter ( ) const
virtual

Definition at line 39 of file PrescaleTool.cxx.

40  {
41  return (Gaudi::Hive::currentContext().eventID().event_number() % m_prescale == 0);
42  }

◆ finalize()

StatusCode DerivationFramework::PrescaleTool::finalize ( )

Definition at line 34 of file PrescaleTool.cxx.

35  {
36  return StatusCode::SUCCESS;
37  }

◆ initialize()

StatusCode DerivationFramework::PrescaleTool::initialize ( )

Definition at line 25 of file PrescaleTool.cxx.

26  {
27  if (m_prescale < 1u) {
28  ATH_MSG_FATAL("Prescale of less than 1 makes no sense");
29  return StatusCode::FAILURE;
30  }
31  return StatusCode::SUCCESS;
32  }

Member Data Documentation

◆ m_prescale

Gaudi::Property<unsigned int> DerivationFramework::PrescaleTool::m_prescale {this, "Prescale", 1}
private

Definition at line 29 of file PrescaleTool.h.


The documentation for this class was generated from the following files:
DerivationFramework::PrescaleTool::m_prescale
Gaudi::Property< unsigned int > m_prescale
Definition: PrescaleTool.h:29
ATH_MSG_FATAL
#define ATH_MSG_FATAL(x)
Definition: AthMsgStreamMacros.h:34
read_hist_ntuple.t
t
Definition: read_hist_ntuple.py:5
Trk::u
@ u
Enums for curvilinear frames.
Definition: ParamDefs.h:77
python.utils.AtlRunQueryDQUtils.p
p
Definition: AtlRunQueryDQUtils.py:210
beamspotman.n
n
Definition: beamspotman.py:731