![]() |
nomlib
|
Descriptor of a file-based resource. More...
#include <ResourceFile.hpp>
Public Types | |
| enum | Type { Invalid = 0 , Graphic , Movie , Audio , TrueTypeFont , BitmapFont } |
| typedef ResourceFile | self_type |
Public Member Functions | |
| ResourceFile (void) | |
| Default constructor; initialize resource to an invalid state. | |
| virtual | ~ResourceFile (void) |
| Destructor. | |
| ResourceFile (const std::string &name) | |
| Construct an invalid resource. | |
| ResourceFile (const std::string &name, const std::string &file_path) | |
| Construct a minimal, but valid resource. | |
| ResourceFile (const std::string &name, const std::string &file_path, ResourceFile::Type type) | |
| Construct a complete resource. | |
| bool | operator< (const self_type &rhs) const |
| Lesser-than comparison method overload. | |
| bool | operator== (const self_type &rhs) const |
| Equality comparison method overload. | |
| bool | exists (void) const |
| Get the status of resource existence at the file-system level. | |
| const std::string & | name (void) const |
| Get the name of the resource. | |
| const std::string & | path (void) const |
| Get the absolute file path to the resource. | |
| ResourceFile::Type | type (void) const |
| Get the resource's type. | |
| bool | loaded (void) const |
| void | set_name (const std::string &name) |
| Set the resource's name. | |
| void | set_path (const std::string &file_path) |
| Set the resource's absolute file path. | |
| void | set_type (ResourceFile::Type type) |
| Set the resource's type. | |
| void | set_loaded (bool state) |
Public Attributes | |
| bool | loaded_ |
| Initialized resource object state. | |
Static Public Attributes | |
| static const ResourceFile | null |
Private Attributes | |
| std::string | name_ |
| The resource's referenced name (think: key). | |
| std::string | path_ |
| The absolute file path to the resource. | |
| ResourceFile::Type | type_ |
| The description of the resource. | |
Descriptor of a file-based resource.
Definition at line 43 of file ResourceFile.hpp.
| typedef ResourceFile nom::ResourceFile::self_type |
Definition at line 46 of file ResourceFile.hpp.
| enum nom::ResourceFile::Type |
Definition at line 50 of file ResourceFile.hpp.
| nom::ResourceFile::ResourceFile | ( | const std::string & | name | ) |
Construct an invalid resource.
| bool nom::ResourceFile::operator< | ( | const self_type & | rhs | ) | const |
Lesser-than comparison method overload.
| bool nom::ResourceFile::operator== | ( | const self_type & | rhs | ) | const |
Equality comparison method overload.
| ResourceFile::Type nom::ResourceFile::type | ( | void | ) | const |
Get the resource's type.
|
mutable |
Initialized resource object state.
Definition at line 135 of file ResourceFile.hpp.
|
private |
The resource's referenced name (think: key).
Definition at line 121 of file ResourceFile.hpp.
|
static |
Definition at line 48 of file ResourceFile.hpp.
|
private |
The absolute file path to the resource.
Definition at line 124 of file ResourceFile.hpp.
|
private |
The description of the resource.
Definition at line 127 of file ResourceFile.hpp.