![]() |
LicenseSpring C++ SDK
Easily add Software Licensing to your application
|
Class for storing settings when using a proxy server. More...
#include <LicenseSpring/ExtendedOptions.h>
Public Member Functions | |
ProxySettings ()=default | |
Default constructor for proxy settings. | |
ProxySettings (const std::string &proxy, const std::string &user, const std::string &password) | |
Constructor for proxy settings. | |
~ProxySettings () | |
Destructor for proxy settings. | |
bool | fetchProxySettings (const std::string &serviceURL, const std::string &credentialTarget, bool throwExceptions=false) |
Automatically fetch proxy URI and credentials. | |
void | setProxyUri (const std::string &uri) |
Setter for proxy URI. | |
const std::string & | getProxyUri () const |
Getter for proxy URI. | |
void | setUser (const std::string &user) |
Setter for proxy user. | |
const std::string & | getUser () const |
Getter for proxy user. | |
void | setPassword (const std::string &password) |
Setter for password. | |
const std::string & | getPassword () const |
Getter for password. | |
bool | isValid () const |
Checker for if proxy URI is specified (i.e. not empty). | |
Class for storing settings when using a proxy server.
Definition at line 59 of file ExtendedOptions.h.
|
default |
Default constructor for proxy settings.
LicenseSpring::ProxySettings::ProxySettings | ( | const std::string & | proxy, |
const std::string & | user, | ||
const std::string & | password | ||
) |
Constructor for proxy settings.
proxy | String of proxy URI |
user | String of user |
password | String of password |
LicenseSpring::ProxySettings::~ProxySettings | ( | ) |
Destructor for proxy settings.
bool LicenseSpring::ProxySettings::fetchProxySettings | ( | const std::string & | serviceURL, |
const std::string & | credentialTarget, | ||
bool | throwExceptions = false |
||
) |
Automatically fetch proxy URI and credentials.
Usable only on Windows.
Tries to automatically fetch PAC file and proxy settings specific to the LicenseSpring API URL. Otherwise fetches default WinHTTP proxy.
Also tries to fetch credential data through Windows Credential Manager.
serviceURL | License API URL |
credentialTarget | Proxy credentials name in Windows Credential Manager |
throwExceptions | Indicates whether this method should throw exceptions |
LicenseSpringException | If proxy is not set up or credentials don't exist |
Setter for proxy URI.
uri | String of proxy URI |
const std::string & LicenseSpring::ProxySettings::getProxyUri | ( | ) | const |
Getter for proxy URI.
Setter for proxy user.
user | String for proxy user |
const std::string & LicenseSpring::ProxySettings::getUser | ( | ) | const |
Getter for proxy user.
Setter for password.
password | String for password |
const std::string & LicenseSpring::ProxySettings::getPassword | ( | ) | const |
Getter for password.
bool LicenseSpring::ProxySettings::isValid | ( | ) | const |
Checker for if proxy URI is specified (i.e. not empty).