DD4hep  1.28.0
Detector Description Toolkit for High Energy Physics
ConditionsPrinter.h
Go to the documentation of this file.
1 //==========================================================================
2 // AIDA Detector description implementation
3 //--------------------------------------------------------------------------
4 // Copyright (C) Organisation europeenne pour la Recherche nucleaire (CERN)
5 // All rights reserved.
6 //
7 // For the licensing terms see $DD4hepINSTALL/LICENSE.
8 // For the list of contributors see $DD4hepINSTALL/doc/CREDITS.
9 //
10 // Author : M.Frank
11 //
12 //==========================================================================
13 #ifndef DD4HEP_CONDITIONSPRINTER_H
14 #define DD4HEP_CONDITIONSPRINTER_H
15 
16 // Framework includes
17 #include "DD4hep/Printout.h"
18 #include "DD4hep/DetElement.h"
19 #include "DD4hep/Conditions.h"
20 
22 namespace dd4hep {
23 
25  namespace cond {
26 
28 
39  protected:
41  class ParamPrinter;
42  friend class ParamPrinter;
43 
48 
49  protected:
51  int m_flag = 0;
52 
53  public:
55  std::string name;
58  std::string prefix;
60  PrintLevel printLevel = INFO;
62  size_t lineLength = 80;
64  size_t numParam = 0;
66  mutable size_t numCondition = 0;
68  mutable size_t numEmptyCondition = 0;
70  bool summary = true;
71  public:
74  const std::string& prefix="",
77  virtual ~ConditionsPrinter();
79  void setName(const std::string& value) { name = value; }
81  void setPrefix(const std::string& value) { prefix = value; }
83  virtual int operator()(DetElement de, int level) const;
85  virtual int operator()(Condition condition) const;
86  };
87 
88  } /* End namespace cond */
89 } /* End namespace dd4hep */
90 #endif // DD4HEP_CONDITIONSPRINTER_H
cond
AlignmentCondition::Object * cond
Definition: AlignmentsCalculator.cpp:68
dd4hep::Condition::NO_NAME
@ NO_NAME
Definition: Conditions.h:71
dd4hep::cond::ConditionsPrinter::numEmptyCondition
size_t numEmptyCondition
Counter: number of empty conditions.
Definition: ConditionsPrinter.h:68
dd4hep::cond::ConditionsPrinter::numCondition
size_t numCondition
Counter: number of conditions.
Definition: ConditionsPrinter.h:66
dd4hep::cond::ConditionsPrinter::m_print
ParamPrinter * m_print
Sub-printer.
Definition: ConditionsPrinter.h:45
dd4hep::cond::ConditionsPrinter::~ConditionsPrinter
virtual ~ConditionsPrinter()
Default destructor.
Definition: ConditionsPrinter.cpp:124
dd4hep::cond::ConditionsPrinter::prefix
std::string prefix
Printout prefix.
Definition: ConditionsPrinter.h:58
dd4hep::cond::ConditionsPrinter::lineLength
size_t lineLength
Line length.
Definition: ConditionsPrinter.h:62
dd4hep::cond::ConditionsPrinter::m_flag
int m_flag
Printout processing and customization flag.
Definition: ConditionsPrinter.h:51
dd4hep::cond::ConditionsPrinter::mapping
ConditionsMap * mapping
Conditionsmap to resolve things.
Definition: ConditionsPrinter.h:47
dd4hep::Condition::WITH_ADDRESS
@ WITH_ADDRESS
Definition: Conditions.h:66
dd4hep::Condition
Main condition object handle.
Definition: Conditions.h:51
dd4hep::cond::ConditionsPrinter::numParam
size_t numParam
Counter: number of parameters.
Definition: ConditionsPrinter.h:64
dd4hep::DetElement
Handle class describing a detector element.
Definition: DetElement.h:188
dd4hep::cond::ConditionsPrinter::ConditionsPrinter
ConditionsPrinter(ConditionsMap *m, const std::string &prefix="", int flag=Condition::NO_NAME|Condition::WITH_IOV|Condition::WITH_ADDRESS)
Initializing constructor.
Definition: ConditionsPrinter.cpp:117
dd4hep::cond::ConditionsPrinter::summary
bool summary
Flag to print summary.
Definition: ConditionsPrinter.h:70
dd4hep::Condition::WITH_IOV
@ WITH_IOV
Definition: Conditions.h:65
dd4hep::cond::ConditionsPrinter::printLevel
PrintLevel printLevel
Printout level.
Definition: ConditionsPrinter.h:60
Conditions.h
dd4hep::cond::ConditionsPrinter::ParamPrinter
DDDB Conditions data dumper helper to output parameter maps.
Definition: ConditionsPrinter.cpp:47
dd4hep::cond::ConditionsPrinter::setName
void setName(const std::string &value)
Set name for printouts.
Definition: ConditionsPrinter.h:79
dd4hep::cond::ConditionsPrinter::name
std::string name
Printer name. Want to know who is printing what.
Definition: ConditionsPrinter.h:56
dd4hep::cond::ConditionsPrinter::setPrefix
void setPrefix(const std::string &value)
Set prefix for printouts.
Definition: ConditionsPrinter.h:81
DetElement.h
dd4hep::cond::ConditionsPrinter::operator()
virtual int operator()(DetElement de, int level) const
Callback to output conditions information of an entire DetElement.
Definition: ConditionsPrinter.cpp:264
dd4hep
Namespace for the AIDA detector description toolkit.
Definition: AlignmentsCalib.h:28
Printout.h
dd4hep::cond::ConditionsPrinter
Generic Conditions data dumper.
Definition: ConditionsPrinter.h:38
dd4hep::ConditionsMap
ConditionsMap class.
Definition: ConditionsMap.h:59