|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.jp.protection.pub.LicenseAdapter
public class LicenseAdapter
An abstract adapter class for receiving license events. All methods of this
class provide simple message output to the System.out
stream if
verbose mode is specified. This class exists as convenience for creating
listener objects.
LicenseListener
Field Summary | |
---|---|
protected boolean |
fVerbose
|
Constructor Summary | |
---|---|
LicenseAdapter()
|
|
LicenseAdapter(boolean aVerbose)
|
Method Summary | |
---|---|
protected void |
error(java.lang.String aMessage)
|
void |
featureChecked(LicenseHost aSource,
License aLicense,
java.lang.String aFeature,
boolean isEnabled)
The License Host calls this method to notify listener that product feature is checked and available. |
boolean |
isVerbose()
|
void |
licenseAboutToExpire(LicenseHost aSource,
License aLicense,
int aDaysLeft)
The License Host calls this method to notify listener that license is about to expire in specified number of days. Note, this method can be used with Protection! Professional edition only. |
void |
licenseAboutToRead(LicenseReader aSource,
java.lang.String aProductID)
License reader calls this method to notify listener that the license is about to be read and specifies a known ID of the product this license is issued for. |
void |
licenseAccepted(LicenseHost aSource,
License aLicense,
boolean isAccepted)
The License Host calls this method to notify listener that license agreement is accepted or declined by the user. |
void |
licenseAvailable(LicenseReader aSource,
java.lang.String aLicenseLocation)
License reader calls this method to notify listener that the license is successfully read and available for use. |
void |
licenseCorrupted(LicenseReader aSource,
java.lang.String aLicenseLocation)
License reader calls this method to notify listener that the license is corrupted and therefore can not be read. |
void |
licenseExpired(LicenseHost aSource,
License aLicense)
The License Host calls this method to notify listener that license is already expired. |
void |
licenseInvalid(LicenseHost aSource,
License aLicense)
The License Host calls this method to notify listener that license is invalid e.g. |
void |
licenseLockExpired(LicenseHost aSource,
License aLicense,
java.lang.String aReason)
The License Host calls this method to notify the listener that the license lock has expired. |
void |
licenseLockRevoked(LicenseHost aSource,
License aLicense,
java.lang.String aReason)
The License Host calls this method to notify the listener that the license lock revocation is requested by the Licensing Server administrator. |
void |
licenseLockViolation(LicenseHost aSource,
License aLicense)
The License Host calls this method to notify listener that license is activated for use on other computer. Note, this method can be used with Protection! Professional edition only. |
void |
licenseMissing(LicenseReader aSource,
java.lang.String aLicenseLocation)
License reader calls this method to notify listener when the license is not found neither in the resource folder nor in the file system. |
void |
licenseNeedActivation(LicenseHost aSource,
License aLicense,
int aDaysLeft)
The License Host calls this method to notify listener that license need to be activated in aDaysLeft days.Note, this method can be used with Protection! Professional edition only. |
void |
licenseNeedLock(LicenseHost aSource,
License aLicense,
int aDaysLeft)
The License Host calls this method to notify the listener that the requirement to acquire license lock will be mandatory in aDaysLeft days.Note, this method can be used with Protection! Professional edition only and can be fired when license need to be locked through the Licensing Server. |
void |
licenseNotActivated(LicenseHost aSource,
License aLicense)
The License Host calls this method to notify listener that license is not activated. Note, this method can be used with Protection! Professional edition only. |
void |
licenseNotLocked(LicenseHost aSource,
License aLicense,
java.lang.String aReason)
The License Host calls this method to notify the listener that license lock has not been acquired. |
void |
licenseOk(LicenseHost aSource,
License aLicense)
The License Host calls this method to notify listener that license is OK. |
void |
licenseRemoved(LicenseReader aSource,
java.lang.String aLicenseLocation)
License reader calls this method to notify listener that the license was removed beacuse it was revoked or not available anymore e.g. |
void |
licenseUpdated(LicenseReader aSource,
java.lang.String aLicenseLocation)
License reader calls this method to notify listener that the license was updated by getting up-to-date version from a remote service such as from Licensing Server |
void |
licenseUseLimitAboutReach(LicenseHost aSource,
License aLicense,
int aUseLeft)
The License Host calls this method to notify listener that license is about to expire after specified number of usages. Note, this method can be used with Protection! Professional edition only. |
protected void |
message(java.lang.String aMessage)
|
void |
numberCopiesViolation(LicenseHost aSource,
License aLicense,
int aNumberInUse)
The License Host calls this method to notify listener that the actual number of concurrently executing applications, which use the same license, exceed maximum allowed number. Note, this method can be used with Protection! Professional edition only. |
void |
setVerbose(boolean aVerbose)
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected boolean fVerbose
Constructor Detail |
---|
public LicenseAdapter()
public LicenseAdapter(boolean aVerbose)
Method Detail |
---|
public boolean isVerbose()
public void setVerbose(boolean aVerbose)
protected void error(java.lang.String aMessage)
protected void message(java.lang.String aMessage)
public void licenseAccepted(LicenseHost aSource, License aLicense, boolean isAccepted)
LicenseHostListener
licenseAccepted
in interface LicenseHostListener
aSource
- the license host.aLicense
- instance of the license.isAccepted
- true
if license agreement is accepted,
false
otherwise.public void licenseMissing(LicenseReader aSource, java.lang.String aLicenseLocation)
LicenseReaderListener
licenseMissing
in interface LicenseReaderListener
aSource
- the license reader.aLicenseLocation
- full path to the license file.public void licenseCorrupted(LicenseReader aSource, java.lang.String aLicenseLocation)
LicenseReaderListener
licenseCorrupted
in interface LicenseReaderListener
aSource
- the license reader.aLicenseLocation
- full path to the license file.public void licenseAvailable(LicenseReader aSource, java.lang.String aLicenseLocation)
LicenseReaderListener
licenseAvailable
in interface LicenseReaderListener
aSource
- the license reader.aLicenseLocation
- full path to the license file.public void licenseRemoved(LicenseReader aSource, java.lang.String aLicenseLocation)
LicenseReaderListenerExt
licenseRemoved
in interface LicenseReaderListenerExt
aSource
- the license reader.aLicenseLocation
- license locationpublic void licenseUpdated(LicenseReader aSource, java.lang.String aLicenseLocation)
LicenseReaderListenerExt
licenseUpdated
in interface LicenseReaderListenerExt
aSource
- the license reader.aLicenseLocation
- license locationpublic void licenseExpired(LicenseHost aSource, License aLicense)
LicenseHostListener
licenseExpired
in interface LicenseHostListener
aSource
- the license host.aLicense
- instance of the license.public void licenseOk(LicenseHost aSource, License aLicense)
LicenseHostListener
licenseOk
in interface LicenseHostListener
aSource
- the license host.aLicense
- instance of the license.public void licenseInvalid(LicenseHost aSource, License aLicense)
LicenseHostListener
licenseInvalid
in interface LicenseHostListener
aSource
- the license host.aLicense
- instance of the license.public void featureChecked(LicenseHost aSource, License aLicense, java.lang.String aFeature, boolean isEnabled)
LicenseHostListener
featureChecked
in interface LicenseHostListener
aSource
- the license host.aLicense
- instance of the license.aFeature
- name of the feature.isEnabled
- true
if feature is enabled, false
otherwise.public void licenseAboutToExpire(LicenseHost aSource, License aLicense, int aDaysLeft)
LicenseHostListener
licenseAboutToExpire
in interface LicenseHostListener
aSource
- the license host.aLicense
- instance of the license.aDaysLeft
- days left to license expiration.public void licenseUseLimitAboutReach(LicenseHost aSource, License aLicense, int aUseLeft)
LicenseHostListener
licenseUseLimitAboutReach
in interface LicenseHostListener
aSource
- the license host.aLicense
- instance of the license.aUseLeft
- usages left to license expiration.public void licenseLockViolation(LicenseHost aSource, License aLicense)
LicenseHostListener
licenseLockViolation
in interface LicenseHostListener
aSource
- the license host.aLicense
- instance of the license.public void numberCopiesViolation(LicenseHost aSource, License aLicense, int aNumberInUse)
LicenseHostListener
numberCopiesViolation
in interface LicenseHostListener
aSource
- the license host.aLicense
- instance of the license.aNumberInUse
- actual number of copies in use.public void licenseNotActivated(LicenseHost aSource, License aLicense)
LicenseHostListener
licenseNotActivated
in interface LicenseHostListener
aSource
- the license host.aLicense
- instance of the license.public void licenseNeedActivation(LicenseHost aSource, License aLicense, int aDaysLeft)
LicenseHostListener
aDaysLeft
days.
licenseNeedActivation
in interface LicenseHostListener
aSource
- the license host.aLicense
- instance of the license.aDaysLeft
- number of days left till the license will be considered as
not activated onepublic void licenseAboutToRead(LicenseReader aSource, java.lang.String aProductID)
LicenseReaderListener
licenseAboutToRead
in interface LicenseReaderListener
aSource
- the license reader.aProductID
- ID of the product this license is issued for.public void licenseNeedLock(LicenseHost aSource, License aLicense, int aDaysLeft)
LicenseHostListener
aDaysLeft
days.
licenseNeedLock
in interface LicenseHostListener
aSource
- the License Host.aLicense
- instance of the license.aDaysLeft
- number of days left untill the license will be considered as
not locked onepublic void licenseNotLocked(LicenseHost aSource, License aLicense, java.lang.String aReason)
LicenseHostListener
licenseNotLocked
in interface LicenseHostListener
aSource
- the license host.aLicense
- instance of the license.aReason
- why license lock is not acquiredpublic void licenseLockExpired(LicenseHost aSource, License aLicense, java.lang.String aReason)
LicenseHostListener
licenseLockExpired
in interface LicenseHostListener
aSource
- the license host.aLicense
- instance of the license.aReason
- why license is expiredpublic void licenseLockRevoked(LicenseHost aSource, License aLicense, java.lang.String aReason)
LicenseHostListener
licenseLockRevoked
in interface LicenseHostListener
aSource
- the license host.aLicense
- instance of the license.aReason
- why license lock revocation is requested.
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |