Drag[en]gine Game Engine
1.21
|
Base file resource class. More...
#include <deFileResource.h>
Public Member Functions | |
Management | |
deVirtualFileSystem * | GetVirtualFileSystem () const |
Virtual file system or NULL if build from memory. More... | |
const decString & | GetFilename () const |
Filename or empty string if build from memory. More... | |
TIME_SYSTEM | GetModificationTime () const |
Modification time used to detect resources changing on disk while loaded. More... | |
void | SetModificationTime (TIME_SYSTEM modificationTime) |
Set modification time used to detect resources changing on disk while loaded. More... | |
bool | GetAsynchron () const |
Resource is asynchron. More... | |
void | SetAsynchron (bool asynchron) |
Set if resource is asynchron. More... | |
Internal Use Only | |
| |
bool | GetOutdated () const |
void | MarkOutdated () |
Public Member Functions inherited from deResource | |
deResourceManager * | GetResourceManager () const |
Resource manager or NULL if resource is leaking. More... | |
deEngine * | GetEngine () const |
Game engine object from resource manager. More... | |
deResource * | GetLLManagerPrev () const |
Previous resource in the resource manager linked list. More... | |
void | SetLLManagerPrev (deResource *resource) |
Set next resource in the resource manager linked list. More... | |
deResource * | GetLLManagerNext () const |
Next resource in the resource manager linked list. More... | |
void | SetLLManagerNext (deResource *resource) |
Set next resource in the resource manager linked list. More... | |
void | MarkLeaking () |
Marks the resource leaking. More... | |
deResource (deResourceManager *resourceManager) | |
Create resource. More... | |
Public Member Functions inherited from deObject | |
int | GetRefCount () const |
Reference count. More... | |
void | AddReference () |
Add reference increasing reference count by 1. More... | |
void | FreeReference () |
Decrease reference count by one and delete object if count reaches 0. More... | |
deObject () | |
Create object with reference count of 1. More... | |
Constructors and Destructors | |
deFileResource (deFileResourceManager *resourceManager, deVirtualFileSystem *vfs, const char *filename, TIME_SYSTEM modificationTime) | |
Create file resource. More... | |
virtual | ~deFileResource () |
Clean up file resource. More... | |
Additional Inherited Members | |
Public Types inherited from deResource | |
typedef deTObjectReference< deResource > | Ref |
Type holding strong reference. More... | |
Public Types inherited from deObject | |
typedef deTObjectReference< deObject > | Ref |
Type holding strong reference. More... | |
Protected Member Functions inherited from deResource | |
virtual | ~deResource () |
Clean up resource. More... | |
Protected Member Functions inherited from deObject | |
virtual | ~deObject () |
Clean up object. More... | |
Base file resource class.
Provides the basic class for all resources loadable from a file. The asynchron flag indicates if this resource is currently handled by the resource loader. Asynchron resources exist in a thread alongside the main thread and can require special treatment in single type modules.
deFileResource::deFileResource | ( | deFileResourceManager * | resourceManager, |
deVirtualFileSystem * | vfs, | ||
const char * | filename, | ||
TIME_SYSTEM | modificationTime | ||
) |
Create file resource.
|
protectedvirtual |
Clean up file resource.
|
inline |
Resource is asynchron.
|
inline |
Filename or empty string if build from memory.
|
inline |
Modification time used to detect resources changing on disk while loaded.
|
inline |
|
inline |
Virtual file system or NULL if build from memory.
void deFileResource::MarkOutdated | ( | ) |
void deFileResource::SetAsynchron | ( | bool | asynchron | ) |
Set if resource is asynchron.
void deFileResource::SetModificationTime | ( | TIME_SYSTEM | modificationTime | ) |
Set modification time used to detect resources changing on disk while loaded.