ASAPCabinetFE
 
Loading...
Searching...
No Matches
vps_database_updater.h
Go to the documentation of this file.
1
13#ifndef VPS_DATABASE_UPDATER_H
14#define VPS_DATABASE_UPDATER_H // Header guard to prevent multiple inclusions
15
16#include <string> // For std::string to handle paths and URLs
17#include <fstream>
18#include "core/ui/loading_progress.h" // Structure for tracking update progress
19
31public:
40 VpsDatabaseUpdater(const std::string& vpsDbPath);
41
55 bool fetchIfNeeded(const std::string& lastUpdatedPath, const std::string& updateFrequency, LoadingProgress* progress = nullptr);
56
57private:
69 bool downloadVpsDb(const std::string& url, LoadingProgress* progress);
70
71 std::string vpsDbPath_;
72};
73
74#endif // VPS_DATABASE_UPDATER_H
Updates the VPS database file in ASAPCabinetFE.
Definition vps_database_updater.h:30
bool fetchIfNeeded(const std::string &lastUpdatedPath, const std::string &updateFrequency, LoadingProgress *progress=nullptr)
Fetches the VPS database if an update is needed.
Definition vps_database_updater.cpp:35
Defines the LoadingProgress struct for tracking loading state in ASAPCabinetFE.
Tracks the loading progress state for ASAPCabinetFE.
Definition loading_progress.h:33