com.jp.protection.pub.pro.ls
Class BasicLicenseStorage.BasicLicenseEntry

java.lang.Object
  extended by com.jp.protection.pub.pro.ls.BasicLicenseStorage.BasicLicenseEntry
All Implemented Interfaces:
LicenseStorage.LicenseEntry, java.io.Serializable
Enclosing class:
BasicLicenseStorage

public static class BasicLicenseStorage.BasicLicenseEntry
extends java.lang.Object
implements LicenseStorage.LicenseEntry, java.io.Serializable

Basic implementation of the LicenseEntry interface

Since:
3.0
See Also:
Serialized Form

Field Summary
protected  BasicLicenseStorage fBasicLicenseStorage
           
protected  int fID
           
protected  byte[] fLicenseBytes
           
protected  java.lang.String fLicenseNumber
           
protected  int fLicenseType
           
protected  int fMajorVersion
           
protected  int fMinorVersion
           
protected  java.lang.String fProduct
           
protected  java.lang.String fProductEdition
           
protected  java.beans.PropertyChangeSupport fPropertyChangeSupport
           
protected  int fUserLicensingModel
           
static java.lang.String PROPERTY_LICENSE_BYTES
           
static java.lang.String PROPERTY_LICENSE_NUMBER
           
static java.lang.String PROPERTY_LICENSE_TYPE
           
static java.lang.String PROPERTY_MAJOR_VERSION
           
static java.lang.String PROPERTY_MINOR_VERSION
           
static java.lang.String PROPERTY_PRODUCT
           
static java.lang.String PROPERTY_PRODUCT_EDITION
           
static java.lang.String PROPERTY_USER_LICENSING_MODEL
           
static long serialVersionUID
           
 
Constructor Summary
BasicLicenseStorage.BasicLicenseEntry(int anID)
          Creates a new instance of the BasicLicenseEntry
BasicLicenseStorage.BasicLicenseEntry(int anID, byte[] aLicenseBytes, java.lang.String aProduct)
          Creates a new instance of the BasicLicenseEntry
BasicLicenseStorage.BasicLicenseEntry(int anID, byte[] aLicenseBytes, java.lang.String aProduct, java.lang.String aProductEdition, int aMajorVersion, int aMinorVersion, int aLicenseType)
          Creates a new instance of the BasicLicenseEntry
 
Method Summary
 void addPropertyChangeListener(java.beans.PropertyChangeListener listener)
          Adds a listener to the listeners list
 boolean equals(java.lang.Object anOther)
           
 BasicLicenseStorage getBasicLicenseStorage()
          Returns license storage this license entry belongs to
 int getID()
          Returns unique identifier
 byte[] getLicenseBytes()
          Returns license bytes
 java.lang.String getLicenseNumber()
          Returns license number
 int getLicenseType()
          Returns license type
 int getMajorVersion()
          Returns major version
 int getMinorVersion()
          Returns minor version
 java.lang.String getProduct()
          Returns product identifier
 java.lang.String getProductEdition()
          Returns product edition identifier
 java.beans.PropertyChangeSupport getPropertyChangeSupport()
          Returns an instance of the PropertyChangeSupport used to fire corresponding events
 int getUserLicensingModel()
          Returns user licensing model
 int hashCode()
           
 void removePropertyChangeListener(java.beans.PropertyChangeListener listener)
          Removes a listener from the listeners list
protected  void setBasicLicenseStorage(BasicLicenseStorage aBasicLicenseStorage)
           
 void setLicenseBytes(byte[] aLicenseBytes)
          Specifies license bytes for the entry
 void setLicenseNumber(java.lang.String aLicenseNumber)
          Specifies license number for the entry
 void setLicenseType(int aLicenseType)
          Specifies license type for the entry
 void setMajorVersion(int aMajorVersion)
          Specifies major version for the entry
 void setMinorVersion(int aMinorVersion)
          Specifies minor version for the entry
 void setProduct(java.lang.String aProduct)
          Specifies product identifier for the entry
 void setProductEdition(java.lang.String aProductEdition)
          Specifies product edition identifier for the entry
 void setUserLicensingModel(int aUserLicensingModel)
          Specifies user licensing model for the entry
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

serialVersionUID

public static final long serialVersionUID
See Also:
Constant Field Values

PROPERTY_LICENSE_BYTES

