Navigation
API > API/Plugins > API/Plugins/DataRegistry
Singleton manager that provides synchronous and asynchronous access to data registries
| Name | UDataRegistrySubsystem |
| Type | class |
| Header File | /Engine/Plugins/Runtime/DataRegistry/Source/DataRegistry/Public/DataRegistrySubsystem.h |
| Include Path | #include "DataRegistrySubsystem.h" |
Syntax
UCLASS (MinimalAPI, NotBlueprintType)
class UDataRegistrySubsystem : public UEngineSubsystem
Inheritance Hierarchy
- UObjectBase → UObjectBaseUtility → UObject → USubsystem → UDynamicSubsystem → UEngineSubsystem → UDataRegistrySubsystem
Typedefs
| Name | Type | Remarks | Include Path |
|---|---|---|---|
| FPreregisterAsset | TPair< FSoftObjectPath, int32 > | List of assets to attempt to register when data registries come online. | DataRegistrySubsystem.h |
| FRegistryMapPair | TPair< FName, TObjectPtr< UDataRegistry > > | DataRegistrySubsystem.h |
Constants
| Name | Type | Remarks | Include Path |
|---|---|---|---|
| SingletonSubSystem | TObjectPtr< UDataRegistrySubsystem > | Singleton object for the DataRegistrySubsystem::Get function to use, populated in Initialize and cleared out in Deinitialize | DataRegistrySubsystem.h |
Functions
Public
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
bool AcquireItem
(
const FDataRegistryId& ItemId, |
Start an async load of an item, delegate will be called on success or failure of acquire. | DataRegistrySubsystem.h | |
bool AreRegistriesInitialized() |
True if all registries should have been initialized | DataRegistrySubsystem.h | |
void DeinitializeAllRegistries() |
De-initializes all loaded registries | DataRegistrySubsystem.h | |
FDataRegistryCacheGetResult EvaluateCachedCurve
(
float& OutValue, |
Computes an evaluated curve value, as well as the actual curve if it is found. | DataRegistrySubsystem.h | |
void GetAllRegistries
(
TArray< UDataRegistry* >& AllRegistries, |
Gets list of all registries, useful for iterating in UI or utilities | DataRegistrySubsystem.h | |
const T * GetCachedItem
(
const FDataRegistryId& ItemId |
Returns a cached item of specified struct type. | DataRegistrySubsystem.h | |
FDataRegistryCacheGetResult GetCachedItemRaw
(
const uint8*& OutItemMemory, |
Gets the cached or precached data and struct type. | DataRegistrySubsystem.h | |
FDataRegistryCacheGetResult GetCachedItemRawFromLookup
(
const uint8*& OutItemMemory, |
Gets the cached or precached data and struct type using an async acquire result. | DataRegistrySubsystem.h | |
FText GetDisplayTextForId
(
FDataRegistryId ItemId |
Returns proper display text for an id, using the correct id format | DataRegistrySubsystem.h | |
UDataRegistry * GetRegistryForType
(
FName RegistryType |
Finds the right registry for a type name | DataRegistrySubsystem.h | |
bool IgnoreRegistryPath
(
const FSoftObjectPath& RegistryAssetPath |
Removes specific data registry asset from the registration map, can be undone with LoadRegistryPath | DataRegistrySubsystem.h | |
void InitializeAllRegistries
(
bool bResetIfInitialized |
Initializes all loaded registries and prepares them for queries | DataRegistrySubsystem.h | |
bool IsConfigEnabled
(
bool bWarnIfNotEnabled |
Returns true if the system is enabled via any config scan settings, will optionally warn if not enabled | DataRegistrySubsystem.h | |
bool IsReadyForInitialization() |
Returns true if the system is ready for initialization, if it hasn't started already | DataRegistrySubsystem.h | |
void LoadAllRegistries() |
Loads all registry assets and initializes them, this is called early in startup | DataRegistrySubsystem.h | |
bool LoadRegistryPath
(
const FSoftObjectPath& RegistryAssetPath |
Load and initialize a specific registry, useful for plugins. | DataRegistrySubsystem.h | |
FPreLoadAllDataRegistriesCallback & OnPreLoadAllDataRegistries() |
Accesses the delegate called before the subsystem has loaded data registries | DataRegistrySubsystem.h | |
FDataRegistrySubsystemInitializedCallback & OnSubsystemInitialized() |
Accesses the delegate called when the subsystem has finished scanning for and initializing all known data registries | DataRegistrySubsystem.h | |
void PreregisterSpecificAssets
(
const TMap< FDataRegistryType, TArray< FSoftObjectPath > >& AssetMap, |
Schedules registration of assets by path, this will happen immediately or will be queued if the data registries don't exist yet | DataRegistrySubsystem.h | |
void RefreshRegistryMap() |
Refreshes the active registry map based on what's in memory | DataRegistrySubsystem.h | |
bool RegisterSpecificAsset
(
FDataRegistryType RegistryType, |
Attempt to register a specified asset with all active sources that allow dynamic registration, returning true if anything changed. | DataRegistrySubsystem.h | |
void ReinitializeFromConfig() |
Handles changes to DataRegistrySettings while engine is running | DataRegistrySubsystem.h | |
void ResetRuntimeState() |
Resets state for all registries, call when gameplay has concluded to destroy caches | DataRegistrySubsystem.h | |
int32 UnregisterAssetsWithPriority
(
FDataRegistryType RegistryType, |
Unregisters all previously registered assets in a specific registry with a specific priority, can be used as a batch reset. | DataRegistrySubsystem.h | |
bool UnregisterSpecificAsset
(
FDataRegistryType RegistryType, |
Removes references to a specific asset, returns bool if it was removed | DataRegistrySubsystem.h | |
bool WantsDelayedDataRegistryLoadingUntilPIE() |
Returns true if the system will wait until first access to process pending Data Registry loads | DataRegistrySubsystem.h |
Protected
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
virtual void ApplyPreregisterMap
(
UDataRegistry* Registry |
DataRegistrySubsystem.h | ||
virtual void EndPIE
(
bool bStartSimulate |
DataRegistrySubsystem.h | ||
void FlushDeferredRegistryLoad
(
bool bExpected |
DataRegistrySubsystem.h | ||
virtual void PostAssetManager() |
DataRegistrySubsystem.h | ||
virtual void PostEngineInit() |
Initialization order, need to wait for other early-load systems to initialize. | DataRegistrySubsystem.h | |
virtual void PostGameplayTags() |
DataRegistrySubsystem.h | ||
virtual void PreBeginPIE
(
bool bStartSimulate |
DataRegistrySubsystem.h |
Overridden from USubsystem
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
virtual void Deinitialize() |
DataRegistrySubsystem.h | ||
virtual void Initialize
(
FSubsystemCollectionBase& Collection |
DataRegistrySubsystem.h |
Static
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
static bool AcquireItemBP
(
FDataRegistryId ItemId, |
Starts an asynchronous acquire of a data registry item that may not yet be cached, and then accessed with Get Data Registry Item From Lookup This function will only work properly if the data registry is set up for asynchronous querying. | DataRegistrySubsystem.h |
|
static void AddReferencedObjects
(
UObject* InThis, |
DataRegistrySubsystem.h | ||
static FString Conv_DataRegistryIdToString
(
FDataRegistryId DataRegistryId |
Converts a Data Registry Id to a string. | DataRegistrySubsystem.h |
|
static FString Conv_DataRegistryTypeToString
(
FDataRegistryType DataRegistryType |
Converts a Data Registry Type to a string. | DataRegistrySubsystem.h |
|
| Dumps out a text representation of every item in the registry | DataRegistrySubsystem.h | ||
static void DumpRegistryTypeSummary() |
Outputs all registered types and some info | DataRegistrySubsystem.h | |
static bool EqualEqual_DataRegistryId
(
FDataRegistryId A, |
Returns true if the values are equal (A == B) | DataRegistrySubsystem.h |
|
static bool EqualEqual_DataRegistryType
(
FDataRegistryType A, |
Returns true if the values are equal (A == B) | DataRegistrySubsystem.h |
|
static void EvaluateDataRegistryCurve
(
FDataRegistryId ItemId, |
Attempts to evaluate a curve stored in a DataRegistry cache using a specific input value | DataRegistrySubsystem.h |
|
static void FindCachedItemBP
(
FDataRegistryId ItemId, |
Attempts to get cached structure data stored in a DataRegistry, returning OutItem if the item is available. | DataRegistrySubsystem.h |
|
static void FindCachedItemFromLookupBP
(
FDataRegistryId ItemId, |
Attempts to get structure data stored in a DataRegistry cache after an async acquire, returning OutItem if the item is available. | DataRegistrySubsystem.h |
|
static UDataRegistrySubsystem * Get() |
Returns the global subsystem instance, this can return null during early engine startup and shutdown | DataRegistrySubsystem.h | |
static bool GetCachedItemBP
(
FDataRegistryId ItemId, |
Attempts to get cached structure data stored in a DataRegistry, modifying OutItem if the item is available. | DataRegistrySubsystem.h |
|
static bool GetCachedItemFromLookupBP
(
FDataRegistryId ItemId, |
Deprecated in favor of FindCachedItemFromLookupBP, but does still work properly | DataRegistrySubsystem.h |
|
static void GetPossibleDataRegistryIdList
(
FDataRegistryType RegistryType, |
Returns the list of known identifiers for an active data registry so they can be iterated with Find or Acquire. | DataRegistrySubsystem.h |
|
static bool IsValidDataRegistryId
(
FDataRegistryId DataRegistryId |
Returns true if this is a non-empty item identifier, does not check if it is currently registered | DataRegistrySubsystem.h |
|
static bool IsValidDataRegistryType
(
FDataRegistryType DataRegistryType |
Returns true if this is a non-empty type, does not check if it is currently registered | DataRegistrySubsystem.h |
|
static bool NotEqual_DataRegistryId
(
FDataRegistryId A, |
Returns true if the values are not equal (A != B) | DataRegistrySubsystem.h |
|
static bool NotEqual_DataRegistryType
(
FDataRegistryType A, |
Returns true if the values are not equal (A != B) | DataRegistrySubsystem.h |
|