UDocumentation UE5.7 10.02.2026 (Source)
API documentation for Unreal Engine 5.7
FFieldPath Struct Reference

#include <FieldPath.h>

+ Inheritance diagram for FFieldPath:

Public Member Functions

 FFieldPath ()=default
 
 FFieldPath (FField *InField)
 
COREUOBJECT_API void Generate (FField *InField)
 
COREUOBJECT_API void Generate (const TCHAR *InFieldPathString)
 
COREUOBJECT_API FFieldTryToResolvePath (UStruct *InCurrentStruct, EPathResolveType InResolveType=FFieldPath::UseStructIfOuterNotFound) const
 
void ResolveField (FFieldClass *ExpectedClass=FField::StaticClass(), UStruct *InCurrentStruct=nullptr, EPathResolveType InResolveType=FFieldPath::UseStructIfOuterNotFound) const
 
FFieldGetTyped (FFieldClass *ExpectedType, UStruct *InCurrentStruct=nullptr) const
 
bool IsPathToFieldEmpty () const
 
bool IsStale () const
 
void Reset ()
 
UE_FORCEINLINE_HINT bool operator== (const FFieldPath &InOther) const
 
UE_FORCEINLINE_HINT bool operator!= (const FFieldPath &InOther) const
 
COREUOBJECT_API FString ToString () const
 

Protected Types

enum  EPathResolveType { UseStructIfOuterNotFound = 0 , UseStructAlways = 1 }
 

Protected Member Functions

bool NeedsResolving () const
 
void ClearCachedField () const
 

Protected Attributes

FFieldResolvedField = nullptr
 
TWeakObjectPtr< UStructResolvedOwner
 
TArray< FNamePath
 

Friends

struct FGCInternals
 
template<class T >
struct TWeakFieldPtr
 
class FFieldPathProperty
 
COREUOBJECT_API friend FArchiveoperator<< (FArchive &Ar, FFieldPath &InOutPropertyPath)
 
uint32 GetTypeHash (const FFieldPath &InPropertyPath)
 

Member Enumeration Documentation

◆ EPathResolveType

Enumerator
UseStructIfOuterNotFound 
UseStructAlways 

Constructor & Destructor Documentation

◆ FFieldPath() [1/2]

FFieldPath::FFieldPath ( )
default

◆ FFieldPath() [2/2]

FFieldPath::FFieldPath ( FField InField)
inline

Member Function Documentation

◆ ClearCachedField()

void FFieldPath::ClearCachedField ( ) const
inlineprotected

Clears the cached value so that the next time Get() is called, it will be resolved again

◆ Generate() [1/2]

void FFieldPath::Generate ( const TCHAR InFieldPathString)

Generates path from the passed in field pointer

◆ Generate() [2/2]

void FFieldPath::Generate ( FField InField)

Generates path from the passed in field pointer

◆ GetTyped()

FField * FFieldPath::GetTyped ( FFieldClass ExpectedType,
UStruct InCurrentStruct = nullptr 
) const
inline

Gets the field represented by this FFieldPath

Parameters
ExpectedTypeExpected type of the resolved field
InCurrentStructStruct that's trying to resolve this field path
Returns
Field represented by this FFieldPath or null if it couldn't be resolved

◆ IsPathToFieldEmpty()

bool FFieldPath::IsPathToFieldEmpty ( ) const
inline

Returns true if the field path is empty (does not test if the owner is valid) This is usually used to verify if the reason behind this field being unresolved is because the owner is missing or the property couldn't be found.

◆ IsStale()

bool FFieldPath::IsStale ( ) const
inline

Slightly different than !IsValid(), returns true if this used to point to a FField, but doesn't any more and has not been assigned or reset in the mean time.

Returns
true if this used to point at a real object but no longer does.

◆ NeedsResolving()

bool FFieldPath::NeedsResolving ( ) const
inlineprotected

◆ operator!=()

UE_FORCEINLINE_HINT bool FFieldPath::operator!= ( const FFieldPath InOther) const
inline

◆ operator==()

UE_FORCEINLINE_HINT bool FFieldPath::operator== ( const FFieldPath InOther) const
inline

◆ Reset()

void FFieldPath::Reset ( )
inline

Reset the weak pointer back to the NULL state

◆ ResolveField()

void FFieldPath::ResolveField ( FFieldClass ExpectedClass = FField::StaticClass(),
UStruct InCurrentStruct = nullptr,
EPathResolveType  InResolveType = FFieldPath::UseStructIfOuterNotFound 
) const
inline

Tries to resolve the path and caches the result

Parameters
ExpectedClassExpected class of the resolved field
InCurrentStructStruct that's trying to resolve this field path

◆ ToString()

FString FFieldPath::ToString ( ) const

◆ TryToResolvePath()

FField * FFieldPath::TryToResolvePath ( UStruct InCurrentStruct,
FFieldPath::EPathResolveType  InResolveType = FFieldPath::UseStructIfOuterNotFound 
) const

Tries to resolve the path without caching the resolved pointer

Parameters
InCurrentStructStruct that's trying to resolve this field path
OutOwnerIndexObjectIndex of the Owner UObject
Returns
Resolved field or null

Friends And Related Symbol Documentation

◆ FFieldPathProperty

friend class FFieldPathProperty
friend

◆ FGCInternals

◆ GetTypeHash

uint32 GetTypeHash ( const FFieldPath InPropertyPath)
friend

Hash function.

◆ operator<<

COREUOBJECT_API friend FArchive & operator<< ( FArchive Ar,
FFieldPath InOutPropertyPath 
)
friend

◆ TWeakFieldPtr

template<class T >
friend struct TWeakFieldPtr
friend

Member Data Documentation

◆ Path

TArray<FName> FFieldPath::Path
protected

Path to the FField object from the innermost FField to the outermost UObject (UPackage)

◆ ResolvedField

FField* FFieldPath::ResolvedField = nullptr
mutableprotected

Untracked pointer to the resolved property

◆ ResolvedOwner

TWeakObjectPtr<UStruct> FFieldPath::ResolvedOwner
mutableprotected

The cached owner of this field. Even though implemented as a weak pointer, GC will keep a strong reference to it if exposed through UPROPERTY macro


The documentation for this struct was generated from the following files: