Package com.xebialabs.license.service
Interface LicenseService
-
public interface LicenseService
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description com.xebialabs.license.LicenseCiCountergetCounter()Provides an access to the counterLicensegetLicense()java.lang.StringgetProduct()Provide the product name.org.joda.time.PeriodgetValidPeriod()Returns the amount of time this license is still validvoidinitialize(LicenseCiCounterFactory ciCounterFactory)Initialization that requires the repositorybooleanisLicenseExpired()Checks whether the license is expiredvoidreload()Reload the license file from the file system andvalidate()it.voidrollbackTransaction(LicenseTransaction transaction)Rolls back any CI changes (deletions, creations, copies) that were performed as part of the given license transactionLicenseTransactionstartTransaction()Gives you a new LicenseTransaction object so you can keep track of what CIs were created during this JcrTransaction per thread.voidvalidate()Validates whether XL Deploy server meets all the license requirements for the license on diskvoidvalidate(License license)Validates whether XL Deploy server meets all the license requirements for a license instance
-
-
-
Method Detail
-
getLicense
License getLicense()
-
isLicenseExpired
boolean isLicenseExpired()
Checks whether the license is expired
-
getValidPeriod
org.joda.time.Period getValidPeriod()
Returns the amount of time this license is still valid- Returns:
- a period. Returns period.ZERO if the license is expired
-
getProduct
java.lang.String getProduct()
Provide the product name.
-
validate
void validate() throws LicenseViolationExceptionValidates whether XL Deploy server meets all the license requirements for the license on disk- Throws:
LicenseViolationException
-
validate
void validate(License license) throws LicenseViolationException
Validates whether XL Deploy server meets all the license requirements for a license instance- Throws:
LicenseViolationException
-
reload
void reload() throws LicenseViolationException, LicenseParseExceptionReload the license file from the file system andvalidate()it.
-
getCounter
com.xebialabs.license.LicenseCiCounter getCounter()
Provides an access to the counter
-
initialize
void initialize(LicenseCiCounterFactory ciCounterFactory)
Initialization that requires the repository
-
startTransaction
LicenseTransaction startTransaction()
Gives you a new LicenseTransaction object so you can keep track of what CIs were created during this JcrTransaction per thread.- Returns:
- a LicenseTransaction
-
rollbackTransaction
void rollbackTransaction(LicenseTransaction transaction)
Rolls back any CI changes (deletions, creations, copies) that were performed as part of the given license transaction- Parameters:
transaction- a LicenseTransaction to rollback changes from
-
-