@ParametersAreNonnullByDefault public class ApplicationConfigurationHelper extends Object
Constructor and Description |
---|
ApplicationConfigurationHelper(com.atlassian.application.api.ApplicationManager applicationManager,
GroupManager groupManager,
ApplicationRoleManager applicationRoleManager,
GlobalPermissionManager globalPermissionManager,
UserManager userManager,
ApplicationRoleStore applicationRoleStore,
MessageUtil.Factory messageUtilFactory,
GroupConfigurationIdentifier groupConfigurationIdentifier,
com.atlassian.event.api.EventPublisher eventPublisher,
JiraAuthenticationContext authenticationContext,
JiraLicenseManager jiraLicenseManager,
JohnsonProvider johnsonProvider) |
Modifier and Type | Method and Description |
---|---|
void |
configureApplicationsForImport(LicenseDetails licenseDetailsForImport)
Performs initial configuration for applications during JIRA Import.
|
void |
configureApplicationsForSetup(Collection<com.atlassian.crowd.embedded.api.Group> additionalGroups,
boolean publishEvent)
Performs initial configuration for applications during JIRA Setup.
|
void |
configureLicense(LicenseChangedEvent event) |
void |
setupAdminForDefaultApplications(ApplicationUser user)
Configure the passed admin for all the default applications by adding the admin to all the applications default
groups.
|
Optional<String> |
validateApplicationForConfiguration(com.atlassian.application.api.ApplicationKey applicationKey,
ApplicationUser user)
Validate whether the specified application can be configured.
|
public ApplicationConfigurationHelper(com.atlassian.application.api.ApplicationManager applicationManager, GroupManager groupManager, ApplicationRoleManager applicationRoleManager, GlobalPermissionManager globalPermissionManager, UserManager userManager, ApplicationRoleStore applicationRoleStore, MessageUtil.Factory messageUtilFactory, GroupConfigurationIdentifier groupConfigurationIdentifier, com.atlassian.event.api.EventPublisher eventPublisher, JiraAuthenticationContext authenticationContext, JiraLicenseManager jiraLicenseManager, JohnsonProvider johnsonProvider)
public Optional<String> validateApplicationForConfiguration(com.atlassian.application.api.ApplicationKey applicationKey, @Nullable ApplicationUser user)
applicationKey
- key identifying application.user
- user performing configuration or null if this is not being performed by a user.Optional
with an warning message if validation did not pass or Optional.empty()
if
there are no warning.public void configureApplicationsForSetup(Collection<com.atlassian.crowd.embedded.api.Group> additionalGroups, boolean publishEvent)
additionalGroups
- Groups that will be added to all the licensed applications. They won't be added as
defaults.publishEvent
- If true then ApplicationConfigurationEvent
will be published if there were any
changes made by this method. This is especially handy during initial setup, where sending events might
cause unwanted actions (like User Management sync)public void configureApplicationsForImport(LicenseDetails licenseDetailsForImport)
public void setupAdminForDefaultApplications(ApplicationUser user)
user
- the user to configure.public void configureLicense(LicenseChangedEvent event)
Copyright © 2002-2019 Atlassian. All Rights Reserved.