diff options
author | Alexey Rusakov <Kitsune-Ral@users.sf.net> | 2021-08-23 09:12:39 +0200 |
---|---|---|
committer | Alexey Rusakov <Kitsune-Ral@users.sf.net> | 2021-08-23 09:12:39 +0200 |
commit | 2914657e594b46bcdc04d320732fa1799978c0a8 (patch) | |
tree | 18e47baa175a109e9a64491b35889ef4375264fd /lib/jobs/basejob.h | |
parent | 3cbc13a33c81a75e18c415bd31cc2156461ffa1f (diff) | |
parent | 93cee89f9a99e51275ac9cd304180499b0543eea (diff) | |
download | libquotient-2914657e594b46bcdc04d320732fa1799978c0a8.tar.gz libquotient-2914657e594b46bcdc04d320732fa1799978c0a8.zip |
Merge branch 'kitsune/deprecations'
Diffstat (limited to 'lib/jobs/basejob.h')
-rw-r--r-- | lib/jobs/basejob.h | 15 |
1 files changed, 9 insertions, 6 deletions
diff --git a/lib/jobs/basejob.h b/lib/jobs/basejob.h index 7ce4b808..29443c53 100644 --- a/lib/jobs/basejob.h +++ b/lib/jobs/basejob.h @@ -52,8 +52,6 @@ public: IncorrectRequestError = IncorrectRequest, IncorrectResponse, IncorrectResponseError = IncorrectResponse, - JsonParseError //< \deprecated Use IncorrectResponse instead - = IncorrectResponse, TooManyRequests, TooManyRequestsError = TooManyRequests, RateLimited = TooManyRequests, @@ -72,7 +70,11 @@ public: }; Q_ENUM(StatusCode) - using Data = RequestData; + using Data +#ifndef Q_CC_MSVC + Q_DECL_DEPRECATED_X("Use Quotient::RequestData instead") +#endif + = RequestData; /*! * This structure stores the status of a server call job. The status @@ -125,7 +127,8 @@ public: BaseJob(HttpVerb verb, const QString& name, const QString& endpoint, bool needsToken = true); BaseJob(HttpVerb verb, const QString& name, const QString& endpoint, - const QUrlQuery& query, Data&& data = {}, bool needsToken = true); + const QUrlQuery& query, RequestData&& data = {}, + bool needsToken = true); QUrl requestUrl() const; bool isBackground() const; @@ -330,8 +333,8 @@ protected: void setRequestHeaders(const headers_t& headers); const QUrlQuery& query() const; void setRequestQuery(const QUrlQuery& query); - const Data& requestData() const; - void setRequestData(Data&& data); + const RequestData& requestData() const; + void setRequestData(RequestData&& data); const QByteArrayList& expectedContentTypes() const; void addExpectedContentType(const QByteArray& contentType); void setExpectedContentTypes(const QByteArrayList& contentTypes); |