1#ifndef LS_BASE_MANAGER_H
2#define LS_BASE_MANAGER_H
7#pragma warning( disable : 4251 )
115#pragma warning( pop )
#define LS_API
Macros that expands to dllexport, dllimport or nothing on non Windows platforms or in case of static ...
Base class for license management.
std::shared_ptr< DataHandler > m_dataHandler
void clearLocalStorage()
Remove local license, other files and folders created by LicenseSpring, usually should be called at a...
void reset()
Reset (delete) members.
void reconfigure(Configuration::ptr_t config)
Change current configuration.
const License::ptr_t getCurrentLicense()
Load license from local storage (if not yet loaded).
const std::wstring & dataLocation() const
Absolute folder path where LicenseSpring data is stored.
LicenseService * m_pLicenseService
BaseManager(const BaseManager &)=delete
std::wstring licenseFilePath() const
Return concatenated dataLocation() and licenseFileName().
std::wstring licenseFileName() const
Return license file name with extension, unless filename was explicitly set to be without extension.
Configuration::ptr_t currentConfig() const
Returns current configuration.
ProductDetails getProductDetails(bool includeLatestVersion=false)
Get basic information from the backend on product which corresponds to the current configuration.
License::ptr_t m_currentLicense
virtual ~BaseManager()
Destroy LicenseManger with current configuration.
Configuration::ptr_t m_config
const License::ptr_t reloadLicense()
Resets current license and loads it again from local storage.
void setLicenseFileName(const std::wstring &name)
Set license file name, it can be with or without extension.
BaseManager(Configuration::ptr_t config, LicenseStorage::ptr_t storage=nullptr)
Create and intialize license manager with given configuration.
void setDataLocation(const std::wstring &path)
Set absolute or relative path to folder where LicenseSpring data should be stored.
std::shared_ptr< Configuration > ptr_t
std::shared_ptr< License > ptr_t
std::shared_ptr< LicenseStorage > ptr_t
Class that encapsulates information about a product.