Mercurial > hg > orthanc-stone
comparison Framework/Toolbox/OrthancApiClient.h @ 309:14ef1227120f am-callable-and-promise
web services: better handling of failures
author | am@osimis.io |
---|---|
date | Fri, 28 Sep 2018 15:02:43 +0200 |
parents | b4abaeb783b1 |
children | aad37d0b6407 |
comparison
equal
deleted
inserted
replaced
307:be2660b6e40a | 309:14ef1227120f |
---|---|
133 const std::string& body, | 133 const std::string& body, |
134 MessageHandler<JsonResponseReadyMessage>* successCallback, | 134 MessageHandler<JsonResponseReadyMessage>* successCallback, |
135 MessageHandler<HttpErrorMessage>* failureCallback = NULL, | 135 MessageHandler<HttpErrorMessage>* failureCallback = NULL, |
136 Orthanc::IDynamicObject* payload = NULL); | 136 Orthanc::IDynamicObject* payload = NULL); |
137 | 137 |
138 // schedule a POST request expecting a JSON response. | |
139 void PostJsonAsyncExpectJson(const std::string& uri, | |
140 const Json::Value& data, | |
141 MessageHandler<JsonResponseReadyMessage>* successCallback, | |
142 MessageHandler<HttpErrorMessage>* failureCallback = NULL, | |
143 Orthanc::IDynamicObject* payload = NULL); | |
138 | 144 |
139 }; | 145 }; |
140 } | 146 } |