ServiceHistory.h
Go to the documentation of this file.
1 #ifndef GAUDIKERNEL_SERVICEHISTORY_H
2 #define GAUDIKERNEL_SERVICEHISTORY_H
3 
4 #include "GaudiKernel/HistoryObj.h"
5 #include "GaudiKernel/IVersHistoryObj.h"
6 
7 #include <string>
8 #include <vector>
9 
10 class IService;
11 class Property;
12 class JobHistory;
13 
22 class GAUDI_API ServiceHistory: public HistoryObj, public IVersHistoryObj {
23 
24 public:
26  ServiceHistory(const IService*, const JobHistory* ) ;
27  ServiceHistory(const IService&, const JobHistory* ) ;
28 
29  virtual ~ServiceHistory() = default;
30 
31  // Class IDs
32  virtual const CLID& clID() const { return classID(); }
33  static const CLID& classID();
34 
35  // Return the service properties.
36  const PropertyList& properties() const { return m_properties; }
37 
38  const IService* service() const { return m_pService; }
39 
40  const JobHistory* jobHistory() const { return m_jobHistory; }
41 
42  void dump(std::ostream &, const bool isXML=false, int indent=0) const;
43 
44  const std::string& name() const { return m_name; }
45  const std::string& type() const { return m_type; }
46  const std::string& version() const { return m_version; }
47 
48 
49 private:
50 
51  const IService* m_pService;
52  const JobHistory* m_jobHistory;
53  std::string m_name,m_type,m_version;
54  PropertyList m_properties;
55 
56 };
57 
58 // Output stream.
59 GAUDI_API std::ostream& operator<<(std::ostream& lhs, const ServiceHistory& rhs);
60 
61 #endif
#define GAUDI_API
Definition: Kernel.h:107
static const CLID & classID()
Definition: HistoryObj.cpp:50
virtual void dump(std::ostream &, const bool isXML=false, int indent=0) const =0
List of properties.
Definition: PropertyList.h:16
Base class for History Objects.
Definition: HistoryObj.h:22
GAUDI_API std::ostream & operator<<(std::ostream &lhs, const ServiceHistory &rhs)
JobHistory class definition.
Definition: JobHistory.h:24
unsigned char m_version
Version number.
Definition: DataObject.h:35
General service interface definition.
Definition: IService.h:18
unsigned int CLID
Class ID definition.
Definition: ClassID.h:8
unsigned char version() const
Retrieve version number of this object representation.
Definition: DataObject.h:82
Property base class allowing Property* collections to be "homogeneous".
Definition: Property.h:38
virtual const CLID & clID() const
Retrieve reference to class definition structure.
Definition: HistoryObj.h:27
ServiceHistory class definition.
const std::string & name() const
Retreive DataObject name. It is the name when registered in the store.
Definition: DataObject.cpp:78
Interface for Versioned History Objects.
string type
Definition: gaudirun.py:151