ATLAS Offline Software
Public Member Functions | Protected Attributes | List of all members
top::SoftMuon Class Reference

Select muons based on some early suggestions. More...

#include <SoftMuon.h>

Inheritance diagram for top::SoftMuon:
Collaboration diagram for top::SoftMuon:

Public Member Functions

 SoftMuon (const double ptcut)
 Construct the tool to select good muons. More...
 
virtual ~SoftMuon ()
 
virtual bool passSelection (const xAOD::Muon &mu) const override
 Implements the logic to select good muons. More...
 
virtual void print (std::ostream &os) const override
 Because everybody likes to know what object definitions they ran with. More...
 

Protected Attributes

double m_ptcut
 
ToolHandle< CP::IMuonSelectionToolm_softmuonSelectionTool
 

Detailed Description

Select muons based on some early suggestions.

Definition at line 18 of file SoftMuon.h.

Constructor & Destructor Documentation

◆ SoftMuon()

top::SoftMuon::SoftMuon ( const double  ptcut)

Construct the tool to select good muons.

Parameters
ptcutThe minimum pT cut for good muons.
isolationThe isolation the user wants to apply. Don't want any isolation to be applied? Then leave this as a nullptr.

Definition at line 10 of file SoftMuon.cxx.

10  :
11  m_ptcut(ptcut),
12  m_softmuonSelectionTool("SoftMuonSelectionTool") {
13  top::check(m_softmuonSelectionTool.retrieve(), "Failed to retrieve softmuonSelectionTool");
14  }

◆ ~SoftMuon()

virtual top::SoftMuon::~SoftMuon ( )
inlinevirtual

Definition at line 30 of file SoftMuon.h.

30 {}

Member Function Documentation

◆ passSelection()

bool top::SoftMuon::passSelection ( const xAOD::Muon mu) const
overridevirtual

Implements the logic to select good muons.

Parameters
muThe muon that we want to check.
Returns
True if the muon is good, false otherwise.

Implements top::SoftMuonSelectionBase.

Definition at line 16 of file SoftMuon.cxx.

16  {
17  if (mu.pt() < m_ptcut) return false;
18 
19  if (!m_softmuonSelectionTool->accept(mu)) return false;
20 
21  return true;
22  }

◆ print()

void top::SoftMuon::print ( std::ostream &  ) const
overridevirtual

Because everybody likes to know what object definitions they ran with.

Implements top::SoftMuonSelectionBase.

Definition at line 24 of file SoftMuon.cxx.

24  {
25  os << "SoftMuon\n"
26  << " * pT > " << m_ptcut << "\n"
27  << " * Everything else from muon tool - fill this in?\n";
28  }

Member Data Documentation

◆ m_ptcut

double top::SoftMuon::m_ptcut
protected

Definition at line 44 of file SoftMuon.h.

◆ m_softmuonSelectionTool

ToolHandle<CP::IMuonSelectionTool> top::SoftMuon::m_softmuonSelectionTool
protected

Definition at line 47 of file SoftMuon.h.


The documentation for this class was generated from the following files:
top::SoftMuon::m_ptcut
double m_ptcut
Definition: SoftMuon.h:44
Pythia8_A14_NNPDF23LO_forMGHT_EvtGen.ptcut
float ptcut
Definition: Pythia8_A14_NNPDF23LO_forMGHT_EvtGen.py:9
top::check
void check(bool thingToCheck, const std::string &usefulFailureMessage)
Print an error message and terminate if thingToCheck is false.
Definition: EventTools.cxx:15
ReadFromCoolCompare.os
os
Definition: ReadFromCoolCompare.py:231
top::SoftMuon::m_softmuonSelectionTool
ToolHandle< CP::IMuonSelectionTool > m_softmuonSelectionTool
Definition: SoftMuon.h:47
CaloNoise_fillDB.mu
mu
Definition: CaloNoise_fillDB.py:53