Commit 0ce22519 authored by Jan Möbius's avatar Jan Möbius
Browse files

Document base backup

git-svn-id: 383ad7c9-94d9-4d36-a494-682f7c89f535
parent b4e6cea8
......@@ -57,19 +57,59 @@ class DLLEXPORT BaseBackup
BaseBackup(QString _name);
/** \brief constructor
* @param _object Pointer to the object, this backup will belong to
* @param _name Name of the object
* @param _type Type of change which can be used to create more specific backups (e.g. selection only)
BaseBackup(BaseObjectData* _object, QString _name, UpdateType _type);
virtual ~BaseBackup();
/** \brief Revert this backup
* This function has to be implemented. It will be called when the backup should be restored.
* \note You have to call the BaseBackup::apply() first in your implementation of this function.
* You have to restore your backup to the corresponding object when this function gets called.
virtual void apply();
/** \brief Get the backups name)
QString name();
/** \brief Set links to corresponding backups
* Backups can be grouped together. The backups store the links to their group members via
* this function.
void setLinks(IdList _objectIDs);
/** \brief get id of this backup
* Automatically generated id for this backup.
int id();
/** \brief Returns if this backup is blocked
* When Backups are grouped together, they can not be reversed o their own but
* oly together with the others in that backup group. This flag indicates, that
* the backup is part of a group and can not be reversed on its own.
bool blocked();
//backup of the perObjectData objects
/// Backup of the perObjectData objects
std::vector< std::pair<QString, PerObjectData*> > objectDatas_;
BaseObjectData* object_;
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment