com.aptana.ide.core.licensing
Class ClientKey

java.lang.Object
  extended by com.aptana.ide.core.licensing.ClientKey

public final class ClientKey
extends java.lang.Object

Client Key


Field Summary
static java.lang.String BEGIN_LICENSE_MARKER
          BEGIN_LICENSE_MARKER
static java.lang.String END_LICENSE_MARKER
          END_LICENSE_MARKER
 
Method Summary
static ClientKey decrypt(java.lang.String encrypted, java.lang.String email)
          Decrypts an encrypted key string
 java.lang.String getEmail()
          Gets the email for this key
 java.util.Calendar getExpiration()
          Gets the expiration of this key
 boolean isCloseToExpiring()
          True if this key is close to expiring
 boolean isCloseToMatching()
          True if key has valid fields but email did not match
 boolean isExpired()
          True if this key is expired
 boolean isPro()
          True if pro key
 boolean isTrial()
          True if trial key
 boolean isValid()
          True if valid key
 boolean shouldProPluginsRun()
          True if professional plugins should run
static java.lang.String trimEncryptedLicense(java.lang.String encrypted)
          Gets the trimmed version of a license key
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

BEGIN_LICENSE_MARKER

public static final java.lang.String BEGIN_LICENSE_MARKER
BEGIN_LICENSE_MARKER

See Also:
Constant Field Values

END_LICENSE_MARKER

public static final java.lang.String END_LICENSE_MARKER
END_LICENSE_MARKER

See Also:
Constant Field Values
Method Detail

decrypt

public static ClientKey decrypt(java.lang.String encrypted,
                                java.lang.String email)
Decrypts an encrypted key string

Parameters:
encrypted -
email -
Returns:
client key

isCloseToExpiring

public boolean isCloseToExpiring()
True if this key is close to expiring

Returns:
true if close, false otherwise

isValid

public boolean isValid()
True if valid key

Returns:
true if valid, false otherwise

isCloseToMatching

public boolean isCloseToMatching()
True if key has valid fields but email did not match

Returns:
- true if close, false otherwise

isExpired

public boolean isExpired()
True if this key is expired

Returns:
true if expired, false otherwise

getEmail

public java.lang.String getEmail()
Gets the email for this key

Returns:
- email

getExpiration

public java.util.Calendar getExpiration()
Gets the expiration of this key

Returns:
- calendar

isTrial

public boolean isTrial()
True if trial key

Returns:
true if trial, false otherwise

isPro

public boolean isPro()
True if pro key

Returns:
true if pro, false otherwise

shouldProPluginsRun

public boolean shouldProPluginsRun()
True if professional plugins should run

Returns:
true to run pros, false otherwise

trimEncryptedLicense

public static java.lang.String trimEncryptedLicense(java.lang.String encrypted)
Gets the trimmed version of a license key

Parameters:
encrypted -
Returns:
- trimmed key