Developer Documentation
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Modules Pages
BackupInterface Class Reference

Interface class for backup handling. More...

#include <OpenFlipper/BasePlugin/BackupInterface.hh>

Inheritance diagram for BackupInterface:
BackupPlugin BSplineCurveSelectionPlugin BSplineSurfaceSelectionPlugin ComponentsPlugin DecimaterPlugin HoleFillerPlugin IsotropicRemesherPlugin MeshComparePlugin MeshObjectSelectionPlugin MeshRepairPlugin MovePlugin ObjectSelectionPlugin PolyLineSelectionPlugin RemesherPlugin SkeletonEditingPlugin SmootherPlugin SmootherPlugin SplatCloudObjectSelectionPlugin SubdividerPlugin TextureControlPlugin TopologyPlugin VolumeMeshSelectionPlugin

Interface definition for general Plugins

virtual void createBackup (int _objectid, QString _name, UpdateType _type=UPDATE_ALL)
 Tell Backup Plugin to create a backup. More...
 
virtual void createBackup (IdList _objectids, QString _name, std::vector< UpdateType > _types)
 Tell Backup Plugin to create a group backup. More...
 
virtual void undo (int _objectid)
 Tell Backup Plugin to undo the last action of an object. More...
 
virtual void redo (int _objectid)
 Tell Backup Plugin to redo the last action on an object. More...
 
virtual void undo ()
 Tell Backup Plugin to undo the last action. More...
 
virtual void redo ()
 Tell Backup Plugin to redo the last action. More...
 
virtual ~BackupInterface ()
 Destructor.
 
virtual void slotCreateBackup (int _objectid, QString _name, UpdateType _type=UPDATE_ALL)
 Backup for an object requested. More...
 
virtual void slotCreateBackup (IdList _objectids, QString _name, std::vector< UpdateType > _types)
 Backup for an object requested. More...
 
virtual void slotAboutToRestore (int _objectid)
 A given object will be restored. More...
 
virtual void slotRestored (int _objectid)
 Object fully restored. More...
 

Interface definition for Backup Plugins

