Navigation
API > API/Plugins > API/Plugins/CineAssemblyToolsEditor
Helper class for scoping modifications to a Productions extended data. On destruction of the instance, Finish is called which will call update on the TargetProduction if it has not been already. Finish can also be called at any time if desired, and will not then be called on destruction.
Use of this class is to create a locally scoped instance before making any modifications, and allowing it to fall out of scope or manually calling Finish when you wish those updates to propogate.
eg. {if(FInstancedStruct*ExtendedData=Production.FindOrLoadExtendedData(*FMyStruct::StaticStruct())){FScopedModifyProductionExtendedDataModifyGuard(Production);...//ModifyExtendedData...}}
You can specify a specific ExtendedData UScriptStruct type to call update only for that type. If this is not provided at construction time, then all ExtendedData is updated on Finish.
| Name | FScopedModifyProductionExtendedData |
| Type | class |
| Header File | /Engine/Plugins/VirtualProduction/CinematicAssemblyTools/Source/CineAssemblyToolsEditor/Public/ScopedModifyProductionExtendedData.h |
| Include Path | #include "ScopedModifyProductionExtendedData.h" |
Syntax
class FScopedModifyProductionExtendedData
Constructors
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
| Default constructor that constructs into an inactive state. | ScopedModifyProductionExtendedData.h | ||
FScopedModifyProductionExtendedData
(
FCinematicProduction& InProduction |
Given a reference to a production, create a scoped modify instance. | ScopedModifyProductionExtendedData.h | |
FScopedModifyProductionExtendedData
(
FCinematicProduction& InProduction, |
Given a reference to a production and a specific data struct type, create a scoped modify instance. | ScopedModifyProductionExtendedData.h |
Destructors
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
virtual ~FScopedModifyProductionExtendedData() |
Destructor that will call Finish. | ScopedModifyProductionExtendedData.h |
Variables
Protected
| Name | Type | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|---|
| bHasFinished | bool | Whether this instance has had Finish called on it or not. | ScopedModifyProductionExtendedData.h | |
| bOriginalBlockValue | bool | Original value of the block flag for the production. | ScopedModifyProductionExtendedData.h | |
| TargetProduction | TStructView< FCinematicProduction > | View onto the target production object that is being modified. | ScopedModifyProductionExtendedData.h | |
| TargetStruct | TOptional< const UScriptStruct * > | Optional target struct type that is being updated as part of this modification. | ScopedModifyProductionExtendedData.h |
Functions
Public
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
void Finish() |
Finish this scoped modify and update the extended data on the target production. | ScopedModifyProductionExtendedData.h | |
bool IsActive () |
Returns if this instance is active. | ScopedModifyProductionExtendedData.h |