summaryrefslogtreecommitdiff
path: root/indra/viewer_components/updater/llupdatedownloader.h
diff options
context:
space:
mode:
authorAndrew A. de Laix <alain@lindenlab.com>2010-11-04 11:33:02 -0700
committerAndrew A. de Laix <alain@lindenlab.com>2010-11-04 11:33:02 -0700
commit7622ab9249506539894d0e33d4c2a8fd9fb3e3ac (patch)
treebb3624f4f01e5ef4f6a59a9356d560e3dd049db5 /indra/viewer_components/updater/llupdatedownloader.h
parent0f6c3a167850a34bad9982ed29eb25c141845320 (diff)
just barely working udate downloading service; missing little nicities like error checking and sill stuff like that.
Diffstat (limited to 'indra/viewer_components/updater/llupdatedownloader.h')
-rw-r--r--indra/viewer_components/updater/llupdatedownloader.h12
1 files changed, 9 insertions, 3 deletions
diff --git a/indra/viewer_components/updater/llupdatedownloader.h b/indra/viewer_components/updater/llupdatedownloader.h
index 9dc5d789ce..6118c4338e 100644
--- a/indra/viewer_components/updater/llupdatedownloader.h
+++ b/indra/viewer_components/updater/llupdatedownloader.h
@@ -27,6 +27,7 @@
#define LL_UPDATE_DOWNLOADER_H
+#include <stdexcept>
#include <string>
#include <boost/shared_ptr.hpp>
#include "lluri.h"
@@ -38,15 +39,19 @@
class LLUpdateDownloader
{
public:
+ class BusyError;
class Client;
class Implementation;
LLUpdateDownloader(Client & client);
- // Cancel any in progress download.
+ // Cancel any in progress download; a no op if none is in progress.
void cancel(void);
// Start a new download.
+ //
+ // This method will throw a BusyException instance if a download is already
+ // in progress.
void download(LLURI const & uri);
// Returns true if a download is in progress.
@@ -61,12 +66,13 @@ private:
// An interface to be implemented by clients initiating a update download.
//
class LLUpdateDownloader::Client {
+public:
// The download has completed successfully.
- void downloadComplete(void);
+ virtual void downloadComplete(void) = 0;
// The download failed.
- void downloadError(std::string const & message);
+ virtual void downloadError(std::string const & message) = 0;
};