ATLAS Offline Software
Loading...
Searching...
No Matches
OutputConditionsAlg.h
Go to the documentation of this file.
1/*
2 Copyright (C) 2002-2019 CERN for the benefit of the ATLAS collaboration
3*/
4
5#ifndef REGISTRATIONSVC_OUTPUTCONDALG_H
6#define REGISTRATIONSVC_OUTPUTCONDALG_H
7// OutputConditionsAlg.h
8// an Algorithm to output conditions data on an AthenaOutputStream and
9// optionally register it in the conditions database
10// Richard Hawkings, started 1/9/05, from a skeleton by Walter Lampl
11
13#include "GaudiKernel/ServiceHandle.h"
14#include "GaudiKernel/ToolHandle.h"
16#include <vector>
17#include <string>
18
20class IClassIDSvc;
22
24{
25public:
26
27 OutputConditionsAlg(const std::string& name, ISvcLocator* pSvcLocator);
29
30 StatusCode initialize();
31 StatusCode execute();
32 StatusCode finalize();
33
34private:
35
36 ServiceHandle<IClassIDSvc> p_clidsvc{this,"ClassIDSvc","ClassIDSvc"};
37 ServiceHandle<IIOVRegistrationSvc> p_regsvc{this, "IOVRegistrationSvc","IOVRegistrationSvc"};
38
39 uint64_t timeToNano(unsigned long int timesec) const;
40
41 typedef ToolHandle<IAthenaOutputStreamTool> IAthenaOutputStreamTool_t;
43
44 Gaudi::Property<std::vector<std::string> > m_objectList{this,"ObjectList",{},"List of object to be written","OrderedSet<std::string>"};
45 Gaudi::Property<std::string> m_streamName{this,"StreamName","ConditionsAlgStream"};
46 Gaudi::Property<bool> m_par_writeIOV{this,"WriteIOV",true};
47 Gaudi::Property<unsigned int> m_par_run1 {this,"Run1",IOVTime::MINRUN,"IOV start (run-number)"};
48 Gaudi::Property<unsigned int> m_par_lumib1 {this,"LB1",IOVTime::MINEVENT,"IOV start (LB-number)"};
49 Gaudi::Property<unsigned int> m_par_run2 {this,"Run2",IOVTime::MAXRUN,"IOV end (run-number)"};
50 Gaudi::Property<unsigned int> m_par_lumib2 {this,"LB2",IOVTime::MAXEVENT,"IOV end (LB-number)"};
51 UnsignedLongProperty m_par_time1 {this,"Time1",IOVTime::MINTIMESTAMP,"IOV start (timestamp)"};
52 UnsignedLongProperty m_par_time2 {this,"Time2",IOVTime::MAXEVENT,"IOV end (timestamp)"};
53 Gaudi::Property<bool> m_par_timestamp {this,"UseTime",false,"IOV in second or Run/LB"};
54 Gaudi::Property<std::vector<std::string> > m_par_iovtags {this,"IOVTagList",{},"List of Tags to be written","OrderedSet<std::string>"};
55};
56
57#endif // REGISTRATIONSVC_OUTPUTCONDALG_H
Basic time unit for IOVSvc.
AthAlgorithm(const std::string &name, ISvcLocator *pSvcLocator)
Constructor with parameters:
This is a tool that allows streaming out of DataObjects.
This is an interface to a service used to register conditions objects in the Interval of Validity (IO...
static constexpr uint32_t MAXRUN
Definition IOVTime.h:48
static constexpr uint32_t MINEVENT
Definition IOVTime.h:50
static constexpr uint64_t MINTIMESTAMP
Definition IOVTime.h:56
static constexpr uint32_t MAXEVENT
Definition IOVTime.h:51
static constexpr uint32_t MINRUN
Definition IOVTime.h:44
uint64_t timeToNano(unsigned long int timesec) const
UnsignedLongProperty m_par_time2
ServiceHandle< IClassIDSvc > p_clidsvc
Gaudi::Property< bool > m_par_writeIOV
ServiceHandle< IIOVRegistrationSvc > p_regsvc
OutputConditionsAlg(const std::string &name, ISvcLocator *pSvcLocator)
Gaudi::Property< unsigned int > m_par_lumib2
Gaudi::Property< std::vector< std::string > > m_par_iovtags
ToolHandle< IAthenaOutputStreamTool > IAthenaOutputStreamTool_t
Gaudi::Property< bool > m_par_timestamp
IAthenaOutputStreamTool_t m_streamer
Gaudi::Property< std::string > m_streamName
Gaudi::Property< std::vector< std::string > > m_objectList
Gaudi::Property< unsigned int > m_par_run2
UnsignedLongProperty m_par_time1
Gaudi::Property< unsigned int > m_par_lumib1
Gaudi::Property< unsigned int > m_par_run1