LicenseSpring C++ SDK  7.27.0
Easily add Software Licensing to your application
ConsumptionPeriod.h
Go to the documentation of this file.
1 #pragma once
2 
3 #include <string>
4 #include "APIDef.h"
5 #include "PODTypes.h"
6 
7 namespace LicenseSpring
8 {
11  {
12  public:
16  static ConsumptionPeriod fromString( const std::string& str );
17 
20 
24 
25  operator LSConsumptionPeriod() const;
26 
29  std::string toString() const;
30 
33  std::string toFormattedString() const;
34 
35  private:
36  LSConsumptionPeriod m_period;
37  };
38 }
#define LS_API
Macros that expands to dllexport, dllimport or nothing on non Windows platforms or in case of static ...
Definition: APIDef.h:22
LSConsumptionPeriod
Consumption period.
Definition: PODTypes.h:38
Class used for encapsulating LSConsumptionPeriod and converting cosumption period to/from string.
std::string toString() const
Converts ConsumptionPeriode to a string.
static ConsumptionPeriod fromString(const std::string &str)
Converts string to ConsumptionPeriod.
ConsumptionPeriod(LSConsumptionPeriod period)
Constructs ConsumptionPeriod with given period type.
std::string toFormattedString() const
Converts ConsumptionPeriode to a string, with first letter capitalized.
ConsumptionPeriod()
Constructs ConsumptionPeriod with type ConsumptionPeriodNone.