The Gaudi Framework  v33r0 (d5ea422b)
AlgToolHistory.h
Go to the documentation of this file.
1 /***********************************************************************************\
2 * (c) Copyright 1998-2019 CERN for the benefit of the LHCb and ATLAS collaborations *
3 * *
4 * This software is distributed under the terms of the Apache version 2 licence, *
5 * copied verbatim in the file "LICENSE". *
6 * *
7 * In applying this licence, CERN does not waive the privileges and immunities *
8 * granted to it by virtue of its status as an Intergovernmental Organization *
9 * or submit itself to any jurisdiction. *
10 \***********************************************************************************/
11 #ifndef GAUDIKERNEL_ALGTOOLHISTORY_H
12 #define GAUDIKERNEL_ALGTOOLHISTORY_H
13 
14 #include "GaudiKernel/HistoryObj.h"
16 
17 class AlgTool;
18 class JobHistory;
19 
20 #include <memory>
21 #include <string>
22 #include <vector>
23 
33 
34 private: // data
35  // Algtool full type.
37 
38  // Algtool version.
40 
41  // Algtool name.
43 
44  // Pointer to the algtool
45  const AlgTool* m_tool;
46 
47  // Properties.
49 
50  // Link to jobHistory
52 
53 public:
54  AlgToolHistory( const AlgTool& alg, const JobHistory* job );
55 
56  AlgToolHistory( const std::string& algVersion, const std::string& algName, const std::string& algType,
57  const AlgTool* tool, const PropertyList& props, const JobHistory* job );
58 
59  // Class IDs
60  const CLID& clID() const override { return classID(); }
61  static const CLID& classID();
62 
63  // Return the algtool type.
64  const std::string& algtool_type() const { return m_type; }
65 
66  // Return the algtool version.
67  const std::string& algtool_version() const { return m_version; }
68 
69  // Return the algtool name.
70  const std::string& algtool_name() const { return m_name; }
71 
72  // Pointer to the algtool
73  const AlgTool* algtool_instance() const { return m_tool; }
74 
75  // Return the algorithm properties.
76  const PropertyList& properties() const override { return m_properties; }
77 
78  // Return the jobHistory
79  const JobHistory* jobHistory() const { return m_jobHistory; }
80 
81  void dump( std::ostream&, const bool isXML = false, int indent = 0 ) const override;
82 
83  const std::string& name() const override { return algtool_name(); }
84  const std::string& type() const override { return algtool_type(); }
85  const std::string& version() const override { return algtool_version(); }
86 };
87 
88 // Output stream.
90 
91 #endif
const PropertyList & properties() const override
std::string m_version
const JobHistory * m_jobHistory
std::string m_name
PropertyList m_properties
const std::string & algtool_name() const
const std::string & algtool_version() const
const std::string & name() const override
static const CLID & classID()
Definition: HistoryObj.cpp:65
virtual void dump(std::ostream &, const bool isXML=false, int indent=0) const =0
Base class for History Objects.
Definition: HistoryObj.h:31
GAUDI_API std::ostream & operator<<(std::ostream &lhs, const AlgToolHistory &rhs)
JobHistory class definition.
Definition: JobHistory.h:32
std::string m_type
const AlgTool * algtool_instance() const
STL class.
unsigned char m_version
Version number.
Definition: DataObject.h:45
const std::string & algtool_type() const
const std::string & version() const override
const std::string & type() const override
const AlgTool * m_tool
unsigned int CLID
Class ID definition.
Definition: ClassID.h:18
AlgToolHistory class definition.
Base class from which all the concrete tool classes should be derived.
Definition: AlgTool.h:57
Interface for Versioned History Objects.
#define GAUDI_API
Definition: Kernel.h:81
STL class.
const CLID & clID() const override
Retrieve reference to class definition structure.
const JobHistory * jobHistory() const