 |
ATLAS Offline Software
|
Go to the documentation of this file.
5 #ifndef TrigConfigSvc_JobOptionsSvc
6 #define TrigConfigSvc_JobOptionsSvc
11 #include "Gaudi/Interfaces/IOptionsSvc.h"
12 #include "GaudiKernel/ServiceHandle.h"
33 class JobOptionsSvc :
public extends<AthService, TrigConf::IJobOptionsSvc, Gaudi::Interfaces::IOptionsSvc> {
34 using AthService::getProperties;
44 virtual void set(
const std::string&
key,
const std::string&
value )
override
49 virtual std::string
get(
const std::string&
key,
const std::string& default_ = {} )
const override
54 virtual std::string
pop(
const std::string&
key,
const std::string& default_ = {} )
override
59 virtual bool has(
const std::string&
key )
const override
64 virtual bool isSet(
const std::string&
key )
const override
69 virtual std::vector<std::tuple<std::string, std::string>>
items()
const override
74 virtual void bind(
const std::string&
prefix, Gaudi::Details::PropertyBase* property )
override
88 throw std::runtime_error(
"TrigConf::JobOptionsSvc::readOptions() is not supported");
112 Gaudi::Property<std::string>
m_sourceType{
this,
"TYPE",
"NONE",
"Configuration type (NONE, FILE, DB)"};
113 Gaudi::Property<std::string>
m_sourcePath{
this,
"PATH", {},
"Path for NONE/FILE, connection string for DB"};
114 Gaudi::Property<std::string>
m_searchPath{
this,
"SEARCHPATH", {},
"NOT SUPPORTED"};
115 Gaudi::Property<std::string>
m_dump{
this,
"DUMPFILE", {},
"Dump job properties into JSON file"};
virtual int hltPrescaleKey() const override
Return HLTPSK (-1 if not set)
virtual std::vector< std::tuple< std::string, std::string > > items() const override
Gaudi::Property< std::string > m_searchPath
StatusCode readOptionsJson(const std::string &file)
virtual StatusCode initialize() override
StatusCode readOptionsDB(const std::string &db_server, int smk)
Gaudi::Property< std::string > m_dump
virtual bool has(const std::string &key) const override
virtual StatusCode readOptions(std::string_view, std::string_view) override
Gaudi::Property< std::string > m_sourcePath
Gaudi::Property< std::string > m_sourceType
int m_l1psk
L1 prescale key.
Forward iterator to traverse the main components of the trigger configuration.
JobOptionsSvc(const std::string &name, ISvcLocator *pSvcLocator)
virtual void set(const std::string &key, const std::string &value) override
::StatusCode StatusCode
StatusCode definition for legacy code.
virtual void broadcast(const std::regex &filter, const std::string &value, OnlyDefaults defaults=OnlyDefaults{true}) override
virtual std::string pop(const std::string &key, const std::string &default_={}) override
std::string m_server
DB connection alias.
virtual int superMasterKey() const override
Return SMK (-1 if not set)
virtual std::string get(const std::string &key, const std::string &default_={}) const override
Gaudi::Interfaces::IOptionsSvc::OnlyDefaults OnlyDefaults
virtual StatusCode start() override
virtual void bind(const std::string &prefix, Gaudi::Details::PropertyBase *property) override
StatusCode dumpOptions(const std::string &file)
This is mainly for debugging purposes and to compare the JobOptions as seen by the JobOptionSvc to th...
virtual const std::string & server() const override
DB connection alias.
virtual bool isSet(const std::string &key) const override
int m_hltpsk
HLT prescale key.
virtual int l1PrescaleKey() const override
Return L1PSK (-1 if not set)
JobOptionsSvc for the HLT.
ServiceHandle< Gaudi::Interfaces::IOptionsSvc > m_optsvc
handle to the "real" IOptionsSvc
void parseDBString(const std::string &s)
Parse DB connection string and fill private members.