com.atlassian.jira.license
Class PluginLicenseRoleDefinitions

java.lang.Object
  extended by com.atlassian.jira.license.PluginLicenseRoleDefinitions
All Implemented Interfaces:
LicenseRoleDefinitions

public class PluginLicenseRoleDefinitions
extends Object
implements LicenseRoleDefinitions


Constructor Summary
PluginLicenseRoleDefinitions(com.atlassian.plugin.PluginAccessor pluginAccessor, JiraLicenseManager licenseManager, com.atlassian.event.api.EventPublisher publisher)
           
 
Method Summary
 com.atlassian.fugue.Option<LicenseRoleDefinition> getAuthenticatedRoleDefinition(LicenseRoleId licenseRoleId)
          Return the LicenseRoleDefinition associated with the passed LicenseRoleId provided it is authenticated.
 Set<LicenseRoleDefinition> getAuthenticatedRoleDefinitions()
          Return all the authenticated LicenseRoleDefinitions.
 com.atlassian.fugue.Option<LicenseRoleDefinition> getDefinedRoleDefinition(LicenseRoleId licenseRoleId)
          Return the LicenseRoleDefinition associated with the passed LicenseRoleId provided it is defined.
 Set<LicenseRoleDefinition> getDefinedRoleDefinitions()
          Return all the defined LicenseRoleDefinitions.
 boolean isLicenseRoleAuthenticated(LicenseRoleId licenseRoleId)
          Return true when the passed LicenseRoleId is authenticated.
 boolean isLicenseRoleDefined(LicenseRoleId licenseRoleId)
          Return true when the passed LicenseRoleId is defined.
 void pluginModuleDisabled(com.atlassian.plugin.event.events.PluginModuleDisabledEvent event)
           
 void pluginModuleEnabled(com.atlassian.plugin.event.events.PluginModuleEnabledEvent event)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

PluginLicenseRoleDefinitions

public PluginLicenseRoleDefinitions(com.atlassian.plugin.PluginAccessor pluginAccessor,
                                    JiraLicenseManager licenseManager,
                                    com.atlassian.event.api.EventPublisher publisher)
Method Detail

getDefinedRoleDefinitions

@Nonnull
public Set<LicenseRoleDefinition> getDefinedRoleDefinitions()
Description copied from interface: LicenseRoleDefinitions
Return all the defined LicenseRoleDefinitions. A LicenseRoleDefinition is defined when a plugin provides it. This does not indicate if the LicenseRoleDefinition is licensed or not.

Specified by:
getDefinedRoleDefinitions in interface LicenseRoleDefinitions
Returns:
all the defined LicenseRoleDefinitions.

getAuthenticatedRoleDefinitions

@Nonnull
public Set<LicenseRoleDefinition> getAuthenticatedRoleDefinitions()
Description copied from interface: LicenseRoleDefinitions
Return all the authenticated LicenseRoleDefinitions. A LicenseRoleDefinition is authenticated when a plugin defines it and it is licensed.

Specified by:
getAuthenticatedRoleDefinitions in interface LicenseRoleDefinitions
Returns:
all the authenticated LicenseRoleDefinitions.

isLicenseRoleDefined

public boolean isLicenseRoleDefined(@Nonnull
                                    LicenseRoleId licenseRoleId)
Description copied from interface: LicenseRoleDefinitions
Return true when the passed LicenseRoleId is defined. A LicenseRoleId is defined when a plugin provides a LicenseRoleDefinition. This does not indicate if the LicenseRoleId is licensed or not.

Specified by:
isLicenseRoleDefined in interface LicenseRoleDefinitions
Parameters:
licenseRoleId - the ID to check.
Returns:
true when the passed LicenseRoleId is defined.

isLicenseRoleAuthenticated

public boolean isLicenseRoleAuthenticated(@Nonnull
                                          LicenseRoleId licenseRoleId)
Description copied from interface: LicenseRoleDefinitions
Return true when the passed LicenseRoleId is authenticated. A LicenseRoleId is authenticated when a plugin provides a LicenseRoleDefinition and it is also licensed.

Specified by:
isLicenseRoleAuthenticated in interface LicenseRoleDefinitions
Parameters:
licenseRoleId - the ID to check.
Returns:
true when the passed LicenseRoleId is authenticated.

getDefinedRoleDefinition

@Nonnull
public com.atlassian.fugue.Option<LicenseRoleDefinition> getDefinedRoleDefinition(@Nonnull
                                                                                          LicenseRoleId licenseRoleId)
Description copied from interface: LicenseRoleDefinitions
Return the LicenseRoleDefinition associated with the passed LicenseRoleId provided it is defined. A value of Option.none() is returned if the passed LicenseRoleId is undefined. A LicenseRoleId is defined when a plugin provides a LicenseRoleDefinition. This does not indicate if the LicenseRoleId is licensed or not.

Specified by:
getDefinedRoleDefinition in interface LicenseRoleDefinitions
Parameters:
licenseRoleId - the ID to check.
Returns:
Return the LicenseRoleDefinition associated with the passed LicenseRoleId if it is defined or Option.none() otherwise.

getAuthenticatedRoleDefinition

@Nonnull
public com.atlassian.fugue.Option<LicenseRoleDefinition> getAuthenticatedRoleDefinition(@Nonnull
                                                                                                LicenseRoleId licenseRoleId)
Description copied from interface: LicenseRoleDefinitions
Return the LicenseRoleDefinition associated with the passed LicenseRoleId provided it is authenticated. A value of Option.none() is returned if the passed LicenseRoleId is not authenticated. A LicenseRoleId is authenticated when a plugin provides a LicenseRoleDefinition and it is licensed.

Specified by:
getAuthenticatedRoleDefinition in interface LicenseRoleDefinitions
Parameters:
licenseRoleId - the ID to check.
Returns:
Return the LicenseRoleDefinition associated with the passed LicenseRoleId if it is authenticated or Option.none() otherwise.

pluginModuleDisabled

@EventListener
public void pluginModuleDisabled(com.atlassian.plugin.event.events.PluginModuleDisabledEvent event)

pluginModuleEnabled

@EventListener
public void pluginModuleEnabled(com.atlassian.plugin.event.events.PluginModuleEnabledEvent event)


Copyright © 2002-2014 Atlassian. All Rights Reserved.