4 #ifndef __KVNAMEDPARAMETER_H
5 #define __KVNAMEDPARAMETER_H
11 typedef const char* cstring;
100 template <
typename T>
137 void Set(
const char*,
const char*);
138 void Set(
const char*,
const std::string&);
143 void Set(
const char*);
144 void Set(
const std::string&);
157 template <
typename T>
162 a.very_unlikely_method_name();
164 template <
typename T>
168 template <
typename T>
206 template<>
inline int KVNamedParameter::Get<int>()
const
210 template<>
inline double KVNamedParameter::Get<double>()
const
214 template<>
inline bool KVNamedParameter::Get<bool>()
const
218 template<>
inline KVString KVNamedParameter::Get<KVString>()
const
222 template<>
inline TString KVNamedParameter::Get<TString>()
const
226 template<>
inline cstring KVNamedParameter::Get<cstring>()
const
230 template<>
inline std::string KVNamedParameter::Get<std::string>()
const
232 return std::string(GetString());
234 template<>
inline int KVNamedParameter::DefaultValue<int>()
238 template<>
inline double KVNamedParameter::DefaultValue<double>()
242 template<>
inline bool KVNamedParameter::DefaultValue<bool>()
246 template<>
inline TString KVNamedParameter::DefaultValue<TString>()
250 template<>
inline KVString KVNamedParameter::DefaultValue<KVString>()
254 template<>
inline cstring KVNamedParameter::DefaultValue<cstring>()
258 template<>
inline std::string KVNamedParameter::DefaultValue<std::string>()
285 template <
typename T>
#define ClassDefOverride(name, id)
Handles lists of named parameters with different types, a list of KVNamedParameter objects.
A generic named parameter storing values of different types.
Bool_t HasSameValueAs(const KVNamedParameter &) const
const Char_t * GetString() const
KVNamedParameter()
Default constructor.
void Set(const char *, const char *)
Bool_t IsEqual(const TObject *obj) const override
void Print(Option_t *opt="") const override
void Add(const KVNamedParameter &p)
Bool_t operator==(const KVNamedParameter &) const
const Char_t * GetSQLType() const
Double_t GetDouble() const
void WriteToEnv(TEnv *, const TString &p="")
Write parameter in TEnv, using optional prefix p as "p.[name]".
Double_t fNumber
used to store numerical (integer or floating-point) values
TString GetTString() const
Int_t Compare(const TObject *obj) const override
Compares numerical parameters for sorting lists (such as KVNameValueList)
virtual ~KVNamedParameter()
Destructor.
void Clear(Option_t *="") override
Removes the name and any assigned value.
void ls(Option_t *opt="") const override
Extension of ROOT TString class which allows backwards compatibility with ROOT v3....
Int_t TestBits(UInt_t f) const