From 3175fbe96c91a2de6f687d5c6bfe0fc7f02a34f4 Mon Sep 17 00:00:00 2001 From: Gluzskiy Alexandr Date: Tue, 25 Aug 2015 15:16:12 +0300 Subject: server: use int for parameters id everywhere --- server/include/api_module_downloader.h | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'server/include/api_module_downloader.h') diff --git a/server/include/api_module_downloader.h b/server/include/api_module_downloader.h index 4a31085..ae91943 100644 --- a/server/include/api_module_downloader.h +++ b/server/include/api_module_downloader.h @@ -79,20 +79,20 @@ struct download_s { int id; std::string name; //id generated via download_add or via session restore and it's unique for current session and current dowloader int64_t size, downloaded, download_speed; //download size and size of downloaded data, also download speed all vars in bytes - std::map info_map; //any additional info provided by downloader module can be stored here + std::map info_map; //any additional info provided by downloader module can be stored here std::list content; //download content can be set for download, structure described above }; class module_downloader : public module_base { public: - virtual int add_download(std::map params) = 0; //add download, this function must return unique for current session and current downloader download id + virtual int add_download(std::map params) = 0; //add download, this function must return unique for current session and current downloader download id virtual bool stop_download(int download_id) = 0; //stop download by id received via add_download, return true on success, false otherwise virtual bool start_download(int download_id) = 0; //start download by id received via add_download, return true on success, false otherwise virtual bool delete_download(int download_id, bool delete_data = false) = 0; //delete download by id received via add_download, if "delete_data" is set, also remove all downloaded data from storage, return true on success, false otherwise - virtual bool execute_action_on_download(int download_id, std::string action_id) = 0; //execute module defined action on download, by id received via add_download - virtual std::list get_downloads(std::map params = std::map()) = 0; //this function must return list of downloads, additional options may be passed via params map - virtual download_s get_download_info(int download_id, std::map params = std::map()) = 0; //same as above, except this one is for single download, not a complete list + virtual bool execute_action_on_download(int download_id, int action_id) = 0; //execute module defined action on download, by id received via add_download + virtual std::list get_downloads(std::map params = std::map()) = 0; //this function must return list of downloads, additional options may be passed via params map + virtual download_s get_download_info(int download_id, std::map params = std::map()) = 0; //same as above, except this one is for single download, not a complete list }; -- cgit v1.2.3