Navigation
API > API/Developer > API/Developer/DerivedDataCache
Flags to control the behavior of cache requests.
Flags can be combined to cover a variety of requirements. Examples:
Get(Default): Fetch from any cache. Store the response to any caches if missing. Get(Local): Fetch from any local cache. Store the response to any local caches if missing. Get(Query | StoreLocal): Fetch from any cache. Store response to any local caches if missing. Get(Query | SkipData): Check for existence in any cache. Do not store to any caches if missing. Get(Default | SkipData): Check for existence in any cache. Store the response to any caches if missing. Get(Default | PartialRecord): Fetch from any cache, and return a partial record if values are missing data.
Put(Default): Store to every cache, and do not overwrite existing valid records or values. Put(Store): Store to every cache, and overwrite existing records or values. Put(Local): Store to every local cache, skipping remote caches. Put(Default | PartialRecord): Store to every cache, even if the record has missing data for its values.
| Name | UE::DerivedData::ECachePolicy |
| Type | enum |
| Header File | /Engine/Source/Developer/DerivedDataCache/Public/DerivedDataCachePolicy.h |
| Include Path | #include "DerivedDataCachePolicy.h" |
Syntax
namespace UE
{
namespace DerivedData
{
enum ECachePolicy
{
None = 0,
QueryLocal = 1 << 0,
QueryRemote = 1 << 1,
Query = QueryLocal | QueryRemote,
StoreLocal = 1 << 2,
StoreRemote = 1 << 3,
Store = StoreLocal | StoreRemote,
Local = QueryLocal | StoreLocal,
Remote = QueryRemote | StoreRemote,
Default = Query | Store,
SkipData = 1 << 4,
SkipMeta = 1 << 5,
PartialRecord = 1 << 6,
KeepAlive = 1 << 7,
}
}
}
Values
| Name | Remarks |
|---|---|
| None | A value with no flags. Disables access to the cache unless combined with other flags. |
| QueryLocal | Allow a cache request to query local caches. |
| QueryRemote | Allow a cache request to query remote caches. |
| Query | Allow a cache request to query any caches. |
| StoreLocal | Allow cache records and values to be stored in local caches. |
| StoreRemote | Allow cache records and values to be stored in remote caches. |
| Store | Allow cache records and values to be stored in any caches. |
| Local | Allow cache requests to query and store records and values in local caches. |
| Remote | Allow cache requests to query and store records and values in remote caches. |
| Default | Allow cache requests to query and store records and values in any caches. |
| SkipData | Skip fetching the data for values. |
| SkipMeta | Skip fetching the metadata for record requests. |
| PartialRecord | Partial output will be provided with the error status when a required value is missing. |
| KeepAlive | Keep records and values in the cache for at least the duration of the session. |