public static final java.lang.String PROPERTY_LICENSE_BYTES
See Also:
Constant Field Values

PROPERTY_LICENSE_TYPE

public static final java.lang.String PROPERTY_LICENSE_TYPE
See Also:
Constant Field Values

PROPERTY_LICENSE_NUMBER

public static final java.lang.String PROPERTY_LICENSE_NUMBER
See Also:
Constant Field Values

PROPERTY_PRODUCT

public static final java.lang.String PROPERTY_PRODUCT
See Also:
Constant Field Values

PROPERTY_PRODUCT_EDITION

public static final java.lang.String PROPERTY_PRODUCT_EDITION
See Also:
Constant Field Values

PROPERTY_MAJOR_VERSION

public static final java.lang.String PROPERTY_MAJOR_VERSION
See Also:
Constant Field Values

PROPERTY_MINOR_VERSION

public static final java.lang.String PROPERTY_MINOR_VERSION
See Also:
Constant Field Values

PROPERTY_USER_LICENSING_MODEL

public static final java.lang.String PROPERTY_USER_LICENSING_MODEL
See Also:
Constant Field Values

fLicenseBytes

protected transient byte[] fLicenseBytes

fLicenseNumber

protected java.lang.String fLicenseNumber

fLicenseType

protected int fLicenseType

fProduct

protected java.lang.String fProduct

fProductEdition

protected java.lang.String fProductEdition

fMajorVersion

protected int fMajorVersion

fMinorVersion

protected int fMinorVersion

fUserLicensingModel

protected int fUserLicensingModel

fBasicLicenseStorage

protected transient BasicLicenseStorage fBasicLicenseStorage

fPropertyChangeSupport

protected transient java.beans.PropertyChangeSupport fPropertyChangeSupport

fID

protected int fID
Constructor Detail

BasicLicenseStorage.BasicLicenseEntry

public BasicLicenseStorage.BasicLicenseEntry(int anID)
Creates a new instance of the BasicLicenseEntry

Parameters:
anID - unique identifier to assign

BasicLicenseStorage.BasicLicenseEntry

public BasicLicenseStorage.BasicLicenseEntry(int anID,
                                             byte[] aLicenseBytes,
                                             java.lang.String aProduct)
Creates a new instance of the BasicLicenseEntry

Parameters:
anID - unique identifier to be assigned
aLicenseBytes - byte[] license bytes to be assigned
aProduct - product identifier to be assigned

BasicLicenseStorage.BasicLicenseEntry

public BasicLicenseStorage.BasicLicenseEntry(int anID,
                                             byte[] aLicenseBytes,
                                             java.lang.String aProduct,
                                             java.lang.String aProductEdition,
                                             int aMajorVersion,
                                             int aMinorVersion,
                                             int aLicenseType)
Creates a new instance of the BasicLicenseEntry

Parameters:
anID - unique identifier to be assigned
aLicenseBytes - byte[] license bytes to be assigned
aProduct - product identifier to be assigned
aProductEdition - product edition identifier to be assigned
aMajorVersion - major version to be assigned
aMinorVersion - minor version to be assigned
aLicenseType - license type to be assigned
Method Detail

getID

public int getID()
Description copied from interface: LicenseStorage.LicenseEntry
Returns unique identifier

Specified by:
getID in interface LicenseStorage.LicenseEntry
Returns:
unique (per License Storage) identifier

hashCode

public int hashCode()
Overrides:
hashCode in class java.lang.Object

equals

public boolean equals(java.lang.Object anOther)
Overrides:
equals in class java.lang.Object

getPropertyChangeSupport

public java.beans.PropertyChangeSupport getPropertyChangeSupport()
Returns an instance of the PropertyChangeSupport used to fire corresponding events

Returns:
instance of the PropertyChangeSupport

getBasicLicenseStorage

public BasicLicenseStorage getBasicLicenseStorage()
Returns license storage this license entry belongs to

Returns:
license storage

setBasicLicenseStorage

protected void setBasicLicenseStorage(BasicLicenseStorage aBasicLicenseStorage)

addPropertyChangeListener

public void addPropertyChangeListener(java.beans.PropertyChangeListener listener)
Adds a listener to the listeners list

Parameters:
listener - a listener to add

removePropertyChangeListener

public void removePropertyChangeListener(java.beans.PropertyChangeListener listener)
Removes a listener from the listeners list

