LicenseSpring C++ SDK
Easily add Software Licensing to your application
Loading...
Searching...
No Matches
LicenseFeature.h
Go to the documentation of this file.
1#ifndef LS_C_LICENSE_FEATURE_H
2#define LS_C_LICENSE_FEATURE_H
3
4#include "../APIDef.h"
5#include "../PODTypes.h"
6#include <time.h>
7#include <stdbool.h>
8
9#ifdef __cplusplus
10extern "C"
11{
12#endif
13
14 LS_API typedef struct LSLicenseFeature
15 {
16 const char *(*toString)(struct LSLicenseFeature *self);
17
18 const char *(*code)(struct LSLicenseFeature *self);
19
20 const char *(*name)(struct LSLicenseFeature *self);
21
22 enum LSFeatureType (*featureType)(struct LSLicenseFeature *self);
23
25 struct LSLicenseFeature *self, const char *value);
26
27 int (*maxConsumption)(struct LSLicenseFeature *self);
28
29 int (*totalConsumption)(struct LSLicenseFeature *self);
30
31 int (*localConsumption)(struct LSLicenseFeature *self);
32
33 bool (*isOveragesAllowed)(struct LSLicenseFeature *self);
34
36
38
39 int (*maxOverages)(struct LSLicenseFeature *self);
40
42
44
45 struct tm (*expiryDate)(struct LSLicenseFeature *self);
46
47 struct tm (*expiryDateUtc)(struct LSLicenseFeature *self);
48
49 bool (*isExpired)(struct LSLicenseFeature *self);
50
51 const char *(*metadata)(struct LSLicenseFeature *self);
52
53 bool (*isFloating)(struct LSLicenseFeature *self);
54
55 bool (*isOfflineFloating)(struct LSLicenseFeature *self);
56
57 int32_t (*floatingTimeout)(struct LSLicenseFeature *self);
58
59 int32_t (*floatingUsers)(struct LSLicenseFeature *self);
60
61 int32_t (*floatingInUseCount)(struct LSLicenseFeature *self);
62
63 struct tm (*floatingEndDateTime)(struct LSLicenseFeature *self);
64
65 struct tm (*floatingEndDateTimeUtc)(struct LSLicenseFeature *self);
66
67 bool (*floatingIsExpired)(struct LSLicenseFeature *self);
68
69 void *inner;
70
72
74
76
77#ifdef __cplusplus
78} // end extern "C"
79#endif
80
81#endif // LS_C_LICENSE_FEATURE_H
#define LS_API
Definition APIDef.h:23
LS_API void FreeLSLicenseFeature(LSLicenseFeature *feature)
LS_API struct LSLicenseFeature LSLicenseFeature
LS_API LSLicenseFeature * CreateLSLicenseFeature()
LSFeatureType
Product feature type.
Definition PODTypes.h:18
LSConsumptionPeriod
Consumption period.
Definition PODTypes.h:36
struct tm(* expiryDate)(struct LSLicenseFeature *self)
bool(* floatingIsExpired)(struct LSLicenseFeature *self)
enum LSConsumptionPeriod(* consumptionPeriod)(struct LSLicenseFeature *self)
bool(* isResetConsumptionEnabled)(struct LSLicenseFeature *self)
int(* maxConsumption)(struct LSLicenseFeature *self)
bool(* isNegativeConsumptionAllowed)(struct LSLicenseFeature *self)
bool(* isUnlimitedConsumptionAllowed)(struct LSLicenseFeature *self)
bool(* isOveragesAllowed)(struct LSLicenseFeature *self)
int32_t(* floatingUsers)(struct LSLicenseFeature *self)
bool(* isFloating)(struct LSLicenseFeature *self)
enum LSFeatureType(* featureTypeFromString)(struct LSLicenseFeature *self, const char *value)
int32_t(* floatingInUseCount)(struct LSLicenseFeature *self)
int32_t(* floatingTimeout)(struct LSLicenseFeature *self)
int(* localConsumption)(struct LSLicenseFeature *self)
enum LSFeatureType(* featureType)(struct LSLicenseFeature *self)
struct tm(* expiryDateUtc)(struct LSLicenseFeature *self)
bool(* isOfflineFloating)(struct LSLicenseFeature *self)
struct tm(* floatingEndDateTimeUtc)(struct LSLicenseFeature *self)
int(* totalConsumption)(struct LSLicenseFeature *self)
int(* maxOverages)(struct LSLicenseFeature *self)
struct tm(* floatingEndDateTime)(struct LSLicenseFeature *self)
bool(* isExpired)(struct LSLicenseFeature *self)