10Duke Scale C++ Client
Loading...
Searching...
No Matches
tenduke::se::licensing::rest::AbstractLicenseRequest Class Reference

#include <AbstractLicenseRequest.h>

Detailed Description

Abstract base class for license-related requests.

Inheritance diagram for tenduke::se::licensing::rest::AbstractLicenseRequest:
tenduke::se::licensing::rest::DefaultLicenseCheckoutRequest tenduke::se::licensing::rest::DefaultLicenseHeartbeatRequest tenduke::se::licensing::rest::DefaultLicenseReleaseRequest

Public Member Functions

 AbstractLicenseRequest (std::string licenseKey, bool metered, const std::shared_ptr< const ::tenduke::se::ClientProperties > &clientProperties, const std::shared_ptr< const ::tenduke::se::BackendConfiguration > &configuration, 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.
 

Static Public Attributes

static const std::string NO_LICENSE_KEY
 Magic value to indicate that this is not a license key request.
 
static const bool METERED = true
 Magic value to indicate that this is metered license request.
 
static const bool NON_METERED = false
 Magic value to indicate that this is normal (not metered) license request.
 

Protected Member Functions

std::string getLicenseKey () const
 Returns license key.
 
bool hasLicenseKey () const
 Checks if this is license-key request.
 
bool isMetered () const
 Checks if this metered-request.
 

Protected Attributes

const std::shared_ptr< const ::tenduke::se::ClientPropertiesclientProperties
 Client properties.
 
const std::shared_ptr< const ::tenduke::se::BackendConfigurationconfiguration
 Config.
 
const std::shared_ptr< const ::tenduke::http::HTTPClienthttp
 HTTP-client.
 
const std::shared_ptr< const ::tenduke::http::HTTPRequestAuthenticatorhttpRequestAuthenticator
 HTTP-request authenticator.
 
const std::shared_ptr< const ::tenduke::http::HTTPResponseToExceptionthrowException
 Throw-exception.
 
const std::shared_ptr< const ::tenduke::json::JSONParserparseJSON
 Parses JSON.
 

Constructor & Destructor Documentation

◆ AbstractLicenseRequest()

tenduke::se::licensing::rest::AbstractLicenseRequest::AbstractLicenseRequest ( std::string  licenseKey,
bool  metered,
const std::shared_ptr< const ::tenduke::se::ClientProperties > &  clientProperties,
const std::shared_ptr< const ::tenduke::se::BackendConfiguration > &  configuration,
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.

Parameters
licenseKey-
metered-
clientProperties-
configuration-
httpClient-
httpRequestAuthenticator-
throwException-
jsonParser-

Member Function Documentation

◆ getLicenseKey()

std::string tenduke::se::licensing::rest::AbstractLicenseRequest::getLicenseKey ( ) const
protected

Returns license key.

Returns
license key. Returns nullptr if this is regular (non-license key) operation.

◆ hasLicenseKey()

bool tenduke::se::licensing::rest::AbstractLicenseRequest::hasLicenseKey ( ) const
protected

Checks if this is license-key request.

Returns
-

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