Mercurial > hg > orthanc-stone
diff Framework/Toolbox/IWebService.h @ 58:468c48eaa01c wasm
refactoring
author | Sebastien Jodogne <s.jodogne@gmail.com> |
---|---|
date | Wed, 03 May 2017 17:35:52 +0200 |
parents | d20e25cfcf3a |
children | 288c948199e5 |
line wrap: on
line diff
--- a/Framework/Toolbox/IWebService.h Wed May 03 14:45:21 2017 +0200 +++ b/Framework/Toolbox/IWebService.h Wed May 03 17:35:52 2017 +0200 @@ -30,16 +30,18 @@ class IWebService : public boost::noncopyable { public: - class IRequestObserver : public boost::noncopyable + class ICallback : public boost::noncopyable { public: - virtual ~IRequestObserver() + virtual ~ICallback() { } - virtual void NotifyError(Orthanc::IDynamicObject* payload) = 0; + virtual void NotifyError(const std::string& uri, + Orthanc::IDynamicObject* payload) = 0; - virtual void NotifyAnswer(const std::string& answer, + virtual void NotifyAnswer(const std::string& uri, + const std::string& answer, Orthanc::IDynamicObject* payload) = 0; }; @@ -47,11 +49,11 @@ { } - virtual void ScheduleGetRequest(IRequestObserver& observer, + virtual void ScheduleGetRequest(ICallback& callback, const std::string& uri, Orthanc::IDynamicObject* payload) = 0; - virtual void SchedulePostRequest(IRequestObserver& observer, + virtual void SchedulePostRequest(ICallback& callback, const std::string& uri, const std::string& body, Orthanc::IDynamicObject* payload) = 0;