10Duke Scale C++ Client
Loading...
Searching...
No Matches
tenduke::se::licensing::rest::AbstractPagingAPIRequest< T > Class Template Reference

#include <AbstractPagingAPIRequest.h>

Detailed Description

template<class T>
class tenduke::se::licensing::rest::AbstractPagingAPIRequest< T >

Abstract base class for API-requests, which support paging.

Template Parameters
Ttype of the response.
Inheritance diagram for tenduke::se::licensing::rest::AbstractPagingAPIRequest< T >:
tenduke::se::licensing::rest::AbstractAPIRequestMixin< T >

Public Member Functions

 AbstractPagingAPIRequest (const std::string &baseUrl, const std::shared_ptr< const ::tenduke::http::HTTPClient > &httpClient, const std::shared_ptr< const ::tenduke::http::HTTPRequestAuthenticator > &httpRequestAuthenticator, const std::shared_ptr< const ::tenduke::http::HTTPResponseToException > &throwException, const std::shared_ptr< const ::tenduke::json::JSONParser > &jsonParser, ::tenduke::se::Paging paging)
 Constructs new instance.
 
- Public Member Functions inherited from tenduke::se::licensing::rest::AbstractAPIRequestMixin< T >
 AbstractAPIRequestMixin (std::string baseUrl, const std::shared_ptr< const ::tenduke::http::HTTPClient > &httpClient, const std::shared_ptr< const ::tenduke::http::HTTPRequestAuthenticator > &httpRequestAuthenticator, const std::shared_ptr< const ::tenduke::http::HTTPResponseToException > &throwException, const std::shared_ptr< const ::tenduke::json::JSONParser > &jsonParser)
 Constructs new instance.
 

Protected Member Functions

::tenduke::http::HTTPRequestBuildersetHeaders (::tenduke::http::HTTPRequestBuilder &request) const override
 Sets the paging headers to the request.
 
- Protected Member Functions inherited from tenduke::se::licensing::rest::AbstractAPIRequestMixin< T >
virtual T executeRequest ()
 Executes the request.
 
virtual T fromJSON (const std::string &responseBody) const =0
 Converts the response body from JSON to the response type.
 
virtual void buildUrl (::tenduke::net::URLBuilder &urlBuilder) const
 Builds the request URL.
 
virtual ::tenduke::http::HTTPRequestBuildersetHeaders (::tenduke::http::HTTPRequestBuilder &request) const
 Sets additional headers.
 

Additional Inherited Members

- Protected Attributes inherited from tenduke::se::licensing::rest::AbstractAPIRequestMixin< T >
const std::string baseUrl
 Base-URL for the request.
 
const std::shared_ptr< const ::tenduke::http::HTTPClienthttp
 HTTP-client to execute the request.
 
const std::shared_ptr< const ::tenduke::http::HTTPRequestAuthenticatorhttpRequestAuthenticator
 For authenticating the request.
 
const std::shared_ptr< const ::tenduke::http::HTTPResponseToExceptionthrowException
 Service to throw exceptions based on HTTP status codes.
 
const std::shared_ptr< const ::tenduke::json::JSONParserparseJSON
 For parsing the response payload.
 

Constructor & Destructor Documentation

◆ AbstractPagingAPIRequest()

template<class T >
tenduke::se::licensing::rest::AbstractPagingAPIRequest< T >::AbstractPagingAPIRequest ( const std::string &  baseUrl,
const std::shared_ptr< const ::tenduke::http::HTTPClient > &  httpClient,
const std::shared_ptr< const ::tenduke::http::HTTPRequestAuthenticator > &  httpRequestAuthenticator,
const std::shared_ptr< const ::tenduke::http::HTTPResponseToException > &  throwException,
const std::shared_ptr< const ::tenduke::json::JSONParser > &  jsonParser,
::tenduke::se::Paging  paging 
)
inline

Constructs new instance.

Parameters
baseUrl-
httpClient-
httpRequestAuthenticator-
throwException-
jsonParser-
paging-

Member Function Documentation

◆ setHeaders()

Sets the paging headers to the request.

Parameters
request-
Returns
-

The documentation for this class was generated from the following file: