Package de.licenseapi

Class LicenseValidator


  • public class LicenseValidator
    extends Object
    • Constructor Detail

      • LicenseValidator

        public LicenseValidator​(String validationKey)
        Creates a new LicenseValidator with the given validation key.
        Parameters:
        validationKey - The validation key of your project. You can find it in the project settings.
    • Method Detail

      • retrieveLicense

        public License retrieveLicense​(String licenseKey)
        Retrieves the license from the license key.
        Parameters:
        licenseKey - The license key you want to validate
        Returns:
        a License object with the license information or null if the validation key is invalid.
      • setRetries

        public void setRetries​(int retries)
        Gets the current amount of retries. If the amount of retries is 0, the license will be validated once.
        Parameters:
        retries - the new amount of retries
      • getRetries

        public int getRetries()
        Gets the current amount of retries. If the amount of retries is 0, the license will be validated once.
        Returns:
        the current amount of retries
      • getValidationKey

        public String getValidationKey()
        Gets the current validation key
        Returns:
        the current validation key