LicenseSpring C++ SDK  7.31.0
Easily add Software Licensing to your application
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros
ExtendedOptions.h
Go to the documentation of this file.
1 #ifndef LS_C_EXTENDED_OPTIONS_H
2 #define LS_C_EXTENDED_OPTIONS_H
3 
4 #include "../APIDef.h"
5 #include "../PODTypes.h"
6 #include <stdbool.h>
7 #include <wchar.h>
8 #include <stdint.h>
9 
10 #ifdef __cplusplus
11 extern "C" {
12 #endif
13 
14  LS_API typedef struct LSProxySettings
15  {
16  void* inner;
17 
18  void ( *setProxyUri )( struct LSProxySettings* self, const char* uri );
19 
20  const char* ( *getProxyUri )( struct LSProxySettings* self );
21 
22  void ( *setUser )( struct LSProxySettings* self, const char* user );
23 
24  const char* ( *getUser )( struct LSProxySettings* self );
25 
26  void ( *setPassword )( struct LSProxySettings* self, const char* password );
27 
28  const char* ( *getPassword )( struct LSProxySettings* self );
29 
30  bool ( *isValid )( struct LSProxySettings* self );
31 
33 
34  LS_API LSProxySettings* CreateLSProxySettings( const char* proxy, const char* user, const char* password );
35 
36  LS_API void FreeLSProxySettings( LSProxySettings* settings );
37 
38 
39  LS_API typedef struct LSExtendedOptions
40  {
41  void* inner;
42 
43  void ( *setLicenseFilePath )( struct LSExtendedOptions* self, const wchar_t* filePath );
44 
45  const wchar_t* ( *getLicenseFilePath )( struct LSExtendedOptions* self );
46 
47  void ( *setHardwareID )( struct LSExtendedOptions* self, const char* ID );
48 
49  const char* ( *getHardwareID )( struct LSExtendedOptions* self );
50 
51  void ( *collectNetworkInfo )( struct LSExtendedOptions* self, bool collect );
52 
54 
55  void ( *enableLogging )( struct LSExtendedOptions* self, bool enable );
56 
57  bool ( *isLoggingEnabled )( struct LSExtendedOptions* self );
58 
59  void ( *enableVMDetection )( struct LSExtendedOptions* self, bool enable );
60 
61  bool ( *isVMDetectionEnabled )( struct LSExtendedOptions* self );
62 
63  void ( *enableGuardFile )( struct LSExtendedOptions* self, bool enable );
64 
65  bool ( *isGuardFileEnabled )( struct LSExtendedOptions* self );
66 
67  void ( *enableSSLCheck )( struct LSExtendedOptions* self, bool enable );
68 
69  bool ( *isSSLCheckEnabled )( struct LSExtendedOptions* self );
70 
71  void ( *setUseNativeTLS )( struct LSExtendedOptions* self, bool enable );
72 
73  bool ( *isNativeTLSEnabled )( struct LSExtendedOptions* self );
74 
75  void ( *setGracePeriod )( struct LSExtendedOptions* self, uint32_t value );
76 
77  uint32_t ( *getGracePeriod )( struct LSExtendedOptions* self );
78 
79  void ( *setNetworkTimeout )( struct LSExtendedOptions* self, long timeout );
80 
81  long ( *getNetworkTimeout )( struct LSExtendedOptions* self );
82 
83  void ( *setProxySettings )( struct LSExtendedOptions* self, const struct LSProxySettings* settings );
84 
85  const struct LSProxySettings* ( *getProxySettings )( struct LSExtendedOptions* self );
86 
87  void ( *setAlternateServiceURL )( struct LSExtendedOptions* self, const char* URL );
88 
89  const char* ( *getAlternateServiceURL )( struct LSExtendedOptions* self );
90 
91  void ( *setAlternateKey )( struct LSExtendedOptions* self, const char* key );
92 
93  void ( *setAlternateKeyInt )( struct LSExtendedOptions* self, int32_t* key, int32_t size );
94 
96 
97  void ( *setDeviceIdAlgorithm )( struct LSExtendedOptions* self, enum DeviceIDAlgorithm algorithm );
98 
100 
102 
103  LS_API LSExtendedOptions* CreateLSExtendedOptionsByPath( const wchar_t* licenseFilePath );
104 
105  LS_API LSExtendedOptions* CreateLSExtendedOptionsEx( const wchar_t* licenseFilePath, const char* hardwareID, const LSProxySettings* proxy );
106 
108 
109 #ifdef __cplusplus
110 } // end extern "C"
111 #endif
112 
113 #endif // LS_C_EXTENDED_OPTIONS_H
void(* enableSSLCheck)(struct LSExtendedOptions *self, bool enable)
LS_API LSExtendedOptions * CreateLSExtendedOptionsEx(const wchar_t *licenseFilePath, const char *hardwareID, const LSProxySettings *proxy)
void(* setAlternateServiceURL)(struct LSExtendedOptions *self, const char *URL)
void(* setLicenseFilePath)(struct LSExtendedOptions *self, const wchar_t *filePath)
bool(* isSSLCheckEnabled)(struct LSExtendedOptions *self)
void(* setAlternateKeyInt)(struct LSExtendedOptions *self, int32_t *key, int32_t size)
LS_API void FreeLSProxySettings(LSProxySettings *settings)
void(* setGracePeriod)(struct LSExtendedOptions *self, uint32_t value)
void(* setAlternateKey)(struct LSExtendedOptions *self, const char *key)
LS_API struct LSProxySettings LSProxySettings
void(* setDeviceIdAlgorithm)(struct LSExtendedOptions *self, enum DeviceIDAlgorithm algorithm)
LS_API struct LSExtendedOptions LSExtendedOptions
LS_API LSExtendedOptions * CreateLSExtendedOptionsByPath(const wchar_t *licenseFilePath)
LS_API LSProxySettings * CreateLSProxySettings(const char *proxy, const char *user, const char *password)
LS_API void FreeLSExtendedOptions(LSExtendedOptions *options)
enum DeviceIDAlgorithm(* getDeviceIdAlgorithm)(struct LSExtendedOptions *self)
void(* setNetworkTimeout)(struct LSExtendedOptions *self, long timeout)
void(* setUseNativeTLS)(struct LSExtendedOptions *self, bool enable)
DeviceIDAlgorithm
Type of Device ID algorithm used by the SDK.
Definition: PODTypes.h:103
void(* setProxyUri)(struct LSProxySettings *self, const char *uri)
void(* setProxySettings)(struct LSExtendedOptions *self, const struct LSProxySettings *settings)
bool(* isNativeTLSEnabled)(struct LSExtendedOptions *self)
bool(* isVMDetectionEnabled)(struct LSExtendedOptions *self)
bool(* isGuardFileEnabled)(struct LSExtendedOptions *self)
void(* enableLogging)(struct LSExtendedOptions *self, bool enable)
uint32_t(* getGracePeriod)(struct LSExtendedOptions *self)
bool(* isValid)(struct LSProxySettings *self)
void(* enableGuardFile)(struct LSExtendedOptions *self, bool enable)
LS_API LSExtendedOptions * CreateLSExtendedOptions()
void(* enableVMDetection)(struct LSExtendedOptions *self, bool enable)
void(* setUser)(struct LSProxySettings *self, const char *user)
#define LS_API
Macros that expands to dllexport, dllimport or nothing on non Windows platforms or in case of static ...
Definition: APIDef.h:22
void(* setPassword)(struct LSProxySettings *self, const char *password)
long(* getNetworkTimeout)(struct LSExtendedOptions *self)
void(* collectNetworkInfo)(struct LSExtendedOptions *self, bool collect)
bool(* isCollectNetworkInfoEnabled)(struct LSExtendedOptions *self)
void(* setHardwareID)(struct LSExtendedOptions *self, const char *ID)
bool(* isLoggingEnabled)(struct LSExtendedOptions *self)