Photon Quantum 3.0.0

Public Member Functions | Public Attributes | List of all members
AssetDB Struct Reference

Represents an asset database. More...

Public Member Functions

 AssetDB (IResourceManager manager)
 Represents an asset database. More...
 
bool DisposeAsset (AssetGuid guid)
 Disposes the asset with the specified guid . More...
 
bool DisposeAsset (string path)
 Disposes an asset based on its path. More...
 
AssetObject FindAsset (AssetGuid guid)
 Finds an asset based on its GUID. More...
 
AssetObject FindAsset (string path)
 Finds an asset with the given path. More...
 
bool LoadAsset (AssetGuid guid)
 Loads the specified asset asynchronously. More...
 

Public Attributes

IEnumerable< AssetObject > LoadedAssets => ResourceManager.GetAllLoadedAssets()
 Returns all loaded assets. More...
 

Detailed Description

Represents an asset database.

Constructor & Destructor Documentation

◆ AssetDB()

AssetDB.AssetDB ( IResourceManager  manager)
inline

Represents an asset database.

This class is obsolete. Use the IResourceManager interface instead.

Member Function Documentation

◆ FindAsset() [1/2]

AssetObject AssetDB.FindAsset ( AssetGuid  guid)

Finds an asset based on its GUID.

Parameters
guidThe GUID of the asset to find.
Returns
The asset object with the specified GUID, or null if not found.

◆ FindAsset() [2/2]

AssetObject AssetDB.FindAsset ( string  path)

Finds an asset with the given path.

Parameters
pathThe path of the asset.
Returns
The asset object with the given path. Returns null if the asset was not found.

This method is obsolete. Use the IResourceManager.GetAsset method instead.

◆ LoadAsset()

bool AssetDB.LoadAsset ( AssetGuid  guid)

Loads the specified asset asynchronously.

Parameters
guidThe unique identifier of the asset to load.
Returns
A boolean indicating whether the asset was loaded successfully.

This method is obsolete. Use the IResourceManager.LoadAssetAsync method instead.

◆ DisposeAsset() [1/2]

bool AssetDB.DisposeAsset ( AssetGuid  guid)

Disposes the asset with the specified guid .

Parameters
guidThe GUID of the asset to dispose.
Returns
true if the asset was disposed successfully; otherwise, false.
See also
IResourceManager.DisposeAsset

◆ DisposeAsset() [2/2]

bool AssetDB.DisposeAsset ( string  path)

Disposes an asset based on its path.

Parameters
pathThe path of the asset to dispose.
Returns
true if the asset is disposed successfully; otherwise, false.

This method is obsolete. Use the IResourceManager.DisposeAsset method instead.

Member Data Documentation

◆ LoadedAssets

IEnumerable<AssetObject> AssetDB.LoadedAssets => ResourceManager.GetAllLoadedAssets()

Returns all loaded assets.