summaryrefslogtreecommitdiff
path: root/indra/viewer_components/updater/llupdatechecker.h
diff options
context:
space:
mode:
authorWilliam Todd Stinson <stinson@lindenlab.com>2012-10-11 14:38:28 -0700
committerWilliam Todd Stinson <stinson@lindenlab.com>2012-10-11 14:38:28 -0700
commit52e306d575b38cb80fcda38efa83be32c251766b (patch)
treeee96da14e6984c79351daf3793e2e9926ca2b6b5 /indra/viewer_components/updater/llupdatechecker.h
parent4174e9be5ea6262d7ad27ab64805990fd13670ee (diff)
parent1709952adbb3ad3ba4eb7d5be39c0c67c389c7c5 (diff)
Pull and merge from https://bitbucket.org/lindenlab/viewer-development.
Diffstat (limited to 'indra/viewer_components/updater/llupdatechecker.h')
-rw-r--r--indra/viewer_components/updater/llupdatechecker.h34
1 files changed, 32 insertions, 2 deletions
diff --git a/indra/viewer_components/updater/llupdatechecker.h b/indra/viewer_components/updater/llupdatechecker.h
index d882169068..23f62a7c5e 100644
--- a/indra/viewer_components/updater/llupdatechecker.h
+++ b/indra/viewer_components/updater/llupdatechecker.h
@@ -29,6 +29,7 @@
#include <boost/shared_ptr.hpp>
+#include "llhttpclient.h"
//
// Implements asynchronous checking for updates.
@@ -36,7 +37,36 @@
class LLUpdateChecker {
public:
class Client;
- class Implementation;
+ class Implementation:
+
+ public LLHTTPClient::Responder
+ {
+ public:
+ Implementation(Client & client);
+ ~Implementation();
+ void checkVersion(std::string const & protocolVersion, std::string const & hostUrl,
+ std::string const & servicePath, std::string channel, std::string version);
+
+ // Responder:
+ virtual void completed(U32 status,
+ const std::string & reason,
+ const LLSD& content);
+ virtual void error(U32 status, const std::string & reason);
+
+ private:
+ static const char * sProtocolVersion;
+
+ Client & mClient;
+ LLHTTPClient mHttpClient;
+ bool mInProgress;
+ std::string mVersion;
+
+ std::string buildUrl(std::string const & protocolVersion, std::string const & hostUrl,
+ std::string const & servicePath, std::string channel, std::string version);
+
+ LOG_CLASS(LLUpdateChecker::Implementation);
+ };
+
// An exception that may be raised on check errors.
class CheckError;
@@ -48,7 +78,7 @@ public:
std::string const & servicePath, std::string channel, std::string version);
private:
- boost::shared_ptr<Implementation> mImplementation;
+ LLPointer<Implementation> mImplementation;
};