Record Class InvalidLicenseState

java.lang.Object
java.lang.Record
com.inductiveautomation.ignition.common.licensing.InvalidLicenseState
All Implemented Interfaces:
LicenseState, Serializable

public record InvalidLicenseState(String cause) extends Record implements LicenseState
Relevant only for Edge and Maker editions. These editions may not be able to run some modules based on licensing restrictions. We can't hot-unload the modules anymore, but we can force the module licenses to "Trial Mode", which will effectively prevent them from doing anything useful while the invalid license state is in place.
See Also:
  • Constructor Details

    • InvalidLicenseState

      public InvalidLicenseState(String cause)
      Creates an instance of a InvalidLicenseState record class.
      Parameters:
      cause - the value for the cause record component
  • Method Details

    • getTrialExpirationDate

      public Date getTrialExpirationDate()
      Description copied from interface: LicenseState
      The Date at which this demo's trial period will expire, or expired at if already expired. Not relevant unless the LicenseMode is Demo.
      Specified by:
      getTrialExpirationDate in interface LicenseState
    • getLicenseMode

      public LicenseMode getLicenseMode()
      Specified by:
      getLicenseMode in interface LicenseState
      Returns:
      the LicenseMode for this given LicenseState.
    • getModuleLicense

      public LicenseDetails getModuleLicense()
      Specified by:
      getModuleLicense in interface LicenseState
      Returns:
      the LicenseDetails in effect for this LicenseState for this particular module. If the LicenseMode is not Activated this can be null.
    • getPlatformLicense

      public LicenseDetails getPlatformLicense()
      Specified by:
      getPlatformLicense in interface LicenseState
      Returns:
      the PlatformLicense in effect for this LicenseState. If the LicenseMode is not Activated this can be null.
    • isTrialExpired

      public boolean isTrialExpired()
      Technically this isn't quite accurate since "Trial Expired" generally means that a gateway's trial mode can be reset to 2 hours. But many, many systems have infrastructure built around the "Trial Expired" idea. This includes things like OPC status codes, EAM agent functionality, etc. Some of these systems still need to communicate with 8.1 gateways, which understand "Trial Expired" but not "Invalid license".
      Specified by:
      isTrialExpired in interface LicenseState
      Returns:
      True, indicating that a module should be functionally disabled.
    • toString

      public String toString()
      Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components.
      Specified by:
      toString in class Record
      Returns:
      a string representation of this object
    • hashCode

      public final int hashCode()
      Returns a hash code value for this object. The value is derived from the hash code of each of the record components.
      Specified by:
      hashCode in class Record
      Returns:
      a hash code value for this object
    • equals

      public final boolean equals(Object o)
      Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared with Objects::equals(Object,Object).
      Specified by:
      equals in class Record
      Parameters:
      o - the object with which to compare
      Returns:
      true if this object is the same as the o argument; false otherwise.
    • cause

      public String cause()
      Returns the value of the cause record component.
      Returns:
      the value of the cause record component