Module com.gluonhq.charm.glisten
Class LicenseManager
- java.lang.Object
-
- com.gluonhq.impl.charm.glisten.license.LicenseManager
-
public class LicenseManager extends Object
-
-
Constructor Summary
Constructors Constructor Description LicenseManager()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static String
generateHash(String input)
static String
validateLicense(String charmVersion, License license, Runnable runIfInvalid)
Checks the license with the license server and runs the runnable if it's invalid.
-
-
-
Method Detail
-
validateLicense
public static String validateLicense(String charmVersion, License license, Runnable runIfInvalid)
Checks the license with the license server and runs the runnable if it's invalid. If the license is found to be valid, it is saved in license.file. If that file exists, the server is not contacted again.- Parameters:
charmVersion
- the charm version for which the license is checkedlicense
- the license key that is validatedrunIfInvalid
-- Returns:
-
-