Panda3D
|
This class is the base class of both ConfigVariable and ConfigVariableCore. More...
#include "configFlags.h"
Public Types | |
enum | ValueType { VT_undefined, VT_list, VT_string, VT_filename, VT_bool, VT_int, VT_double, VT_enum, VT_search_path, VT_int64 } |
enum | VariableFlags { F_trust_level_mask = 0x00000fff, F_open = 0x00001000, F_closed = 0x00002000, F_dynamic = 0x00004000, F_dconfig = 0x00008000 } |
Static Protected Member Functions | |
static AtomicAdjust::Integer | initial_invalid_cache () |
Returns a value that will be appropriate for initializing a local_modified value. | |
static void | invalidate_cache () |
Invalidates all of the global ConfigVariable caches in the world at once, by incrementing the global_modified counter. | |
static bool | is_cache_valid (AtomicAdjust::Integer local_modified) |
Returns true if the local object's cache is still valid (based on a comparison of the supplied local_modified value with the global_modified value). | |
static void | mark_cache_valid (AtomicAdjust::Integer &local_modified) |
Updates the indicated local_modified value so that the cache will appear to be valid, until someone next calls invalidate_cache(). |
This class is the base class of both ConfigVariable and ConfigVariableCore.
It exists only to provide a convenient name scoping for some enumerated values common to both classes.
Definition at line 29 of file configFlags.h.
AtomicAdjust::Integer ConfigFlags::initial_invalid_cache | ( | ) | [inline, static, protected] |
Returns a value that will be appropriate for initializing a local_modified value.
This value will indicate an invalid cache in the next call to is_cache_valid().
Definition at line 49 of file configFlags.I.
Referenced by ConfigVariableSearchPath::append_directory(), ConfigVariableSearchPath::append_path(), ConfigVariableSearchPath::clear_local_value(), ConfigVariableSearchPath::prepend_directory(), and ConfigVariableSearchPath::prepend_path().
void ConfigFlags::invalidate_cache | ( | ) | [inline, static, protected] |
Invalidates all of the global ConfigVariable caches in the world at once, by incrementing the global_modified counter.
Definition at line 61 of file configFlags.I.
Referenced by ConfigVariableCore::clear_local_value(), ConfigPageManager::delete_explicit_page(), ConfigPageManager::make_explicit_page(), ConfigPageManager::reload_implicit_pages(), ConfigDeclaration::set_bool_word(), ConfigDeclaration::set_double_word(), ConfigDeclaration::set_int64_word(), ConfigDeclaration::set_int_word(), NotifyCategory::set_severity(), ConfigDeclaration::set_string_value(), and ConfigDeclaration::set_string_word().
bool ConfigFlags::is_cache_valid | ( | AtomicAdjust::Integer | local_modified | ) | [inline, static, protected] |
Returns true if the local object's cache is still valid (based on a comparison of the supplied local_modified value with the global_modified value).
Definition at line 24 of file configFlags.I.
Referenced by ConfigVariableString::get_value(), ConfigVariableInt64::get_value(), ConfigVariableInt::get_value(), ConfigVariableDouble::get_value(), and ConfigVariableBool::get_value().
void ConfigFlags::mark_cache_valid | ( | AtomicAdjust::Integer & | local_modified | ) | [inline, static, protected] |
Updates the indicated local_modified value so that the cache will appear to be valid, until someone next calls invalidate_cache().
Definition at line 36 of file configFlags.I.
Referenced by ConfigVariableString::get_value(), ConfigVariableInt64::get_value(), ConfigVariableInt::get_value(), ConfigVariableDouble::get_value(), and ConfigVariableBool::get_value().