Navigation
API > API/Plugins > API/Plugins/StructUtils
References
| Module | StructUtils |
| Header | /Engine/Plugins/Experimental/StructUtils/Source/StructUtils/Public/InstancedStruct.h |
| Include | #include "InstancedStruct.h" |
Syntax
USTRUCT&40;BlueprintType,
Meta&61;&40;HasNativeMake&61;"&47;Script&47;StructUtilsEngine.StructUtilsFunctionLibrary.MakeInstancedStruct"&41;&41;
struct FInstancedStruct
Remarks
FInstancedStruct works similarly as instanced UObject* property but is USTRUCTs.
Example:
FInstancedStructTest;
TArray
Variables
| Type | Name | Description | |
|---|---|---|---|
| TObjectPtr< const UScriptStruct > | ScriptStruct | ||
| uint8 * | StructMemory |
Constructors
| Type | Name | Description | |
|---|---|---|---|
FInstancedStruct
(
const UScriptStruct* InScriptStruct |
|||
FInstancedStruct
(
const FConstStructView InOther |
This constructor is explicit to avoid accidentally converting struct views to instanced structs (which would result in costly copy of the struct to be made). | ||
FInstancedStruct
(
const FInstancedStruct& InOther |
|||
FInstancedStruct
(
FInstancedStruct&& InOther |
|||
FInstancedStruct
(
const UScriptStruct* InScriptStruct, |
Destructors
| Type | Name | Description | |
|---|---|---|---|
Functions
| Type | Name | Description | |
|---|---|---|---|
| void | AddStructReferencedObjects
(
FReferenceCollector& Collector |
||
| bool | ExportTextItem
(
FString& ValueStr, |
||
| bool | FindInnerPropertyInstance
(
FName PropertyName, |
||
| const T & | Get () |
Returns const reference to the struct, this getter assumes that all data is valid. | |
| const uint8 * | GetMemory () |
Returns const pointer to struct memory. | |
| T & | GetMutable () |
Returns mutable reference to the struct, this getter assumes that all data is valid. | |
| uint8 * | Returns a mutable pointer to struct memory. | ||
| T * | Returns mutable pointer to the struct, or nullptr if cast is not valid. | ||
| void | GetPreloadDependencies
(
TArray< UObject* >& OutDeps |
||
| const T * | GetPtr () |
Returns const pointer to the struct, or nullptr if cast is not valid. | |
| const UScriptStruct * | Returns struct type. | ||
| bool | Identical
(
const FInstancedStruct* Other, |
||
| bool | ImportTextItem
(
const TCHAR*& Buffer, |
||
| void | InitializeAs
(
TArgs&&... InArgs |
Initializes from struct type and emplace construct. | |
| void | InitializeAs
(
const UScriptStruct* InScriptStruct, |
Initializes from struct type and optional data. | |
| bool | IsValid () |
Returns True if the struct is valid. | |
| FInstancedStruct | Make
(
TArgs&&... InArgs |
Creates a new FInstancedStruct from the templated type and forward all arguments to constructor. | |
| FInstancedStruct | Make () |
Creates a new FInstancedStruct from templated struct type. | |
| FInstancedStruct | Make
(
const T& Struct |
Creates a new FInstancedStruct from templated struct. | |
| bool | NetSerialize
(
FArchive& Ar, |
||
| void | Reset () |
Reset to empty. | |
| void | |||
| bool | For StructOpsTypeTraits | ||
| bool | SerializeFromMismatchedTag
(
const FPropertyTag& Tag, |
||
| void | SetStructData
(
const UScriptStruct* InScriptStruct, |
Operators
| Type | Name | Description | |
|---|---|---|---|
| bool | operator!=
(
const FInstancedStruct& Other |
||
| FInstancedStruct & | operator=
(
const FConstStructView InOther |
||
| FInstancedStruct & | operator=
(
FInstancedStruct&& InOther |
||
| FInstancedStruct & | operator=
(
const FInstancedStruct& InOther |
||
| bool | operator==
(
const FInstancedStruct& Other |
Comparison operators. Deep compares the struct instance when identical. |