Plasma Engine  2.0
Loading...
Searching...
No Matches
plLongOpControllerManager Class Referencefinal

The LongOp controller is active in the editor process and manages which long ops are available, running, etc. More...

#include <LongOpControllerManager.h>

Inheritance diagram for plLongOpControllerManager:

Classes

struct  ProxyOpInfo
 Holds all information about the proxy long op on the editor side. More...
 

Public Member Functions

void RegisterLongOp (const plUuid &documentGuid, const plUuid &componentGuid, const char *szLongOpType)
 Typically called by plLongOpsAdapter when a component that has an plLongOpAttribute is added to a scene.
 
void UnregisterLongOp (const plUuid &documentGuid, const plUuid &componentGuid, const char *szLongOpType)
 Typically called by plLongOpsAdapter when a component that has an plLongOpAttribute is removed from a scene.
 
void StartOperation (plUuid opGuid)
 Starts executing the given long op. Typically called by the plQtLongOpsPanel.
 
void CancelOperation (plUuid opGuid)
 Cancels a given long op. Typically called by the plQtLongOpsPanel.
 
void CancelAndRemoveAllOpsForDocument (const plUuid &documentGuid)
 Cancels and deletes all operations linked to the given document. Makes sure to wait for all canceled ops. Typically called by the plLongOpsAdapter when a document is about to be closed.
 
ProxyOpInfoGetOperation (const plUuid &opGuid)
 Returns a pointer to the given long op, or null if the GUID does not exist.
 
const plDynamicArray< plUniquePtr< ProxyOpInfo > > & GetOperations () const
 Gives access to all currently available long ops. Make sure the lock m_Mutex (of the plLongOpManager base class) while accessing this.
 
- Public Member Functions inherited from plLongOpManager
void Startup (plProcessCommunicationChannel *pCommunicationChannel)
 Needs to be called early to initialize the IPC channel to use.
 
void Shutdown ()
 Call this to shut down the IPC communication.
 

Public Attributes

plEvent< const plLongOpControllerEvent & > m_Events
 Events about the state of all available long ops.
 
- Public Attributes inherited from plLongOpManager
plMutex m_Mutex
 Publicly exposed mutex for some special cases.
 

Additional Inherited Members

- Protected Attributes inherited from plLongOpManager
plProcessCommunicationChannelm_pCommunicationChannel = nullptr
 
plEvent< constplProcessCommunicationChannel::Event & >::Unsubscriber m_Unsubscriber
 

Detailed Description

The LongOp controller is active in the editor process and manages which long ops are available, running, etc.

All available long ops are registered with the controller, typically automatically by the plLongOpsAdapter, although it is theoretically possible to register additional long ops.

Through the controller long ops can be started or canceled, which is exposed in the UI by the plQtLongOpsPanel.

Through the broadcast plLongOpControllerEvent, one can track the state of all long ops.

Member Function Documentation

◆ ProcessCommunicationChannelEventHandler()

void plLongOpControllerManager::ProcessCommunicationChannelEventHandler ( const plProcessCommunicationChannel::Event & e)
overrideprivatevirtual

Implements plLongOpManager.


The documentation for this class was generated from the following files: