engine
 
载入中...
搜索中...
未找到
Public 成员函数 | 所有成员列表
ITransaction类 参考abstract

Interface for transactions. 更多...

#include <ITransaction.h>

Public 成员函数

virtual void Apply ()=0
 Applies the transaction.
 
virtual void BeginOperation ()=0
 BeginOperation should be called when a transaction or undo/redo starts
 
virtual bool ContainsPieObjects () const =0
 
virtual void EndOperation ()=0
 EndOperation should be called when a transaction is finalized or canceled or undo/redo ends
 
virtual void Finalize ()=0
 Called when this transaction is completed to finalize the transaction
 
virtual FTransactionContext GetContext () const =0
 Gets the full context for the transaction
 
virtual bool IsTransient () const =0
 Report if a transaction should be put in the undo buffer. 更多...
 
virtual void SaveArray (UObject *Object, class FScriptArray *Array, int32 Index, int32 Count, int32 Oper, int32 ElementSize, STRUCT_DC DefaultConstructor, STRUCT_AR Serializer, STRUCT_DTOR Destructor)=0
 Saves an array to the transaction. 更多...
 
virtual void SaveObject (UObject *Object)=0
 Saves an UObject to the transaction. 更多...
 
virtual void SetPrimaryObject (UObject *Object)=0
 Sets the transaction's primary object. 更多...
 
virtual void SnapshotObject (UObject *Object, TArrayView< const FProperty * > Properties)=0
 Snapshots a UObject within the transaction. 更多...
 
virtual void StoreUndo (UObject *Object, TUniquePtr< FChange > CustomChange)=0
 Stores a command that can be used to undo a change to the specified object. 更多...
 

详细描述

Interface for transactions.

Transactions are created each time an UObject is modified, for example in the Editor. The data stored inside a transaction object can then be used to provide undo/redo functionality.

成员函数说明

◆ ContainsPieObjects()

virtual bool ITransaction::ContainsPieObjects ( ) const
pure virtual
返回
if this transaction tracks PIE objects

◆ IsTransient()

virtual bool ITransaction::IsTransient ( ) const
pure virtual

Report if a transaction should be put in the undo buffer.

A transaction will be transient if it contains PIE objects or result in a no-op. If this returns true the transaction won't be put in the transaction buffer.

返回
true if the transaction is transient.

◆ SaveArray()

virtual void ITransaction::SaveArray ( UObject *  Object,
class FScriptArray *  Array,
int32  Index,
int32  Count,
int32  Oper,
int32  ElementSize,
STRUCT_DC  DefaultConstructor,
STRUCT_AR  Serializer,
STRUCT_DTOR  Destructor 
)
pure virtual

Saves an array to the transaction.

参数
ObjectThe object that owns the array.
ArrayThe array to save.
Index
Count
Oper
ElementSize
Serializer
Destructor
参见
SaveObject

◆ SaveObject()

virtual void ITransaction::SaveObject ( UObject *  Object)
pure virtual

Saves an UObject to the transaction.

参数
ObjectThe object to save.
参见
SaveArray

◆ SetPrimaryObject()

virtual void ITransaction::SetPrimaryObject ( UObject *  Object)
pure virtual

Sets the transaction's primary object.

参数
ObjectThe primary object to set.

◆ SnapshotObject()

virtual void ITransaction::SnapshotObject ( UObject *  Object,
TArrayView< const FProperty * >  Properties 
)
pure virtual

Snapshots a UObject within the transaction.

参数
ObjectThe object to snapshot.
PropertyThe optional list of properties that have potentially changed on the object (to avoid snapshotting the entire object).

◆ StoreUndo()

virtual void ITransaction::StoreUndo ( UObject *  Object,
TUniquePtr< FChange >  CustomChange 
)
pure virtual

Stores a command that can be used to undo a change to the specified object.

This may be called multiple times in the same transaction to stack up changes that will be rolled back in reverse order. No copy of the object itself is stored.

参数
ObjectThe object the undo change will apply to
CustomChangeThe change that can be used to undo the changes to this object.

该类的文档由以下文件生成: