v2.4
IOperation Interface Reference

This class contains functions to commit changes in objects to project. More...

Inheritance diagram for IOperation:

Public Member Functions

HRESULT Start ()
 Starts an operation. More...
 
HRESULT Apply ()
 Commits the changes made to objects. More...
 
HRESULT Rollback ()
 Discards any changes made to objects since the operation started. More...
 

Detailed Description

This class contains functions to commit changes in objects to project.

Use this class to edit Renga objects.

Changes are applied to objects only if the operation was started beforehand. A new operation cannot be started while there is an active operation in progress. (An active operation is an operation that has been started but has not been applied or rolled back yet).

When an operation is applied, all changes made to objects since the operation started get accepted. Each applied operation pushes a new record into Renga's undo queue, it allows the user to revert the changes.

This interface can be obtained through IModel.

Member Function Documentation

HRESULT IOperation::Apply ( )

Commits the changes made to objects.

Only active opertaions can be applied.

HRESULT IOperation::Rollback ( )

Discards any changes made to objects since the operation started.

It is impossible to roll the changes back after the operation is applied.

HRESULT IOperation::Start ( )

Starts an operation.

You should start an operation before modifying any model objects.