Navigation
API > API/Runtime > API/Runtime/CoreUObject
FStructTracker is a utility class used to track and map UStruct types to indices, which are used in bitsets. It manages a mapping between UStruct instances and integer indices, allowing for efficient storage and querying of types in a bitset
The FStructTracker assigns an index to a given type the first time it encounters it
| Name | FStructTracker |
| Type | struct |
| Header File | /Engine/Source/Runtime/CoreUObject/Public/StructUtils/StructTypeBitSet.h |
| Include Path | #include "StructUtils/StructTypeBitSet.h" |
Syntax
struct FStructTracker
Derived Classes
Constructors
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
FStructTracker
(
const UStruct* InBaseType, |
StructUtils/StructTypeBitSet.h | ||
FStructTracker
(
const FStructTracker& |
StructUtils/StructTypeBitSet.h | ||
FStructTracker
(
FStructTracker&& |
StructUtils/StructTypeBitSet.h | ||
FStructTracker
(
const FBaseStructGetter& InBaseStructGetter |
The input parameter is a function that fetches the UStruct representing the base class for all the stored structs. | StructUtils/StructTypeBitSet.h |
Destructors
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
~FStructTracker() |
StructUtils/StructTypeBitSet.h |
Typedefs
| Name | Type | Remarks | Include Path |
|---|---|---|---|
| FBaseStructGetter | TFunction< UStruct *()> | StructUtils/StructTypeBitSet.h | |
| FTypeValidation | TFunction< bool(const UStruct *)> | StructUtils/StructTypeBitSet.h |
Variables
Protected
| Name | Type | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|---|
| BaseType | const UStruct * | StructUtils/StructTypeBitSet.h |
Functions
Public
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
| StructUtils/StructTypeBitSet.h | |||
TConstArrayView< TWeakObjectPtr< const T > > DebugGetAllStructTypes() |
StructUtils/StructTypeBitSet.h | ||
FName DebugGetStructTypeName
(
const int32 StructTypeIndex |
StructUtils/StructTypeBitSet.h | ||
void DebugResetStructTypeMappingInfo() |
Resets all struct type mapping information. Used for debugging and testing purposes. | StructUtils/StructTypeBitSet.h | |
int32 FindOrAddStructTypeIndex
(
const UStruct& InStructType |
Fetches the internal index representing the given UStruct instance. | StructUtils/StructTypeBitSet.h | |
int32 FindStructTypeIndex
(
const UStruct& InStructType |
StructUtils/StructTypeBitSet.h | ||
const UStruct * GetBaseType() |
Retrieves the base UStruct type used for validation. | StructUtils/StructTypeBitSet.h | |
const UStruct * GetStructType
(
const int32 StructTypeIndex |
Retrieves the UStruct type associated with a given index | StructUtils/StructTypeBitSet.h | |
int32 Num() |
Gets the number of registered struct types. | StructUtils/StructTypeBitSet.h | |
int32 Register
(
const UStruct& InStructType |
Registers the given UStruct with the struct tracker. | StructUtils/StructTypeBitSet.h | |
void Serialize
(
FArchive& Ar, |
Serializes the struct types bit array using the archive provided. | StructUtils/StructTypeBitSet.h |
Protected
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
int32 RegisterImplementation
(
const UStruct& InStructType, |
StructUtils/StructTypeBitSet.h |
Operators
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
FStructTracker & operator=
(
const FStructTracker& |
StructUtils/StructTypeBitSet.h | ||
FStructTracker & operator=
(
FStructTracker&& |
StructUtils/StructTypeBitSet.h |