SWMMVis  6.0.0-alpha.4
Qt6/C++ GIS-based graphical user interface for the SWMMVis engine (6.0.0-alpha.4)
Loading...
Searching...
No Matches
openswmmvis::ExtensionSaveOperation Class Referencefinal

Native RAII save scope; nested joined scopes leave completion to their owner. More...

#include <extensionstateregistry.h>

Collaboration diagram for openswmmvis::ExtensionSaveOperation:

Public Member Functions

 ExtensionSaveOperation (ExtensionStateRegistry *registry, const QList< QUuid > &sessions, OpenSWMM::Sdk::SaveKind kind, const QString &targetPath, QString *error=nullptr, bool joinExisting=false)
 Begin or join a correlated save scope.
 
 ~ExtensionSaveOperation ()
 End an owned operation with success or a captured/fallback failure diagnostic.
 
 ExtensionSaveOperation (const ExtensionSaveOperation &other)=delete
 Forbid copying a terminal-outcome responsibility.
 
ExtensionSaveOperation & operator= (const ExtensionSaveOperation &other)=delete
 Forbid assigning a terminal-outcome responsibility.
 
bool valid () const
 Check whether construction accepted an operation.
 
bool ownsOperation () const
 Inspect terminal-outcome ownership.
 
QUuid operationId () const
 Read the shared save correlation identity.
 
void setTargetPath (const QString &targetPath)
 Set a newly determined final destination on an owned outer operation.
 
void succeed ()
 Record successful native commit; outer destruction publishes the outcome.
 

Detailed Description

Native RAII save scope; nested joined scopes leave completion to their owner.

Constructor & Destructor Documentation

◆ ExtensionSaveOperation() [1/2]

openswmmvis::ExtensionSaveOperation::ExtensionSaveOperation ( ExtensionStateRegistry *  registry,
const QList< QUuid > &  sessions,
OpenSWMM::Sdk::SaveKind  kind,
const QString &  targetPath,
QString *  error = nullptr,
bool  joinExisting = false 
)

Begin or join a correlated save scope.

Parameters
[in]registryBorrowed application registry, guarded through callbacks.
[in]sessionsAffected open-lifetime identities.
[in]kindOuter transaction category.
[in]targetPathIntended final destination.
[in,out]errorOptional borrowed diagnostic destination, outliving this scope.
[in]joinExistingPermit a nested scope to join one shared outer operation.
Here is the call graph for this function:

◆ ~ExtensionSaveOperation()

openswmmvis::ExtensionSaveOperation::~ExtensionSaveOperation ( )

End an owned operation with success or a captured/fallback failure diagnostic.

◆ ExtensionSaveOperation() [2/2]

openswmmvis::ExtensionSaveOperation::ExtensionSaveOperation ( const ExtensionSaveOperation &  other)
delete

Forbid copying a terminal-outcome responsibility.

Parameters
[in]otherUnused noncopyable source.

Member Function Documentation

◆ operationId()

QUuid openswmmvis::ExtensionSaveOperation::operationId ( ) const

Read the shared save correlation identity.

Returns
Operation UUID or null after refused construction.

◆ operator=()

ExtensionSaveOperation & openswmmvis::ExtensionSaveOperation::operator= ( const ExtensionSaveOperation &  other)
delete

Forbid assigning a terminal-outcome responsibility.

Parameters
[in]otherUnused noncopyable source.
Returns
Assignment is unavailable.

◆ ownsOperation()

bool openswmmvis::ExtensionSaveOperation::ownsOperation ( ) const

Inspect terminal-outcome ownership.

Returns
True only for a newly created outer scope.
Here is the call graph for this function:
Here is the caller graph for this function:

◆ setTargetPath()

void openswmmvis::ExtensionSaveOperation::setTargetPath ( const QString &  targetPath)

Set a newly determined final destination on an owned outer operation.

Parameters
[in]targetPathFinal destination, such as a recovery sidecar selected after snapshotting.
Note
Joined nested scopes cannot replace their outer transaction's destination.
Here is the call graph for this function:

◆ succeed()

void openswmmvis::ExtensionSaveOperation::succeed ( )

Record successful native commit; outer destruction publishes the outcome.

Here is the caller graph for this function:

◆ valid()

bool openswmmvis::ExtensionSaveOperation::valid ( ) const

Check whether construction accepted an operation.

Returns
True for a surviving registry and accepted correlation identity.
Here is the caller graph for this function:

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