public class JiraLicenseServiceImpl extends Object implements JiraLicenseUpdaterService
JiraLicenseService.ValidationResult
Constructor and Description |
---|
JiraLicenseServiceImpl(JiraLicenseManager licenseManager,
UserUtil userUtil) |
Modifier and Type | Method and Description |
---|---|
void |
confirmProceedUnderEvaluationTerms(String userName)
This will confirm that user has agreed to proceed under Evaluation terms, typically when the license is too old
for the current JIRA build.
|
LicenseDetails |
getLicense()
Returns a non null
LicenseDetails object that represents the current license or an instance of com.atlassian.jira.license.NullLicenseDetails if the license is not currently setup |
Iterable<LicenseDetails> |
getLicenses()
Retrieve a list of all products licenses installed in this instance.
|
String |
getServerId()
Gets the server ID of the JIRA instance, creates it if it doesn't already exists.
|
LicenseDetails |
setLicense(JiraLicenseService.ValidationResult validationResult)
Sets the license from the given ValidationResult as the current JIRA license.
|
LicenseDetails |
setLicenseNoEvent(JiraLicenseService.ValidationResult validationResult)
Sets the license from the given ValidationResult as the current JIRA license.
|
Iterable<JiraLicenseService.ValidationResult> |
validate(I18nHelper i18n,
Iterable<String> licenses)
Validates each license String provided in preparation for setting them.
|
JiraLicenseService.ValidationResult |
validate(I18nHelper i18nHelper,
String licenseString)
Validates the license String in preparation for setting the license.
|
public JiraLicenseServiceImpl(JiraLicenseManager licenseManager, UserUtil userUtil)
public String getServerId()
JiraLicenseService
getServerId
in interface JiraLicenseService
public LicenseDetails getLicense()
JiraLicenseService
LicenseDetails
object that represents the current license or an instance of com.atlassian.jira.license.NullLicenseDetails
if the license is not currently setupgetLicense
in interface JiraLicenseService
LicenseDetails
objectpublic JiraLicenseService.ValidationResult validate(I18nHelper i18nHelper, String licenseString)
JiraLicenseService
validate
in interface JiraLicenseService
i18nHelper
- the helper for i18nlicenseString
- the license to validatepublic Iterable<JiraLicenseService.ValidationResult> validate(I18nHelper i18n, Iterable<String> licenses)
JiraLicenseService
validate
in interface JiraLicenseService
i18n
- the helper for i18n - used to populate the error messageslicenses
- the licenses to validatepublic LicenseDetails setLicense(JiraLicenseService.ValidationResult validationResult)
JiraLicenseUpdaterService
setLicense
in interface JiraLicenseUpdaterService
validationResult
- the validation result to get the license from.public LicenseDetails setLicenseNoEvent(JiraLicenseService.ValidationResult validationResult)
JiraLicenseUpdaterService
setLicenseNoEvent
in interface JiraLicenseUpdaterService
validationResult
- the validation result to get the license from.public void confirmProceedUnderEvaluationTerms(String userName)
JiraLicenseService
confirmProceedUnderEvaluationTerms
in interface JiraLicenseService
userName
- the name of the user that made the confirmationpublic Iterable<LicenseDetails> getLicenses()
JiraLicenseService
getLicenses
in interface JiraLicenseService
Copyright © 2002-2015 Atlassian. All Rights Reserved.