These signals and slots have to be implemented if you create a plugin managing Backups ( A Backup plugin is already provided by OpenFlipper so you don't need to use these funcions).

virtual void aboutToRestore (int _objectid)
 Backup Plugin tells other Plugins that a restore will happen. More...
 
virtual void generateBackup (int _id, QString _name, UpdateType _type)
 This signal is emitted by a BackupPlugin and tells a TypePlugin to generate a backup. More...
 
virtual void restored (int _objectid)
 Backup Plugin tells other Plugins that a restore has happened. More...
 
virtual void slotUndo (int _objectid)
 Undo the last action of an object. More...
 
virtual void slotRedo (int _objectid)
 Redo the last action on an object. More...
 
virtual void slotUndo ()
 Undo the last action. More...
 
virtual void slotRedo ()
 Redo the last action. More...
 

Detailed Description

Interface class for backup handling.

Detailed description
This interface defines functions to implement backup and restore for objects or object groups.

Definition at line 68 of file BackupInterface.hh.

Member Function Documentation

virtual void BackupInterface::aboutToRestore ( int  _objectid)
inlinevirtualsignal

Backup Plugin tells other Plugins that a restore will happen.

Definition at line 200 of file BackupInterface.hh.

virtual void BackupInterface::createBackup ( int  _objectid,
QString  _name,
UpdateType  _type = UPDATE_ALL 
)
inlinevirtualsignal

Tell Backup Plugin to create a backup.

Plugins which supports backups can call this function if they want to create backups.
A Backup control Plugin will do the rest.

Parameters
_objectidIdentifier of the object to create the backup
_nameName of the Backup, to show the user what can be recovered
_typeThe type of the backup (e.g. UPDATE_SELECTION)

Reimplemented in BackupPlugin.

Definition at line 86 of file BackupInterface.hh.

virtual void BackupInterface::createBackup ( IdList  _objectids,
QString  _name,
std::vector< UpdateType _types 
)
inlinevirtual

Tell Backup Plugin to create a group backup.

Plugins which supports backups can call this function if they want to create group backups.
The backups specified here will be grouped together. They can only be reverted as one block and not one by one. they combine backups on multiple objects to a singe backup set.

A Backup control Plugin will do the rest.

Parameters
_objectidsIdentifier of the object to create the backup
_nameName of the Backup, to show the user what can be recovered
_typesThe types of the backups (e.g. UPDATE_SELECTION)

Definition at line 100 of file BackupInterface.hh.

virtual void BackupInterface::generateBackup ( int  _id,
QString  _name,
UpdateType  _type 
)
inlinevirtualsignal

This signal is emitted by a BackupPlugin and tells a TypePlugin to generate a backup.

Parameters
_idId of the added object
_nameName of the backup to generate
_typethe type of backup that needs to be done

Definition at line 257 of file BackupInterface.hh.

virtual void BackupInterface::redo ( int  _objectid)
inlinevirtual

Tell Backup Plugin to redo the last action on an object.

Plugins which supports backups can call this function if they want to restore backups.
A Backup control Plugin will do the rest.

Parameters
_objectidIdentifier of the object to restore

Definition at line 116 of file BackupInterface.hh.

virtual void BackupInterface::redo ( )
inlinevirtual

Tell Backup Plugin to redo the last action.

Plugins which supports backups can call this function if they want to restore backups.
A Backup control Plugin will do the rest.

Definition at line 130 of file BackupInterface.hh.

virtual void BackupInterface::restored ( int  _objectid)
inlinevirtual

Backup Plugin tells other Plugins that a restore has happened.

Definition at line 205 of file BackupInterface.hh.

virtual void BackupInterface::slotAboutToRestore ( int  _objectid)
inlineprivatevirtual

A given object will be restored.

This function is called before an object is restored from a backup. perObjectDatas and the object will be reset to the backup state after this function is called for all plugins.

If you have any pointers or references to the given object you have to clean them up here.

Parameters
_objectidIdentifier of the object which is about to be restored

Definition at line 167 of file BackupInterface.hh.

virtual void BackupInterface::slotCreateBackup ( int  _objectid,
QString  _name,
UpdateType  _type = UPDATE_ALL 
)
inlineprivatevirtualslot

Backup for an object requested.

This function will be called if a plugin requests a backup. You can also react on this event if you reimplement this function in your plugin.

Parameters
_objectidIdentifier of the object to create the backup
_nameName of the Backup, to show the user what can be recovered
_typeWhat has been updated (This can be used to restrict the backup to certain parts of the object)

Definition at line 143 of file BackupInterface.hh.

virtual void BackupInterface::slotCreateBackup ( IdList  _objectids,
QString  _name,
std::vector< UpdateType _types 
)
inlineprivatevirtual

Backup for an object requested.

This function will be called if a plugin requests a backup. You can also react on this event if you reimplement this function in your plugin.

Parameters
_objectidsIdentifiers of the object to create the backup
_nameName of the Backup, to show the user what can be recovered
_typesWhat has been updated (This can be used to restrict the backup to certain parts of the objects)

Definition at line 154 of file BackupInterface.hh.

virtual void BackupInterface::slotRedo ( int  _objectid)
inlineprivatevirtual

Redo the last action on an object.

This function has to be implemented in the backup management plugin. Normally this function is provided by the default backup plugin and should not be used! To restore data in your plugin use the slotRestore above.

Parameters
_objectidIdentifier of the object to restore

Definition at line 229 of file BackupInterface.hh.

virtual void BackupInterface::slotRedo ( )
inlineprivatevirtual

Redo the last action.

This function has to be implemented in the backup management plugin. Normally this function is provided by the default backup plugin and should not be used! To restore data in your plugin use the slotRestore above.

Definition at line 247 of file BackupInterface.hh.

virtual void BackupInterface::slotRestored ( int  _objectid)
inlineprivatevirtual

Object fully restored.

This function is called after an object and all data from other plugins is restored from a backup.

perObjectDatas and the object have been reset to the backup state.

Parameters
_objectidIdentifier of the object which is about to be restored

Definition at line 178 of file BackupInterface.hh.

virtual void BackupInterface::slotUndo ( int  _objectid)
inlineprivatevirtualslot

Undo the last action of an object.

This function has to be implemented in the backup management plugin. Normally this function is provided by the default backup plugin and should not be used! To restore data in your plugin use the slotRestore above.

Parameters
_objectidIdentifier of the object to restore

Definition at line 219 of file BackupInterface.hh.

virtual void BackupInterface::slotUndo ( )
inlineprivatevirtual

Undo the last action.

This function has to be implemented in the backup management plugin. Normally this function is provided by the default backup plugin and should not be used! To restore data in your plugin use the slotRestore above.

Definition at line 238 of file BackupInterface.hh.

virtual void BackupInterface::undo ( int  _objectid)
inlinevirtual

Tell Backup Plugin to undo the last action of an object.

Plugins which supports backups can call this function if they want to restore backups.
A Backup control Plugin will do the rest.

Parameters
_objectidIdentifier of the object to restore

Definition at line 108 of file BackupInterface.hh.

virtual void BackupInterface::undo ( )
inlinevirtual

Tell Backup Plugin to undo the last action.

Plugins which supports backups can call this function if they want to restore backups.
A Backup control Plugin will do the rest.

Definition at line 123 of file BackupInterface.hh.


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