FileAssetInterface Class Reference

#include <assets.h>

Inheritance diagram for FileAssetInterface:

Detailed Description

This interface represents a file asset, so a plain file (or directory) stored in an asset repository.

Public Member Functions

MAXON_METHOD const UrlGetUrl () const
 

Static Public Member Functions

static MAXON_METHOD Result< FileAsset > Create (const Url &url)
 

Private Member Functions

 MAXON_INTERFACE (FileAssetInterface, MAXON_REFERENCE_COPY_ON_WRITE, "net.maxon.interface.fileasset")
 

Member Function Documentation

◆ MAXON_INTERFACE()

MAXON_INTERFACE ( FileAssetInterface  ,
MAXON_REFERENCE_COPY_ON_WRITE  ,
"net.maxon.interface.fileasset"   
)
private

◆ GetUrl()

MAXON_METHOD const Url& GetUrl ( ) const

The Url to access the file which is wrapped by this asset.

Returns
The Url of the file (or directory).

◆ Create()

static MAXON_METHOD Result<FileAsset> Create ( const Url url)
static

Creates a new FileAsset for the given Url. The returned file asset doesn't belong to a repository, you have to store it afterwards at a repository. This will change the Url to a Url within the repository.

Parameters
[in]urlThe Url of the file (or directory) which shall be made an asset.
Returns
The FileAsset wrapping #url.