FDerivedDataCacheInterface

Interface for the derived data cache This API is fully threadsafe (with the possible exception of the system interface: NotfiyBootComplete, etc).

Unreal Engine C++ API Reference > Developer > DerivedDataCache

References

   
Module DerivedDataCache
Header /Engine/Source/Developer/DerivedDataCache/Public/DerivedDataCacheInterface.h
Include #include "DerivedDataCacheInterface.h"

Syntax

class FDerivedDataCacheInterface  

Remarks

Interface for the derived data cache This API is fully threadsafe (with the possible exception of the system interface: NotfiyBootComplete, etc).

Destructors

Type Name Description
  ~FDerivedDataCacheInterface ()  

Functions

Type Name Description
void AddToAsyncCompletionCounter ( int32 Addend ) Adds or subtracts a number from the thread safe counter which tracks outstanding async requests.
bool AllCachedDataProbablyExists ( TConstArrayView< FString > CacheKey... ) Returns true if the data associated with each key is likely to exist in the cache.
bool AnyAsyncRequestsRemaining () Are there any async DDC requests in progress?
FString BuildCacheKey ( FStringView PluginName, FStringView VersionString, FStringView PluginSpecificCacheKeyS... )  
FString BuildCacheKey ( const TCHAR* PluginName, const TCHAR* VersionString, const TCHAR* PluginSpecificCac... ) Static function to build a cache key out of the plugin name, versions and plugin specific info
bool CachedDataProbablyExists ( const TCHAR* CacheKey ) Returns true if the data associated with the key is likely to exist in the cache.
TBitArray CachedDataProbablyExistsBatch ( TConstArrayView< FString > CacheKey... ) Returns whether the data associated with each key is likely to exist in the cache.
void GatherAnalytics ( TArray< FAnalyticsEventAttribute > ... )  
void GatherResourceStats ( TArray< FDerivedDataCacheResourceSt... )  
void GatherSummaryStats ( FDerivedDataCacheSummaryStats& DDC... )  
void GatherUsageStats ( TMap< FString, FDerivedDataCacheUsa... ) Retrieve usage stats by the DDC
uint32 GetAsynchronous ( const TCHAR* CacheKey, FStringView DebugContext ) Starts the async process of checking the cache and if the item is present, retrieving the cached results.
uint32 GetAsynchronous ( FDerivedDataPluginInterface* D... ) Starts the async process of checking the cache and if the item is present, retrieving the cached results, otherwise telling the deriver to build the data and then updating the cache If the plugin does not support threading, all of the above will be completed before the call returns.
bool GetAsynchronousResults ( uint32 Handle, TArray64< uint8 >& OutData, bool* bDataWasBuilt )  
bool GetAsynchronousResults ( uint32 Handle, TArray< uint8 >& OutData, bool* bDataWasBuilt ) Retrieves the results from an async lookup / build.
FOnDDCNotifi... GetDDCNotificationEvent () Retrieve the event delegate for cache put notifications
const TCHAR ... GetDefaultGraphName () Retrieve the name of the 'default' graph, which may or may not be the active graph currently.
void GetDirectories ( TArray< FString >& OutResults ) Retrieve the directories used by the DDC
const TCHAR ... GetGraphName () Retrieve the name of the graph used when configuring DDC
bool GetSynchronous ( FDerivedDataPluginInterface* D..., TArray< uint8 >& OutData, bool* bDataWasBuilt ) Synchronously checks the cache and if the item is present, it returns the cached results, otherwise tells the deriver to build the data and then updates the cache
bool GetSynchronous ( const TCHAR* CacheKey, TArray64< uint8 >& OutData, FStringView DebugContext )  
bool GetSynchronous ( const TCHAR* CacheKey, TArray< uint8 >& OutData, FStringView DebugContext ) Synchronously checks the cache and if the item is present, it returns the cached results, otherwise it returns false.
bool GetUsingSharedDDC () Retrieve whether a Shared DDC is being used
bool IsDefaultGraph () Are we currently using the default graph configuration?
bool IsValidCacheChar ( const TCHAR C ) Returns true if character is valid in a DDC cache key without escaping
void MarkTransient ( const TCHAR* CacheKey ) Hint that the data associated with the key is transient and may be optionally purged from the cache.
void NotifyBootComplete () Notify the system that the boot process is complete and so we can write the boot cache and get rid of it
bool PollAsynchronousCompletion ( uint32 Handle ) Polls a previous GetAsynchronous get for completion.
void Put ( const TCHAR* CacheKey, TArrayView64< const uint8 > Data, FStringView DataContext, bool bPutEvenIfExists ) Puts data into the cache.
FString SanitizeCacheKey ( const TCHAR* CacheKey ) Static function to make sure a cache key contains only legal characters by using an escape
bool TryToPrefetch ( TConstArrayView< FString > CacheKey..., FStringView DebugContext ) Synchronous attempt to make sure the cached data will be available as optimally as possible.
void WaitAsynchronousCompletion ( uint32 Handle ) Blocks the current thread until an previous GetAsynchronous request is ready
void WaitForQuiescence ( bool bShutdown ) Wait for all outstanding async DDC operations to complete.

Enums

Type Name Description
Public enum EDDCNotification  

Typedefs

Name Description
FOnDDCNotification  

Constants

Name Description
ValidCacheKeyChars Low Level Static Helpers.

Deprecated Functions

Type Name Description
TSharedRef< ... GatherUsageStats () This overload of GatherUsageStats is temporary. Please use other overload.

Ask questions and help your peers Developer Forums

Write your own tutorials or read those from others Learning Library