com.atlassian.jira.plugin.studio
Interface StudioLicenseHooks

All Known Implementing Classes:
MockStudioHooks.MockStudioLicenseHooks

public interface StudioLicenseHooks

Methods on this interface are called by JIRA when it makes some of its Licensing decisions. All of these methods will need to be thread safe. These method can be called by multiple threads at the same time. The same method can be called by my multiple threads at the same time. All of these methods will need to be performant. JIRA will not do any caching of the results and will probably call a method with the same arguments multiple times (possibly at the same time).

Since:
v4.4.2

Method Summary
 boolean canActivateNumberOfUsers(int numUsers, com.atlassian.util.concurrent.Function<Integer,Boolean> method)
          Called when a call to UserUtil.canActivateNumberOfUsers(int) is made.
 boolean canActivateUsers(Collection<String> userNames, com.atlassian.util.concurrent.Function<Collection<String>,Boolean> method)
          Called when a call to UserUtil.canActivateUsers(java.util.Collection) is made.
 void clearActiveUserCount(com.atlassian.util.concurrent.Function<Void,Void> method)
          Called when a call to UserUtil.clearActiveUserCount() is made.
 boolean hasExceededUserLimit(com.atlassian.util.concurrent.Function<Void,Boolean> method)
          Called when a call to UserUtil.hasExceededUserLimit() is made.
 

Method Detail

clearActiveUserCount

void clearActiveUserCount(com.atlassian.util.concurrent.Function<Void,Void> method)
Called when a call to UserUtil.clearActiveUserCount() is made. JIRA's default implementation of this method can be called by invoking the function passed to the method.

Parameters:
method - function that can be used to invoke JIRAs default implementation of this method.

hasExceededUserLimit

boolean hasExceededUserLimit(com.atlassian.util.concurrent.Function<Void,Boolean> method)
Called when a call to UserUtil.hasExceededUserLimit() is made. JIRA's default implementation of this method can be called by invoking the function passed to the method.

Parameters:
method - function that can be used to invoke JIRAs default implementation of this method.
Returns:
see UserUtil.hasExceededUserLimit()}.

canActivateNumberOfUsers

boolean canActivateNumberOfUsers(int numUsers,
                                 com.atlassian.util.concurrent.Function<Integer,Boolean> method)
Called when a call to UserUtil.canActivateNumberOfUsers(int) is made. JIRA's default implementation of this method can be called by invoking the function passed to the method.

Parameters:
numUsers - see UserUtil.canActivateNumberOfUsers(int)
method - function that can be used to invoke JIRAs default implementation of this method.
Returns:
see UserUtil.canActivateNumberOfUsers(int)

canActivateUsers

boolean canActivateUsers(Collection<String> userNames,
                         com.atlassian.util.concurrent.Function<Collection<String>,Boolean> method)
Called when a call to UserUtil.canActivateUsers(java.util.Collection) is made. JIRA's default implementation of this method can be called by invoking the function passed to the method.

Parameters:
userNames - see UserUtil.canActivateUsers(java.util.Collection)
method - function that can be used to invoke JIRAs default implementation of this method.
Returns:
see UserUtil.canActivateUsers(java.util.Collection)


Copyright © 2002-2014 Atlassian. All Rights Reserved.