| LicenseSpring C++ SDK 7.32.0 Easily add Software Licensing to your application

Public Member Functions | Static Public Member Functions | List of all members
LicenseSpring::ConsumptionPeriod Class Reference

Class used for encapsulating LSConsumptionPeriod and converting cosumption period to/from string. More...

`#include <LicenseSpring/ConsumptionPeriod.h>`

## Public Member Functions
| ConsumptionPeriod ()
| Constructs ConsumptionPeriod with type ConsumptionPeriodNone. More...
| ConsumptionPeriod (LSConsumptionPeriod period)
| Constructs ConsumptionPeriod with given period type. More...
| operator LSConsumptionPeriod () const
std::string | toString () const
| Converts ConsumptionPeriode to a string. More...
std::string | toFormattedString () const
| Converts ConsumptionPeriode to a string, with first letter capitalized. More...

## Static Public Member Functions
static ConsumptionPeriod | fromString (const std::string &str)
| Converts string to ConsumptionPeriod. More...

## Detailed Description

Class used for encapsulating LSConsumptionPeriod and converting cosumption period to/from string.

Definition at line 10 of file ConsumptionPeriod.h.

## Constructor & Destructor Documentation

## ◆ ConsumptionPeriod() [1/2]

LicenseSpring::ConsumptionPeriod::ConsumptionPeriod | ( |  | ) |

Constructs ConsumptionPeriod with type ConsumptionPeriodNone.

## ◆ ConsumptionPeriod() [2/2]

LicenseSpring::ConsumptionPeriod::ConsumptionPeriod | ( | LSConsumptionPeriod | period | ) |

Constructs ConsumptionPeriod with given period type.

Parameters

  period | Consumption reset period

## Member Function Documentation

## ◆ fromString()

static ConsumptionPeriod LicenseSpring::ConsumptionPeriod::fromString | ( | const std::string & | str | ) |
| static

Converts string to ConsumptionPeriod.

Parameters

  str | String to convert to ConsumptionPeriod

Returns
  ConsumptionPeriod of corresponding string.

## ◆ operator LSConsumptionPeriod()

LicenseSpring::ConsumptionPeriod::operator LSConsumptionPeriod | ( |  | ) | const

## ◆ toString()

std::string LicenseSpring::ConsumptionPeriod::toString | ( |  | ) | const

Converts ConsumptionPeriode to a string.

Returns
  Corresponding string based on consumption reset period.

## ◆ toFormattedString()

std::string LicenseSpring::ConsumptionPeriod::toFormattedString | ( |  | ) | const

Converts ConsumptionPeriode to a string, with first letter capitalized.

Returns
  Same as toString(), but with first letter capitalized.

The documentation for this class was generated from the following file:

- LicenseSpring/ConsumptionPeriod.h