#include <urlfile_cache.h>
UrlFileCacheInterface offers helper functions to allow to access to files with unsupported URLSCHEMEs. E.g. preset:// wont work with openexr because this lib needs a valid utf8 character path and InputStreams cannot be used to virtualize the read. In that case you would write:
Static Public Member Functions | |
static MAXON_METHOD Bool | IsAccessible (const maxon::Url &url) |
static MAXON_METHOD Result< UrlFileCacheEntry > | FindOrCreateUrl (const Url &sourceUrl, const TimeValue &maxCacheTime=Seconds(1.0), URLFILECACHEFLAGS flags=URLFILECACHEFLAGS::NONE) |
static MAXON_METHOD Result< void > | FlushCache (const Url &url) |
Private Member Functions | |
MAXON_INTERFACE_NONVIRTUAL (UrlFileCacheInterface, MAXON_REFERENCE_NONE, "net.maxon.interface.urlfilecache") | |
|
private |
|
static |
Check if the url scheme is directly accessible via fopen().
[in] | url | Url to check. |
|
static |
Finds or creates a new UrlFileCacheEntry for the given source Url.
[in] | sourceUrl | Url to be cached. |
[in] | maxCacheTime | Time to wait until to delete the cache file after it's not needed anymore. |
[in] | flags | See URLFILECACHEFLAGS. |
|
static |
Flushes the url from the cache. Existing UrlFileCacheEntries keep alive until the last handle vanishes. Calling the FindOrCreateUrl will create a new cache file for this url.