WIP. Database updater now has its own namespace and dedicated directory

This commit is contained in:
emeric
2014-07-01 23:43:49 +02:00
parent 7fd546eb44
commit 16d1194d61
35 changed files with 320 additions and 224 deletions
+44
View File
@@ -0,0 +1,44 @@
#ifndef DB_UPDATER_UPDATER_HPP
#define DB_UPDATER_UPDATER_HPP
#include "metadata/MetaData.hpp"
#include "database/DatabaseHandler.hpp"
#include "database/FileTypes.hpp"
#include "database/DatabaseHandler.hpp"
namespace DatabaseUpdater {
class Updater
{
public:
Updater(boost::filesystem::path db, MetaData::Parser& parser);
// Update database
void process();
private:
// void refresh(const WatchedDirectory& directory);
// Video
void refreshVideoDirectory( const boost::filesystem::path& directory );
void processVideoFile( const boost::filesystem::path& file);
// Audio
void removeMissingAudioFiles( void );
void refreshAudioDirectory( const boost::filesystem::path& directory);
void processAudioFile( const boost::filesystem::path& file);
Database::Path::pointer getAddPath(const boost::filesystem::path& path);
Database::Handler _db;
MetaData::Parser& _metadataParser;
}; // class Updater
} // DatabaseUpdater
#endif