Module |
|
Header |
/Engine/Source/Editor/PropertyEditor/Public/DetailLayoutBuilder.h |
Include |
#include "DetailLayoutBuilder.h" |
TSharedRef< IPropertyHandle > GetProperty
(
const FName PropertyPath,
const UStruct * ClassOutermost,
FName InstanceName
) const
Gets a handle to a property which can be used to read and write the property value and identify the property in other detail customization interfaces. Instructions
struct MyStruct { int32 StaticArray[3]; float FloatVar; }
class MyActor { MyStruct Struct1; MyStruct Struct2; float MyFloat }
To access StaticArray at index 2 from Struct2 in MyActor, your path would be MyStruct.StaticArray[2]" and your instance name is "Struct2" To access MyFloat in MyActor you can just pass in "MyFloat" because the name of the property is unambiguous
Parameter |
Description |
---|---|
Path |
The path to the property. Can be just a name of the property or a path in the format outer.outer.value[optional_index_for_static_arrays] |
ClassOutermost |
Optional outer class if accessing a property outside of the current class being customized |
InstanceName |
Optional instance name if multiple FProperty's of the same type exist. such as two identical structs, the instance name is one of the struct variable names) Examples: |