FPersistentObjectRef

This type is necessary because the blueprint system is destroying and creating CDOs at edit time (usually on compile, but also on load), but also stores user entered data in the CDO.

Windows
MacOS
Linux

References

Module

UnrealEd

Header

/Engine/Source/Editor/UnrealEd/Classes/Editor/Transactor.h

Include

#include "Editor/Transactor.h"

Syntax

struct FPersistentObjectRef

Remarks

This type is necessary because the blueprint system is destroying and creating CDOs at edit time (usually on compile, but also on load), but also stores user entered data in the CDO. We "need" changes to a CDO to persist across instances because as we undo and redo we need to apply changes to different instances of the CDO - alternatively we could destroy and create the CDO as part of a transaction (this alternative is the reason for the bunny ears around need).

DanO: My long term preference is for the editor to use a dynamic, mutable type (rather than the CDO) to store editor data. The CDO can then be re-instanced (or not) as runtime code requires.

Variables

Name Description

Public variable

FName

 

ComponentName

Public variable

UObject *

 

Object

Public variable

EReferenceType

 

ReferenceType

Public variable

TArray< FName >

 

SubObjectHierarchyID

Constructors

Name Description

Public function

FPersistentObjectRef()

Public function

FPersistentObjectRef

(
    UObject* InObject
)

Functions

Name Description

Public function Const

UObject *...

 

Get()

Operators

Name Description

Public function Const

UObject *...

 

operator->()

Enums

Name

Description

Public enum

EReferenceType

This enum represents all of the different special cases we are handling with this type:

Help shape the future of Unreal Engine documentation! Tell us how we're doing so we can serve you better.
Take our survey
Dismiss