public class DefaultInternalProjectPermissionHelper extends Object implements InternalProjectPermissionHelper
| Constructor and Description |
|---|
DefaultInternalProjectPermissionHelper(PermissionManager permissionManager,
ApplicationProperties applicationProperties) |
| Modifier and Type | Method and Description |
|---|---|
boolean |
canUserBrowseProject(Project project,
ApplicationUser user)
Checks if the user can see the projects.
|
List<Project> |
getBrowsableProjectHistory(ApplicationUser user)
Gets the history of projects that should be visible for the user based on 'BROWSE_PROJECTS' permission checks.
|
Collection<Project> |
getBrowsableProjects(ApplicationUser user)
Gets the list of projects that should be visible for the user based on 'BROWSE_PROJECTS' permission checks.
|
ServiceOutcome<List<Project>> |
getBrowsableProjectsForProjectAction(ApplicationUser user)
Gets the list of projects that should be visible for the user based on
ProjectAction. |
Collection<Project> |
getBrowsableProjectsInCategory(ApplicationUser user,
ProjectCategory projectCategory)
Gets the list of projects from a given category that should be visible for the user based on 'BROWSE_PROJECTS' permission checks.
|
boolean |
hasPermission(ProjectPermissionKey permissionKey,
Project project,
ApplicationUser user)
Permission checker method that differentiates the behaviour only for 'BROWSE_PROJECTS'.
|
public DefaultInternalProjectPermissionHelper(PermissionManager permissionManager, ApplicationProperties applicationProperties)
public boolean canUserBrowseProject(Project project, ApplicationUser user)
InternalProjectPermissionHelpercanUserBrowseProject in interface InternalProjectPermissionHelperproject - Project to check for 'BROWSE_PROJECTS'.user - User to check the permissions for.public boolean hasPermission(ProjectPermissionKey permissionKey, Project project, ApplicationUser user)
InternalProjectPermissionHelperhasPermission in interface InternalProjectPermissionHelperpermissionKey - Permission that's being checked.project - Project against which the permission is tested.user - User to check the permissions for.public Collection<Project> getBrowsableProjects(ApplicationUser user)
InternalProjectPermissionHelpergetBrowsableProjects in interface InternalProjectPermissionHelperuser - User to check the permissions for.public ServiceOutcome<List<Project>> getBrowsableProjectsForProjectAction(ApplicationUser user)
InternalProjectPermissionHelperProjectAction.
Differentiating based on the FF.getBrowsableProjectsForProjectAction in interface InternalProjectPermissionHelperuser - User to check the permissions for.public Collection<Project> getBrowsableProjectsInCategory(ApplicationUser user, ProjectCategory projectCategory)
InternalProjectPermissionHelpergetBrowsableProjectsInCategory in interface InternalProjectPermissionHelperuser - User to check the permissions for.projectCategory - Category to get the projects from.public List<Project> getBrowsableProjectHistory(ApplicationUser user)
InternalProjectPermissionHelpergetBrowsableProjectHistory in interface InternalProjectPermissionHelperuser - User to check the permissions for.Copyright © 2002-2022 Atlassian. All Rights Reserved.