Interface JaacsService
- All Known Implementing Classes:
DefaultJaacsService
public interface JaacsService
Service to support configuration of JIRA as a Crowd Service.
-
Method Summary
Modifier and TypeMethodDescriptionbooleanaddRemoteAddress(JiraServiceContext jiraServiceContext, String remoteAddress, long applicationId) Adding a new remote address.voidcreate(ApplicationUser remoteUser, com.atlassian.crowd.model.application.Application application) Creates a new ApplicationbooleandeleteApplication(JiraServiceContext jiraServiceContext, long applicationId) Delete a remote address.List<com.atlassian.crowd.model.application.Application>findAll(ApplicationUser remoteUser) Returns a list containing all non-permanent Crowd applications.com.atlassian.crowd.model.application.ApplicationImplfindById(ApplicationUser remoteUser, Long applicationId) Returns the Application having the given id.Set<com.atlassian.crowd.model.application.RemoteAddress>getRemoteAddresses(JiraServiceContext jiraServiceContext, long applicationId) Retrieve a list of configured remote addresses.booleanresetPassword(JiraServiceContext jiraServiceContext, String password, long applicationId) Reset a password.voidupdate(ApplicationUser remoteUser, com.atlassian.crowd.model.application.Application updatedApplication) Updates an Application.booleanvalidateAddRemoteAddress(JiraServiceContext jiraServiceContext, String remoteAddress, long applicationId) Validate adding a new remote address.booleanvalidateDeleteApplication(JiraServiceContext jiraServiceContext, long applicationId) Validate deleting a remote address.booleanvalidateResetPassword(JiraServiceContext jiraServiceContext, String password, long applicationId) Validate resetting a password.
-
Method Details
-
getRemoteAddresses
Set<com.atlassian.crowd.model.application.RemoteAddress> getRemoteAddresses(JiraServiceContext jiraServiceContext, long applicationId) Retrieve a list of configured remote addresses.- Parameters:
jiraServiceContext- The service context.applicationId- Application Id- Returns:
- List of configured remote addresses.
-
validateAddRemoteAddress
boolean validateAddRemoteAddress(JiraServiceContext jiraServiceContext, String remoteAddress, long applicationId) Validate adding a new remote address.- Parameters:
remoteAddress- A new address to addjiraServiceContext- The service context.applicationId- Application Id- Returns:
- true if validation passes
-
addRemoteAddress
boolean addRemoteAddress(JiraServiceContext jiraServiceContext, String remoteAddress, long applicationId) Adding a new remote address.- Parameters:
jiraServiceContext- The service context.remoteAddress- A new address to addapplicationId- Application Id- Returns:
- true if validation passes
-
validateDeleteApplication
Validate deleting a remote address.- Parameters:
jiraServiceContext- The service context.applicationId- Application Id- Returns:
- true if validation passes and action succeeds
-
deleteApplication
Delete a remote address.- Parameters:
jiraServiceContext- The service context.applicationId- Application Id- Returns:
- true if validation passes
-
validateResetPassword
boolean validateResetPassword(JiraServiceContext jiraServiceContext, String password, long applicationId) Validate resetting a password.- Parameters:
password- A password stringjiraServiceContext- The service context.applicationId- Application Id- Returns:
- true if validation passes
-
resetPassword
Reset a password.- Parameters:
password- A password stringjiraServiceContext- The service context.applicationId- Application Id- Returns:
- true if validation passes and action succeeds
-
findAll
List<com.atlassian.crowd.model.application.Application> findAll(ApplicationUser remoteUser) throws ValidationFailureException Returns a list containing all non-permanent Crowd applications.- Parameters:
remoteUser- a User representing the user on whose behalf to perform the call- Returns:
- a new List
- Throws:
ValidationFailureException- if there is a problem
-
findById
com.atlassian.crowd.model.application.ApplicationImpl findById(ApplicationUser remoteUser, Long applicationId) throws ValidationFailureException Returns the Application having the given id.- Parameters:
remoteUser- a User representing the user on whose behalf to perform the callapplicationId- a Long containing an application id, or null if it doesn't exist- Returns:
- an Application
- Throws:
ValidationFailureException- if there is a problem
-
create
void create(ApplicationUser remoteUser, com.atlassian.crowd.model.application.Application application) throws ValidationFailureException Creates a new Application- Parameters:
remoteUser- a User representing the user on whose behalf to perform the callapplication- an Application to create- Throws:
ValidationFailureException- if there is a problem
-
update
void update(ApplicationUser remoteUser, com.atlassian.crowd.model.application.Application updatedApplication) throws ValidationFailureException Updates an Application. The application having the given id will be updated with the remaining contents.- Parameters:
remoteUser- a User representing the user on whose behalf to perform the callupdatedApplication- an Application to update- Throws:
ValidationFailureException- if there is a problem
-