Interface ServiceDeskPermissionService
@PublicApi
@ParametersAreNonnullByDefault
@ReturnValuesAreNonnullByDefault
public interface ServiceDeskPermissionService
An experimental interface for validating users against service project permissions
WARNING: this interface is experimental and is subject to change between minor versions of Jira Service Management up to and including removal of this interface or parts thereof. It is not for consumption by non-Atlassian plugins and no consideration will be given to nor guarantees made for its compatibility between releases. Basically, don't use it unless you're a Jira Service Management developer.
- Since:
- 2.3
-
Method Summary
Modifier and TypeMethodDescriptionboolean
isAdminAgent
(com.atlassian.jira.user.ApplicationUser user, ServiceDesk serviceDesk) Checks whether the user is an agent with project admin permission.boolean
isAgent
(com.atlassian.jira.user.ApplicationUser user, ServiceDesk serviceDesk) Checks whether the user is an agent for the given service project.boolean
isCustomer
(com.atlassian.jira.user.ApplicationUser user, com.atlassian.jira.issue.Issue issue) Checks whether theApplicationUser
is a customer for the givencom.atlassian.servicedesk.api.request
.boolean
isCustomer
(com.atlassian.jira.user.ApplicationUser user, CustomerRequest request) Checks whether theApplicationUser
is a customer for the givencom.atlassian.servicedesk.api.request
.
-
Method Details
-
isAdminAgent
Checks whether the user is an agent with project admin permission. True if - valid licensed, - license count not overrun - required permissions on the project - is admin on project- Parameters:
user
- the user who you want to checkserviceDesk
- the service project you want to check the agent status against.- Returns:
- whether the user is an admin agent for the given service project.
- Throws:
ServiceDeskServiceException
- on error
-
isAgent
Checks whether the user is an agent for the given service project. True if - valid licensed, - license count not overrun - required permissions on the project- Parameters:
user
- the user who you want to checkserviceDesk
- the service project you want to check the agent status against.- Returns:
- whether the user is an agent for the given service project.
- Throws:
ServiceDeskServiceException
- on error
-
isCustomer
Checks whether theApplicationUser
is a customer for the givencom.atlassian.servicedesk.api.request
.- Parameters:
user
- the user who you want to checkrequest
- the request you want to check customer status against.- Returns:
- whether the user is a customer for the given request.
- Throws:
ServiceDeskServiceException
- on error
-
isCustomer
boolean isCustomer(com.atlassian.jira.user.ApplicationUser user, com.atlassian.jira.issue.Issue issue) Checks whether theApplicationUser
is a customer for the givencom.atlassian.servicedesk.api.request
.- Parameters:
user
- the user who you want to checkissue
- the jira issue you want to check customer status against.- Returns:
- whether the user is a customer for the given request.
- Throws:
ServiceDeskServiceException
- on error
-