44#include "GroupBackup.hh"
46#include <OpenFlipper/common/BackupData.hh>
51GroupBackup::GroupBackup(
IdList _objectIDs,
const QString& _name)
53 objectIDs_(_objectIDs)
58 for (
unsigned int i=0; i < objectIDs_.size(); ++i ){
69 backupData =
dynamic_cast< BackupData*
>(
object->objectData(OBJECT_BACKUPS));
73 if ( objectIDs_.size() > 1 )
77 backupIDs_.push_back(
id);
83GroupBackup::~GroupBackup(){
95const IdList& GroupBackup::objectIDs()
const{
101bool GroupBackup::contains(
int _objectid )
const{
102 return std::find(objectIDs_.begin(), objectIDs_.end(), _objectid) != objectIDs_.end();
std::vector< int > IdList
Standard Type for id Lists used for scripting.
Abstract class that is used to store backups.
void setLinks(IdList _objectIDs)
int currentID()
return the id of the current backup state
Class that encapsulates a backup.
bool hasObjectData(QString _dataName)
Checks if object data with given name is available.
void apply()
Revert this backup.
bool getObject(const int _identifier, BaseObject *&_object)
Get the object which has the given identifier.