![]() |
Lumiera 0.pre.04~rc.1
»edit your freedom«
|
#include "steam/asset/db.hpp"
Implementation of the registry holding all Asset instances known to the Asset Manager subsystem.
As of 8/2007 implemented by a hashtable.
Public Member Functions | |
| template<class KIND > | |
| lib::P< KIND > | get (ID< KIND > hash) const |
| template<class KIND > | |
| void | put (ID< KIND > hash, lib::P< KIND > &ptr) |
| void | put (ID< Asset > hash, PAsset &ptr) |
| bool | del (ID< Asset > hash) |
| void | clear () |
| removes all registered assets and does something similar to Asset::unlink() on each to break cyclic dependencies (we can't use the real unlink()-function, because this will propagate, including calls to the AssetManager. | |
| void | asList (list< PcAsset > &output) const |
| intended for diagnostics | |
Friends | |
| class | lib::DependencyFactory< DB > |
Private Member Functions | |
| DB () | |
| ~DB () | |
| const PAsset & | find (size_t hash) const |
Private Member Functions inherited from NonCopyable | |
| ~NonCopyable ()=default | |
| NonCopyable ()=default | |
| NonCopyable (NonCopyable const &)=delete | |
| NonCopyable & | operator= (NonCopyable const &)=delete |
Private Attributes | |
| IdHashtable | table |
Additional Inherited Members | |
Static Public Member Functions inherited from Sync< CONF > | |
| static Monitor & | getMonitor (Sync const *forThis) |
Definition at line 108 of file db.hpp.
References DB::find(), and hash.
Referenced by AssetManager::getAsset(), WrappedStandardExeBuilder::invokeOriginalBuilder(), AssetManager::known(), AssetManager::known(), and AssetManager::wrap().
Here is the call graph for this function:
Here is the caller graph for this function:Definition at line 115 of file db.hpp.
References hash, and DB::table.
Referenced by AssetManager::reg().
Here is the caller graph for this function:Definition at line 127 of file db.hpp.
References hash, and DB::table.
Referenced by AssetManager::remove().
Here is the caller graph for this function:
|
inline |
removes all registered assets and does something similar to Asset::unlink() on each to break cyclic dependencies (we can't use the real unlink()-function, because this will propagate, including calls to the AssetManager.
As the destructor of DB needs to call clear(), this could result in segfaults. This doesn't seem to be a problem, though, because we register and process all assets and the net effect is just breaking any cyclic dependencies)
Definition at line 144 of file db.hpp.
References DB::table.
Referenced by AssetManager::clear().
Here is the caller graph for this function:
|
inline |
intended for diagnostics
Definition at line 159 of file db.hpp.
References DB::table.
Referenced by AssetManager::listContent().
Here is the caller graph for this function:
|
inlineprivate |
|
private |
Definition at line 91 of file db.hpp.
Referenced by DB::asList(), DB::clear(), DB::del(), DB::find(), DB::put(), and DB::put().
|
friend |
Inheritance diagram for DB:
Collaboration diagram for DB: