public class

DefaultAuthorizationSupport

extends Object
implements AuthorizationSupport
java.lang.Object
   ↳ com.atlassian.jira.web.util.DefaultAuthorizationSupport

Class Overview

Implementation of the authorization checks defined in AuthorizationSupport

Summary

Public Constructors
DefaultAuthorizationSupport(PermissionManager permissionManager, JiraAuthenticationContext jiraAuthenticationContext)
Public Methods
boolean hasIssuePermission(int permissionsId, Issue issue)
Returns true if the logged in user has the given permission type on the given Issue.
boolean hasPermission(int permissionsId)
Returns true if the logged in user has the given permission type.
boolean hasProjectPermission(int permissionsId, Project project)
Returns true if the logged in user has the given permission type on the given Project.
boolean isHasIssuePermission(int permissionsId, GenericValue issue)
Returns true if the logged in user has the given permission type on the given Issue.
boolean isHasIssuePermission(String permName, GenericValue issue)
Returns true if the logged in user has the given permission type on the given Issue.
boolean isHasPermission(String permName)
Returns true if the logged in user has the given permission type.
@Deprecated boolean isHasPermission(String permName, GenericValue entity)
Returns true if remote user has permission over given entity, false otherwise.
boolean isHasPermission(int permissionsId)
Returns true if the logged in user has the given permission type.
boolean isHasProjectPermission(int permissionsId, GenericValue project)
Returns true if the logged in user has the given permission type on the given Project.
boolean isHasProjectPermission(String permName, GenericValue project)
Returns true if the logged in user has the given permission type on the given Project.
[Expand]
Inherited Methods
From class java.lang.Object
From interface com.atlassian.jira.web.util.AuthorizationSupport

Public Constructors

public DefaultAuthorizationSupport (PermissionManager permissionManager, JiraAuthenticationContext jiraAuthenticationContext)

Public Methods

public boolean hasIssuePermission (int permissionsId, Issue issue)

Returns true if the logged in user has the given permission type on the given Issue.

Parameters
permissionsId the permission type
issue the Issue
Returns
  • true if the logged in user has the given permission type on the given Issue.

public boolean hasPermission (int permissionsId)

Returns true if the logged in user has the given permission type.

Parameters
permissionsId the permission type
Returns
  • true if the logged in user has the given permission type.

public boolean hasProjectPermission (int permissionsId, Project project)

Returns true if the logged in user has the given permission type on the given Project.

Parameters
permissionsId the permission type
project the Project
Returns
  • true if the logged in user has the given permission type on the given Project.

public boolean isHasIssuePermission (int permissionsId, GenericValue issue)

Returns true if the logged in user has the given permission type on the given Issue.

Parameters
permissionsId the permission type
issue the Issue
Returns
  • true if the logged in user has the given permission type on the given Issue.

public boolean isHasIssuePermission (String permName, GenericValue issue)

Returns true if the logged in user has the given permission type on the given Issue.

Parameters
permName the permission type
issue the Issue
Returns
  • true if the logged in user has the given permission type on the given Issue.

public boolean isHasPermission (String permName)

Returns true if the logged in user has the given permission type.

Parameters
permName the permission type
Returns
  • true if the logged in user has the given permission type.

@Deprecated public boolean isHasPermission (String permName, GenericValue entity)

Returns true if remote user has permission over given entity, false otherwise.

Parameters
permName permission type
entity entity to check the permission for, e.g. project, issue
Returns
  • true if remote user has permission over given entity, false otherwise

public boolean isHasPermission (int permissionsId)

Returns true if the logged in user has the given permission type.

Parameters
permissionsId the permission type
Returns
  • true if the logged in user has the given permission type.

public boolean isHasProjectPermission (int permissionsId, GenericValue project)

Returns true if the logged in user has the given permission type on the given Project.

Parameters
permissionsId the permission type
project the Project
Returns
  • true if the logged in user has the given permission type on the given Project.

public boolean isHasProjectPermission (String permName, GenericValue project)

Returns true if the logged in user has the given permission type on the given Project.

Parameters
permName the permission type
project the Project
Returns
  • true if the logged in user has the given permission type on the given Project.