Parameters:
listener - a listener to remove

getLicenseBytes

public byte[] getLicenseBytes()
Description copied from interface: LicenseStorage.LicenseEntry
Returns license bytes

Specified by:
getLicenseBytes in interface LicenseStorage.LicenseEntry
Returns:
license bytes

setLicenseBytes

public void setLicenseBytes(byte[] aLicenseBytes)
Description copied from interface: LicenseStorage.LicenseEntry
Specifies license bytes for the entry

Specified by:
setLicenseBytes in interface LicenseStorage.LicenseEntry
Parameters:
aLicenseBytes - license bytes to set

setLicenseType

public void setLicenseType(int aLicenseType)
Description copied from interface: LicenseStorage.LicenseEntry
Specifies license type for the entry

Specified by:
setLicenseType in interface LicenseStorage.LicenseEntry
Parameters:
aLicenseType - license type to set

setMajorVersion

public void setMajorVersion(int aMajorVersion)
Description copied from interface: LicenseStorage.LicenseEntry
Specifies major version for the entry

Specified by:
setMajorVersion in interface LicenseStorage.LicenseEntry
Parameters:
aMajorVersion - major version to set

setMinorVersion

public void setMinorVersion(int aMinorVersion)
Description copied from interface: LicenseStorage.LicenseEntry
Specifies minor version for the entry

Specified by:
setMinorVersion in interface LicenseStorage.LicenseEntry
Parameters:
aMinorVersion - minor version to set

setProduct

public void setProduct(java.lang.String aProduct)
Description copied from interface: LicenseStorage.LicenseEntry
Specifies product identifier for the entry

Specified by:
setProduct in interface LicenseStorage.LicenseEntry
Parameters:
aProduct - product identifier to set

setProductEdition

public void setProductEdition(java.lang.String aProductEdition)
Description copied from interface: LicenseStorage.LicenseEntry
Specifies product edition identifier for the entry

Specified by:
setProductEdition in interface LicenseStorage.LicenseEntry
Parameters:
aProductEdition - product edition identifier to set

setLicenseNumber

public void setLicenseNumber(java.lang.String aLicenseNumber)
Description copied from interface: LicenseStorage.LicenseEntry
Specifies license number for the entry

Specified by:
setLicenseNumber in interface LicenseStorage.LicenseEntry
Parameters:
aLicenseNumber - license number to set

setUserLicensingModel

public void setUserLicensingModel(int aUserLicensingModel)
Description copied from interface: LicenseStorage.LicenseEntry
Specifies user licensing model for the entry

Specified by:
setUserLicensingModel in interface LicenseStorage.LicenseEntry
Parameters:
aUserLicensingModel - user licensing model to set

getLicenseType

public int getLicenseType()
Description copied from interface: LicenseStorage.LicenseEntry
Returns license type

Specified by:
getLicenseType in interface LicenseStorage.LicenseEntry
Returns:
license type

getProduct

public java.lang.String getProduct()
Description copied from interface: LicenseStorage.LicenseEntry
Returns product identifier

Specified by:
getProduct in interface LicenseStorage.LicenseEntry
Returns:
product identifier

getProductEdition

public java.lang.String getProductEdition()
Description copied from interface: LicenseStorage.LicenseEntry
Returns product edition identifier

Specified by:
getProductEdition in interface LicenseStorage.LicenseEntry
Returns:
product edition identifier

getMajorVersion

public int getMajorVersion()
Description copied from interface: LicenseStorage.LicenseEntry
Returns major version

Specified by:
getMajorVersion in interface LicenseStorage.LicenseEntry
Returns:
major version

getMinorVersion

public int getMinorVersion()
Description copied from interface: LicenseStorage.LicenseEntry
Returns minor version

Specified by:
getMinorVersion in interface LicenseStorage.LicenseEntry
Returns:
minor version

getLicenseNumber

public java.lang.String getLicenseNumber()
Description copied from interface: LicenseStorage.LicenseEntry
Returns license number

Specified by:
getLicenseNumber in interface LicenseStorage.LicenseEntry
Returns:
license number

getUserLicensingModel

public int getUserLicensingModel()
Description copied from interface: LicenseStorage.LicenseEntry
Returns user licensing model

Specified by:
getUserLicensingModel in interface LicenseStorage.LicenseEntry
Returns:
user licensing model