#include <creaImageIOSQLiteTreeHandler.h>
#include <creaImageIOTreeHandlerImageAdder.h>
+#include <creaImageIOTimestampDatabaseHandler.h>
+#include <creaImageIOSynchronizer.h>
namespace creaImageIO
{
void AddDir(const std::string& handler, const std::string& path,
bool recurse);
+ ///Synchronizes the loaded data with the database. If remove is true the database will be updated, otherwise
+ ///only a warning sign will be issued
+ void Synchronize(bool update, TreeHandler* handler);
+
/// Prints the tree handled by the handler
void Print(const std::string& handler);
/// Returns the TreeHandler with a given name
TreeHandler* GetTreeHandler(const std::string& name) const;
+
+ /// Returns the TimestampDatabase
+ TimestampDatabaseHandler* GetTimestampDatabase() const;
///
SQLiteTreeHandler* GetLocalDatabase() { return mLocalDatabase; }
const std::string& GetUserSettingsDirectory();
void CreateUserSettingsDirectory();
const std::string& GetLocalDatabasePath();
+ const std::string& GetTimestampDatabasePath();
//=============================================
private:
SQLiteTreeHandler* mLocalDatabase;
+ TimestampDatabaseHandler* mTimestampDatabase;
TreeHandlerMapType mTreeHandlerMap;
+ Synchronizer* mSynchronizer;
std::string mCurrentDirectory;
std::string mHomeDirectory;
std::string mUserSettingsDirectory;
std::string mLocalDatabasePath;
+ std::string mTimestampDatabasePath;
TreeHandlerImageAdder mImageAdder;
};