10Duke Scale C++ Client
Loading...
Searching...
No Matches
HTTPResponseToOAuthException.h
1#ifndef TENDUKE_OAUTH_HTTPRESPONSETOOAUTHEXCEPTION_H
2#define TENDUKE_OAUTH_HTTPRESPONSETOOAUTHEXCEPTION_H
3
4#include "http/HTTPResponseToException.h"
5#include "json/JSONParser.h"
6#include <memory>
7
8namespace tenduke { namespace oauth {
9
22{
23public:
28 explicit HTTPResponseToOAuthException(const std::shared_ptr<const tenduke::json::JSONParser> &parseJson);
29
30protected:
35 void from4xx(http::HTTPResponse &response) const override;
36
37private:
38 const std::shared_ptr<const tenduke::json::JSONParser> parseJSON;
39};
40
41}}
42
43#endif //TENDUKE_OAUTH_HTTPRESPONSETOOAUTHEXCEPTION_H
Utility service to throw an exception based on tenduke::http::HTTPResponse.
Definition HTTPResponseToException.h:18
A HTTP Response.
Definition HTTPResponse.h:15
Throws OAuthExceptions based on HTTP error response.
Definition HTTPResponseToOAuthException.h:22
void from4xx(http::HTTPResponse &response) const override
OAuth-specific handling for HTTP 4xx-errors.
Definition HTTPResponseToOAuthException.cpp:19
OAuth services.
Definition AccessTokenRequestAuthenticator.h:8
Root for classes, functions and globals of 10Duke C++ Client.
Definition BackendConfiguration.h:7