ATLAS Offline Software
TFileChecker.h
Go to the documentation of this file.
1 // Dear emacs, this is -*- c++ -*-
2 
3 /*
4  Copyright (C) 2002-2022 CERN for the benefit of the ATLAS collaboration
5 */
6 
7 #ifndef XAODROOTACCESS_TOOLS_TFILECHECKER_H
8 #define XAODROOTACCESS_TOOLS_TFILECHECKER_H
9 
10 // System include(s):
11 #include <set>
12 #include <string>
13 
14 // ROOT include(s):
15 #include <TObject.h>
16 
17 // Local include(s):
20 
21 // Forward declaration(s):
22 namespace SG {
23  class AuxVectorBase;
24 }
25 
26 namespace xAOD {
27 
28  // Forward declaration(s):
29  class TEvent;
30 
39  class ATLAS_NOT_THREAD_SAFE TFileChecker : public ::TObject {
40 
41  public:
44 
47 
49  void setStopOnError( ::Bool_t value );
51  ::Bool_t stopOnError() const;
52 
54  void addIgnoredVariable( const std::string& name );
56  void setIgnoredVariables( const std::set< std::string >& value );
58  const std::set< std::string >& ignoredVariables() const;
59 
60  private:
63  const std::string& name );
64 
66  ::Bool_t m_stopOnError;
68  std::set< std::string > m_ignoredVariables;
69 
71  std::set< std::string > m_orpannedContainers;
72 
73  ClassDef( xAOD::TFileChecker, 0 )
74 
75  }; // class TFileChecker
76 
77 } // namespace xAOD
78 
79 #endif // XAODROOTACCESS_TOOLS_TFILECHECKER_H
xAOD::name
name
Definition: TriggerMenuJson_v1.cxx:29
SG
Forward declaration.
Definition: CaloCellPacker_400_500.h:32
xAOD::TFileChecker::setIgnoredVariables
void setIgnoredVariables(const std::set< std::string > &value)
Set the list of variables to be ignored in the test.
xAOD::TFileChecker::stopOnError
::Bool_t stopOnError() const
Check whether the validation will stop when an error is found.
xAOD::TFileChecker::m_orpannedContainers
std::set< std::string > m_orpannedContainers
List of containers without an auxiliary store.
Definition: TFileChecker.h:71
athena.value
value
Definition: athena.py:122
xAOD
ICaloAffectedTool is abstract interface for tools checking if 4 mom is in calo affected region.
Definition: ICaloAffectedTool.h:24
vec
std::vector< size_t > vec
Definition: CombinationsGeneratorTest.cxx:12
xAOD::TFileChecker::ignoredVariables
const std::set< std::string > & ignoredVariables() const
Get the list of variables which are ignored in the test.
SG::AuxVectorBase
Manage index tracking and synchronization of auxiliary data.
Definition: AuxVectorBase.h:98
xAOD::ATLAS_NOT_THREAD_SAFE
void ErrorHandler ATLAS_NOT_THREAD_SAFE(Int_t level, Bool_t abort, const char *location, const char *message)
Function filtering the warnings coming from ROOT.
Definition: Init.cxx:105
event
POOL::TEvent event(POOL::TEvent::kClassAccess)
EL::StatusCode
::StatusCode StatusCode
StatusCode definition for legacy code.
Definition: PhysicsAnalysis/D3PDTools/EventLoop/EventLoop/StatusCode.h:22
xAOD::TFileChecker
Tool for running sanity checks on xAOD files.
Definition: TFileChecker.h:39
xAOD::TFileChecker::TFileChecker
TFileChecker()
Default constructor.
xAOD::TFileChecker::setStopOnError
void setStopOnError(::Bool_t value)
Set whether the validation should stop when an error is found.
xAOD::TFileChecker::addIgnoredVariable
void addIgnoredVariable(const std::string &name)
Add a variable to be ignored in the test.
StatusCode.h
xAOD::TFileChecker::checkContainer
StatusCode checkContainer(const SG::AuxVectorBase &vec, const std::string &name)
Check the health of a container.
xAOD::TFileChecker::m_ignoredVariables
std::set< std::string > m_ignoredVariables
List of variables to ignore in the test.
Definition: TFileChecker.h:68
xAOD::TFileChecker::m_stopOnError
::Bool_t m_stopOnError
Stop the validation when an issue is found?
Definition: TFileChecker.h:66
checker_macros.h
Define macros for attributes used to control the static checker.
xAOD::TEvent
Tool for accessing xAOD files outside of Athena.
Definition: Control/xAODRootAccess/xAODRootAccess/TEvent.h:81
xAOD::TFileChecker::check
StatusCode check(TEvent &event)
Execute all sanity checks on a given file.