GENIEGenerator
Loading...
Searching...
No Matches
AlgId.h
Go to the documentation of this file.
1//____________________________________________________________________________
2/*!
3
4\class genie::AlgId
5
6\brief Algorithm ID (algorithm name + configuration set name)
7
8\author Costas Andreopoulos <c.andreopoulos \at cern.ch>
9 University of Liverpool
10
11\created October 20, 2005
12
13\cpright Copyright (c) 2003-2025, The GENIE Collaboration
14 For the full text of the license visit http://copyright.genie-mc.org
15*/
16//____________________________________________________________________________
17
18#ifndef _ALGID_H_
19#define _ALGID_H_
20
21#include <string>
22#include <iostream>
23
25
26using std::string;
27using std::ostream;
28
29namespace genie {
30
31class AlgId;
32ostream & operator << (ostream & stream, const AlgId & alg);
33
34class AlgId {
35
36public:
37
38 AlgId();
39 AlgId(string name, string config);
40 AlgId(const AlgId & id);
41 AlgId(const RgAlg & registry_item);
42 ~AlgId();
43
44 string Name (void) const { return fName; }
45 string Config (void) const { return fConfig; }
46 string Key (void) const { return fKey; }
47
48 void SetId (string name, string config="");
49 void SetName (string name);
50 void SetConfig (string config);
51 void Copy (const AlgId & id);
52 void Copy (const RgAlg & registry_item);
53 void Print (ostream & stream) const;
54
55 friend ostream & operator << (ostream & stream, const AlgId & alg);
56
57private:
58
59 void Init (void);
60 void UpdateKey (void);
61
62 string fName; ///< Algorithm name (including namespaces)
63 string fConfig; ///< Configuration set name
64 string fKey; ///< Unique key: namespace::alg_name/alg_config
65};
66
67} // genie namespace
68
69#endif // _ALGID_H_
Algorithm ID (algorithm name + configuration set name)
Definition AlgId.h:34
void Init(void)
Definition AlgId.cxx:103
string fKey
Unique key: namespace::alg_name/alg_config.
Definition AlgId.h:64
string Config(void) const
Definition AlgId.h:45
void SetConfig(string config)
Definition AlgId.cxx:59
string Key(void) const
Definition AlgId.h:46
void UpdateKey(void)
Definition AlgId.cxx:93
string Name(void) const
Definition AlgId.h:44
string fConfig
Configuration set name.
Definition AlgId.h:63
void Print(ostream &stream) const
Definition AlgId.cxx:88
void Copy(const AlgId &id)
Definition AlgId.cxx:72
void SetName(string name)
Definition AlgId.cxx:54
string fName
Algorithm name (including namespaces)
Definition AlgId.h:62
void SetId(string name, string config="")
Definition AlgId.cxx:64
friend ostream & operator<<(ostream &stream, const AlgId &alg)
Definition AlgId.cxx:22
THE MAIN GENIE PROJECT NAMESPACE
Definition AlgCmp.h:25
ostream & operator<<(ostream &stream, const AlgConfigPool &config_pool)