17 INLINE ConfigVariableString::
18 ConfigVariableString(
const std::string &name) :
20 _local_modified(initial_invalid_cache())
28 INLINE ConfigVariableString::
29 ConfigVariableString(
const std::string &name,
const std::string &default_value,
30 const std::string &description,
int flags) :
31 #ifdef PRC_SAVE_DESCRIPTIONS
36 _local_modified(initial_invalid_cache())
38 _core->set_default_value(default_value);
53 INLINE ConfigVariableString::
54 operator
const std::string & ()
const {
61 INLINE
const char *ConfigVariableString::
63 return get_value().c_str();
69 INLINE
bool ConfigVariableString::
77 INLINE
size_t ConfigVariableString::
85 INLINE
char ConfigVariableString::
86 operator [] (
size_t n)
const {
94 INLINE
bool ConfigVariableString::
95 operator == (
const std::string &other)
const {
102 INLINE
bool ConfigVariableString::
103 operator != (
const std::string &other)
const {
110 INLINE
bool ConfigVariableString::
111 operator < (
const std::string &other)
const {
126 INLINE
const std::string &ConfigVariableString::
128 TAU_PROFILE(
"const string &ConfigVariableString::get_value() const",
" ", TAU_USER);
129 if (!is_cache_valid(_local_modified)) {
138 INLINE std::string ConfigVariableString::
139 get_default_value()
const {
141 if (decl !=
nullptr) {
144 return std::string();
152 return get_string_word(n);
161 set_string_word(n, value);
const std::string & get_string_value() const
Returns the value assigned to this variable.
std::string get_word(size_t n) const
Returns the variable's nth value.
void set_string_value(const std::string &value)
Changes the value assigned to this variable.
void operator=(const std::string &value)
Reassigns the variable's local value.
This is a generic, untyped ConfigVariable.
This is a convenience class to specialize ConfigVariable as a string type.
set_value
Reassigns the variable's local value.
get_value
Returns the variable's value.
void set_word(size_t n, const std::string &value)
Reassigns the variable's nth value.
A single declaration of a config variable, typically defined as one line in a .prc file,...