#include <CeresEngine/Resource/ResourceHandle.hpp>
◆ ResourceHandleData() [1/2]
Creates a new resource handle data.
- Parameters
-
| manager | The resource manager that the handle belongs to. |
| uuid | The UUID for the resource. |
| resource | The pre-existing resource. Can be nullptr. |
◆ ResourceHandleData() [2/2]
Creates a new resource handle data.
- Parameters
-
| uuid | The UUID for the resource. |
| resource | The pre-existing resource. Can be nullptr. |
◆ ~ResourceHandleData()
| CeresEngine::ResourceHandleData::~ResourceHandleData |
( |
| ) |
|
Destroys the resource handle data and notifies the manager that it is being destroyed.
◆ getResource()
| Resource * CeresEngine::ResourceHandleData::getResource |
( |
| ) |
const |
|
inlinenoexcept |
The resource being managed by the resource handle, if any.
If set, it means that the resource is fully loaded and available for usage, if nullptr, then it means that the resource is not loaded.
◆ getResourcePointer()
| const ResourcePtr & CeresEngine::ResourceHandleData::getResourcePointer |
( |
| ) |
const |
|
inlinenoexcept |
The resource being managed by the resource handle, if any.
If set, it means that the resource is fully loaded and available for usage, if nullptr, then it means that the resource is not loaded.
◆ getUUID()
| const UUID & CeresEngine::ResourceHandleData::getUUID |
( |
| ) |
const |
|
inlinenoexcept |
The resource UUID the handle is representing.
Once set, the handle cannot represent another UUID.
◆ notifyStrongRelease()
| void CeresEngine::ResourceHandleData::notifyStrongRelease |
( |
| ) |
|
|
private |
◆ setResource()
| void CeresEngine::ResourceHandleData::setResource |
( |
ResourcePtr && |
resource | ) |
|
|
private |
Changes the resource instance.
- Parameters
-
| resource | The resource to change the handle to. |
◆ strongRelease()
| void CeresEngine::ResourceHandleData::strongRelease |
( |
| ) |
|
|
private |
◆ strongRetain()
| void CeresEngine::ResourceHandleData::strongRetain |
( |
| ) |
|
|
private |
◆ weakRelease()
| void CeresEngine::ResourceHandleData::weakRelease |
( |
| ) |
|
|
private |
◆ weakRetain()
| void CeresEngine::ResourceHandleData::weakRetain |
( |
| ) |
|
|
private |
◆ AbstractResourceHandle
◆ ResourceHandle
◆ ResourceManager
◆ WeakResourceHandle
◆ didLoadResource
An event fired whenever the resource is loaded.
◆ didUnloadResource
An event fired whenever the resource is unloaded.
◆ mReferenceCounter
| RefCounter CeresEngine::ResourceHandleData::mReferenceCounter |
|
private |
A reference counter that counts the number of total references (strong + weak) to the resource.
Once this counter reaches zero, the resource handle data is deallocated.
◆ mResource
The resource being managed by the resource handle, if any.
If set, it means that the resource is fully loaded and available for usage, if nullptr, then it means that the resource is not loaded.
◆ mResourceManager
The resource manager that the handle belongs to.
◆ mStrongReferenceCounter
| RefCounter CeresEngine::ResourceHandleData::mStrongReferenceCounter |
|
private |
A reference counter that counts the number of strong references to the resource.
Once this counter reaches zero, the resource will be unloaded by the system.
◆ mUUID
| const UUID CeresEngine::ResourceHandleData::mUUID |
|
private |
The resource UUID the handle is representing.
Once set, the handle cannot represent another UUID.
The documentation for this class was generated from the following file:
- /Users/Rogiel/Developer/CeresEngine/Engine/Sources/CeresEngine/Resource/ResourceHandle.hpp