UDocumentation UE5.7 10.02.2026 (Source)
API documentation for Unreal Engine 5.7
PropertyPathFunctions.h
Go to the documentation of this file.
1// Copyright Epic Games, Inc. All Rights Reserved.
2
3#pragma once
4
5#include "CoreTypes.h"
7
8#define UE_API COREUOBJECT_API
9
10class FName;
11class FProperty;
12class UObject;
13class UStruct;
16
17namespace UE { class FPropertyPathName; }
18namespace UE { class FPropertyTypeName; }
19
20namespace UE
21{
22
23UE_API extern const FName NAME_Key;
24UE_API extern const FName NAME_Value;
25
34
46{
48 const FProperty* Property = nullptr;
50 const UStruct* Struct = nullptr;
52 void* Container = nullptr;
55
56 inline explicit operator bool() const
57 {
58 return !!Property;
59 }
60
62 template <typename ValueType>
63 inline ValueType* GetValuePtr() const
64 {
65 // A lambda template allows this to be defined with only a forward declaration of FProperty.
66 return [this]<typename PropertyType>(PropertyType* P)
67 {
69 }(Property);
70 }
71
73 inline bool IsDynamicContainerElement() const
74 {
75 return Struct == nullptr;
76 }
77};
78
86UE_API FPropertyValueInContainer TryResolvePropertyPath(const FPropertyPathName& Path, UObject* Object);
87
99UE_API FPropertyValueInContainer TryResolvePropertyPathForChangeEvent(const FPropertyPathName& Path, UObject* Object, uint32 ChangeType, TSharedPtr<FPropertyChangedChainEvent>& OutEvent, FEditPropertyChain& OutChain);
100
101} // UE
102
103#undef UE_API
@ INDEX_NONE
Definition CoreMiscDefines.h:150
FPlatformTypes::int32 int32
A 32-bit signed integer.
Definition Platform.h:1125
UE_FORCEINLINE_HINT TSharedRef< CastToType, Mode > StaticCastSharedRef(TSharedRef< CastFromType, Mode > const &InSharedRef)
Definition SharedPointer.h:127
const bool
Definition NetworkReplayStreaming.h:178
#define UE_API
Definition SColorGradingComponentViewer.h:12
uint32_t uint32
Definition binka_ue_file_header.h:6
Definition UnrealType.h:6738
Definition NameTypes.h:617
Definition UnrealType.h:174
Definition SharedPointer.h:692
Definition PropertyTypeName.h:46
Definition Object.h:95
Definition Class.h:480
Definition AdvancedWidgetsModule.cpp:13
FProperty * FindPropertyByNameAndTypeName(const UStruct *Struct, FName Name, FPropertyTypeName TypeName)
Definition PropertyPathFunctions.cpp:17
const FName NAME_Key(ANSITEXTVIEW("Key"))
Definition PropertyPathFunctions.h:23
const FName NAME_Value(ANSITEXTVIEW("Value"))
Definition PropertyPathFunctions.h:24
FPropertyValueInContainer TryResolvePropertyPath(const FPropertyPathName &Path, UObject *Object)
Definition PropertyPathFunctions.cpp:183
FPropertyValueInContainer TryResolvePropertyPathForChangeEvent(const FPropertyPathName &Path, UObject *Object, uint32 ChangeType, TSharedPtr< FPropertyChangedChainEvent > &OutEvent, FEditPropertyChain &OutChain)
Definition PropertyPathFunctions.cpp:188
Definition UnrealType.h:7001
Definition PropertyPathFunctions.h:46
bool IsDynamicContainerElement() const
Definition PropertyPathFunctions.h:73
int32 ArrayIndex
Definition PropertyPathFunctions.h:54
void * Container
Definition PropertyPathFunctions.h:52
const FProperty * Property
Definition PropertyPathFunctions.h:48
const UStruct * Struct
Definition PropertyPathFunctions.h:50
ValueType * GetValuePtr() const
Definition PropertyPathFunctions.h:63