ATLAS Offline Software
GoodRunsListSelectionTool.h
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2017 CERN for the benefit of the ATLAS collaboration
3 */
4 
5 // $Id$
6 // Dear emacs, this is -*- c++ -*-
7 #ifndef GoodRunsLists_GoodRunsListSelectionTool_H
8 #define GoodRunsLists_GoodRunsListSelectionTool_H
9 
10 // System include(s):
11 #include <vector>
12 #include <string>
13 
14 // Framework include(s):
15 #include "AsgTools/AsgTool.h"
16 
17 // Local include(s):
20 
21 #ifndef XAOD_STANDALONE
23 #endif
24 
34 #ifndef XAOD_STANDALONE
36 #endif
37  public asg::AsgTool {
38 
39  // Declare the proper constructor(s) for Athena:
41 
42 public:
43  GoodRunsListSelectionTool( const std::string& name =
44  "GoodRunsListsSelectionTool" );
45 
47  virtual StatusCode initialize();
48 
51 
53  virtual bool passRunLB( const std::vector< std::string >& grlnameVec =
54  std::vector< std::string >(),
55  const std::vector< std::string >& brlnameVec =
56  std::vector< std::string >() ) const;
57 
59  virtual bool passRunLB( const xAOD::EventInfo& event,
60  const std::vector< std::string >& grlnameVec =
61  std::vector< std::string >(),
62  const std::vector< std::string >& brlnameVec =
63  std::vector< std::string >() ) const;
64 
66  virtual bool passRunLB( int runNumber, int lumiBlockNr,
67  const std::vector< std::string >& grlnameVec =
68  std::vector< std::string >(),
69  const std::vector< std::string >& brlnameVec =
70  std::vector< std::string >() ) const;
71 
73  virtual const Root::TGRLCollection& getGRLCollection() const {
74  return m_grlcollection;
75  }
76 
78  virtual const Root::TGRLCollection& getBRLCollection() const {
79  return m_brlcollection;
80  }
81 
82 #ifndef XAOD_STANDALONE
83  virtual bool eventPassesFilter() const;
86 #endif
87 
89 
90 protected:
93  const std::vector< std::string >& files );
94 
95  std::vector< std::string > m_goodrunslistVec;
96  std::vector< std::string > m_blackrunslistVec;
97 
100 
101  int m_boolop;
104 
105 }; // class GoodRunsListSelectionTool
106 
107 #endif // GoodRunsLists_GoodRunsListSelectionTool_H
IGoodRunsListSelectionTool.h
asg::AsgTool
Base class for the dual-use tool implementation classes.
Definition: AsgTool.h:47
GoodRunsListSelectionTool::initialize
virtual StatusCode initialize()
Initialize AlgTool.
Definition: GoodRunsListSelectionTool.cxx:26
TGRLCollection.h
GoodRunsListSelectionTool
Tool implementing the GRL selection.
Definition: GoodRunsListSelectionTool.h:37
ASG_TOOL_CLASS2
#define ASG_TOOL_CLASS2(CLASSNAME, INT1, INT2)
Definition: AsgToolMacros.h:77
GoodRunsListSelectionTool::readXMLs
StatusCode readXMLs(Root::TGRLCollection &grl, const std::vector< std::string > &files)
Helper function reading in the specified files into a GRL object.
Definition: GoodRunsListSelectionTool.cxx:141
GoodRunsListSelectionTool::getGRLCollection
virtual const Root::TGRLCollection & getGRLCollection() const
Get the good runs list used by the tool.
Definition: GoodRunsListSelectionTool.h:73
GoodRunsListSelectionTool::eventPassesFilter
virtual bool eventPassesFilter() const
ISkimmingTool method: will retrieve eventInfo from storegate and use that with above methods.
Definition: GoodRunsListSelectionTool.cxx:189
DerivationFramework::ISkimmingTool
Definition: ISkimmingTool.h:25
IGoodRunsListSelectionTool
Main tools implementing this interface: GoodRunsListSelectionTool (source code: DataQuality/GoodRunsL...
Definition: PhysicsAnalysis/Interfaces/AsgAnalysisInterfaces/AsgAnalysisInterfaces/IGoodRunsListSelectionTool.h:26
grl
Definition: ZLumiScripts/grid/grl.py:1
GoodRunsListSelectionTool::m_brlcollection
Root::TGRLCollection m_brlcollection
Definition: GoodRunsListSelectionTool.h:99
GoodRunsListSelectionTool::m_goodrunslistVec
std::vector< std::string > m_goodrunslistVec
Definition: GoodRunsListSelectionTool.h:95
event
POOL::TEvent event(POOL::TEvent::kClassAccess)
EL::StatusCode
::StatusCode StatusCode
StatusCode definition for legacy code.
Definition: PhysicsAnalysis/D3PDTools/EventLoop/EventLoop/StatusCode.h:22
GoodRunsListSelectionTool::m_boolop
int m_boolop
Definition: GoodRunsListSelectionTool.h:101
generateReferenceFile.files
files
Definition: generateReferenceFile.py:12
GoodRunsListSelectionTool::m_blackrunslistVec
std::vector< std::string > m_blackrunslistVec
Definition: GoodRunsListSelectionTool.h:96
Root::TGRLCollection
Definition: TGRLCollection.h:29
GoodRunsListSelectionTool::GoodRunsListSelectionTool
GoodRunsListSelectionTool(const std::string &name="GoodRunsListsSelectionTool")
Definition: GoodRunsListSelectionTool.cxx:15
name
std::string name
Definition: Control/AthContainers/Root/debug.cxx:221
GoodRunsListSelectionTool::getBRLCollection
virtual const Root::TGRLCollection & getBRLCollection() const
Get the bad runs list used by the tool.
Definition: GoodRunsListSelectionTool.h:78
GoodRunsListSelectionTool::m_passthrough
bool m_passthrough
Definition: GoodRunsListSelectionTool.h:102
GoodRunsListSelectionTool::m_grlcollection
Root::TGRLCollection m_grlcollection
Definition: GoodRunsListSelectionTool.h:98
GoodRunsListSelectionTool::m_rejectanybrl
bool m_rejectanybrl
Definition: GoodRunsListSelectionTool.h:103
xAOD::EventInfo_v1
Class describing the basic event information.
Definition: EventInfo_v1.h:43
DeMoAtlasDataLoss.runNumber
string runNumber
Definition: DeMoAtlasDataLoss.py:64
GoodRunsListSelectionTool::passRunLB
virtual bool passRunLB(const std::vector< std::string > &grlnameVec=std::vector< std::string >(), const std::vector< std::string > &brlnameVec=std::vector< std::string >()) const
Check if the current event passes the selection.
Definition: GoodRunsListSelectionTool.cxx:55
AsgTool.h
ISkimmingTool.h