10Duke Enterprise C++ Client
|
#include <BaseOAuthRequest.h>
Base OAuthRequest.
This base class has some common utility methods.
Protected Member Functions | |
BaseOAuthRequest (const std::string &scopes, const std::map< std::string, std::string > &additionalParameters, const std::shared_ptr< const ::tenduke::oauth::OAuthConfiguration > &config, const std::shared_ptr< const ::tenduke::http::HTTPClient > &http, const std::shared_ptr< const ::tenduke::json::JSONParser > &parseJson, const std::shared_ptr<::tenduke::time::Clock > &clock) | |
Constructs new instance. | |
virtual std::map< std::string, std::string > | buildTokenRequestParameters () const |
Builds base parameters for the token request. | |
virtual std::unique_ptr<::tenduke::oauth::OAuthTokenRequest > | createTokenRequest () const |
Creates the token request. | |
virtual std::unique_ptr<::tenduke::oauth::OAuthState > | handleTokenResponse (std::unique_ptr<::tenduke::oauth::OAuthTokenResponse > response) const |
Handles token response. | |
Protected Attributes | |
const std::string | scopes |
const std::map< std::string, std::string > | additionalParameters |
const std::shared_ptr< const ::tenduke::oauth::OAuthConfiguration > | config |
const std::shared_ptr< const ::tenduke::http::HTTPClient > | http |
const std::shared_ptr< const ::tenduke::json::JSONParser > | parseJSON |
const std::shared_ptr<::tenduke::time::Clock > | clock |
|
protected |
Constructs new instance.
scopes | - |
additionalParameters | - |
config | - |
http | - |
parseJson | - |
clock | - |
|
protectedvirtual |
Builds base parameters for the token request.
This method adds following common request parameters:
Reimplemented in tenduke::oauth::ccg::OAuthClientCredentialsGrantRequest, and tenduke::oauth::ropg::OAuthResourceOwnerPasswordRequest.
|
protectedvirtual |
Creates the token request.
|
protectedvirtual |
Handles token response.
response | the token response |