CeresEngine 0.2.0
A game development framework
Loading...
Searching...
No Matches
CeresEngine::ImportedResource Struct Reference

A single resource imported by an importer. More...

#include <CeresEngine/Resource/Importer/ResourceImporter.hpp>

Public Member Functions

 ImportedResource ()=default
 Creates a new empty ImportedResource struct.
 
 ImportedResource (ResourcePtr resource, const UUID suggestedUUID={}, String suggestedName={})
 Creates a new ImportedResource struct from a Resource pointer.
 
template<typename T >
 ImportedResource (SPtr< T > resource, const UUID suggestedUUID={}, String suggestedName={})
 Creates a new ImportedResource struct from a Resource pointer.
 
 ImportedResource (HResource resource, const UUID suggestedUUID={}, String suggestedName={})
 Creates a new ImportedResource struct from a Resource pointer.
 
template<typename T >
 ImportedResource (ResourceHandle< T > resource, const UUID suggestedUUID={}, String suggestedName={})
 Creates a new ImportedResource struct from a Resource pointer.
 

Public Attributes

Variant< HResource, ResourcePtrresource
 The primary imported resource.
 
UUID suggestedUUID
 A suggested UUID for the resource.
 
String suggestedName
 A suggested name for the imported resource.
 

Detailed Description

A single resource imported by an importer.

This contains a reference to the resource itself and metadata that may, optionally, be used by the resource manager.

Constructor & Destructor Documentation

◆ ImportedResource() [1/5]

CeresEngine::ImportedResource::ImportedResource ( )
default

Creates a new empty ImportedResource struct.

◆ ImportedResource() [2/5]

CeresEngine::ImportedResource::ImportedResource ( ResourcePtr  resource,
const UUID  suggestedUUID = {},
String  suggestedName = {} 
)
inline

Creates a new ImportedResource struct from a Resource pointer.

◆ ImportedResource() [3/5]

template<typename T >
CeresEngine::ImportedResource::ImportedResource ( SPtr< T resource,
const UUID  suggestedUUID = {},
String  suggestedName = {} 
)
inline

Creates a new ImportedResource struct from a Resource pointer.

◆ ImportedResource() [4/5]

CeresEngine::ImportedResource::ImportedResource ( HResource  resource,
const UUID  suggestedUUID = {},
String  suggestedName = {} 
)
inline

Creates a new ImportedResource struct from a Resource pointer.

◆ ImportedResource() [5/5]

template<typename T >
CeresEngine::ImportedResource::ImportedResource ( ResourceHandle< T resource,
const UUID  suggestedUUID = {},
String  suggestedName = {} 
)
inline

Creates a new ImportedResource struct from a Resource pointer.

Member Data Documentation

◆ resource

Variant<HResource, ResourcePtr> CeresEngine::ImportedResource::resource

The primary imported resource.

◆ suggestedName

String CeresEngine::ImportedResource::suggestedName

A suggested name for the imported resource.

◆ suggestedUUID

UUID CeresEngine::ImportedResource::suggestedUUID

A suggested UUID for the resource.

Can be empty, in that case the UUID will be randomly generated and assigned to the resource. Note that this UUID is only a suggestion for the resource system, it may not use this UUID at all.


The documentation for this struct was generated from the following file: