18INLINE ConfigVariableBase::
19ConfigVariableBase(
const std::string &name,
31INLINE ConfigVariableBase::
32~ConfigVariableBase() {
40 nassertr(_core !=
nullptr, *
new std::string());
41 return _core->get_name();
50 nassertr(_core !=
nullptr, VT_undefined);
51 return _core->get_value_type();
59 nassertr(_core !=
nullptr, *
new std::string());
60 return _core->get_description();
71 nassertr(_core !=
nullptr, 0);
72 return _core->get_flags();
86 nassertr(_core !=
nullptr,
false);
102 nassertr(_core !=
nullptr, 0);
103 return _core->get_trust_level();
113 nassertr(_core !=
nullptr,
false);
114 return _core->is_dynamic();
126 nassertr(_core !=
nullptr,
false);
127 return _core->clear_local_value();
136 nassertr(_core !=
nullptr,
false);
137 return _core->has_local_value();
146 nassertr(_core !=
nullptr,
false);
147 return _core->has_value();
153INLINE
void ConfigVariableBase::
154output(std::ostream &out)
const {
155 nassertv(_core !=
nullptr);
162INLINE
void ConfigVariableBase::
163write(std::ostream &out)
const {
164 nassertv(_core !=
nullptr);
170 variable.output(out);
This class is the base class for both ConfigVariableList and ConfigVariable (and hence for all of the...
get_name
Returns the name of the variable.
bool has_local_value() const
Returns true if this variable's value has been shadowed by a local assignment (as created via make_lo...
bool has_value() const
Returns true if this variable has an explicit value, either from a prc file or locally set,...
get_trust_level
Returns the minimum trust_level a prc file must demonstrate in order to redefine the value for this v...
int get_flags() const
Returns the flags value as set by set_flags().
is_dynamic
Returns true if the variable was indicated as "dynamic" by its constructor, indicating that its name ...
get_description
Returns the brief description of this variable, if it has been defined.
get_value_type
Returns the stated type of this variable.
is_closed
Returns true if the variable is not trusted by any prc file (and hence cannot be modified from its co...
bool clear_local_value()
Removes the local value defined for this variable, and allows its value to be once again retrieved fr...
is_closed
Returns true if the variable is not trusted by any prc file (and hence cannot be modified from its co...
A global object that maintains the set of ConfigVariables (actually, ConfigVariableCores) everywhere ...