47 #include "SplatCloudBackup.hh" 61 splatCloudObject_( _object ),
62 splatCloudBackup_( 0 )
65 std::cerr <<
"Create SplatCloudBackup with name: \"" << name_.toStdString() <<
"\" (id: " << id_ <<
")." << std::endl;
72 std::cerr <<
"Could not create SplatCloudBackup with name: \"" << name_.toStdString() <<
"\" (id: " << id_ <<
") : SplatCloud not found." << std::endl;
76 splatCloudBackup_ =
new SplatCloud( *splatCloud );
78 if( splatCloudBackup_ == 0 )
80 std::cerr <<
"Could not create SplatCloudBackup with name: \"" << name_.toStdString() <<
"\" (id: " << id_ <<
") : Out of memory." << std::endl;
89 SplatCloudBackup::~SplatCloudBackup()
92 std::cerr <<
"Delete SplatCloudBackup with name: \"" << name_.toStdString() <<
"\" (id: " << id_ <<
")." << std::endl;
95 delete splatCloudBackup_;
107 # ifdef REPORT_BACKUP 108 std::cerr <<
"Apply SplatCloudBackup with name: \"" << name_.toStdString() <<
"\" (id: " << id_ <<
")." << std::endl;
113 if( splatCloud == 0 )
115 std::cerr <<
"Could not apply SplatCloudBackup with name: \"" << name_.toStdString() <<
"\" (id: " << id_ <<
") : SplatCloud not found." << std::endl;
119 if( splatCloudBackup_ == 0 )
121 std::cerr <<
"Could not apply SplatCloudBackup with name: \"" << name_.toStdString() <<
"\" (id: " << id_ <<
") : No backup available." << std::endl;
126 *splatCloud = *splatCloudBackup_;
Class that encapsulates a backup.
virtual void apply()
Revert this backup.
SplatCloud * splatCloud(BaseObjectData *_object)
Get a SplatCloud from an object.
void apply()
Revert this backup.