com.atlassian.confluence.security.delegate
Class GroupPermissionsDelegate

java.lang.Object
  extended by com.atlassian.confluence.security.delegate.GroupPermissionsDelegate
All Implemented Interfaces:
PermissionDelegate

public class GroupPermissionsDelegate
extends Object
implements PermissionDelegate

Class for checking operations on groups.


Constructor Summary
GroupPermissionsDelegate()
           
 
Method Summary
 boolean canAdminister(com.atlassian.user.User user, Object target)
          Unsupported.
 boolean canCreate(com.atlassian.user.User user, Object container)
          Determines if the specified user has permissions to create groups
 boolean canEdit(com.atlassian.user.User user, Object group)
          Determines if the specified user can modify the membership (add/remove users) from the target group.
 boolean canExport(com.atlassian.user.User user, Object target)
          Unsupported.
 boolean canRemove(com.atlassian.user.User user, Object target)
          Determines if the specified user can remove the target group.
 boolean canSetPermissions(com.atlassian.user.User user, Object target)
          Determines if the specified user can assign new permissions to or remove existing permissions from the target group.
 boolean canView(com.atlassian.user.User user, Object target)
          Determines if the specified user can view the target group.
 void setSpacePermissionManager(SpacePermissionManager spacePermissionManager)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

GroupPermissionsDelegate

public GroupPermissionsDelegate()
Method Detail

canView

public boolean canView(com.atlassian.user.User user,
                       Object target)
Determines if the specified user can view the target group.

Specified by:
canView in interface PermissionDelegate
Returns:
true, always (according to the current implementation).

canEdit

public boolean canEdit(com.atlassian.user.User user,
                       Object group)
Determines if the specified user can modify the membership (add/remove users) from the target group. Only Confluence administrators and System administrators can modify most groups. Only system administrators can modify groups with system administrator permissions (or the confluence-administrator super group).

Specified by:
canEdit in interface PermissionDelegate
Parameters:
group - group to be modified (type Group)
Returns:
true if the specified user can modify the target group, false otherwise.

canRemove

public boolean canRemove(com.atlassian.user.User user,
                         Object target)
Determines if the specified user can remove the target group. Only Confluence administrators and System administrators can remove most groups. Only system administrators can remove groups with system administrators permissions (or the confluence-administrator super group).

Specified by:
canRemove in interface PermissionDelegate
Returns:
true if the specified user can remove the target group, false otherwise.

canCreate

public boolean canCreate(com.atlassian.user.User user,
                         Object container)
Determines if the specified user has permissions to create groups

Specified by:
canCreate in interface PermissionDelegate
Parameters:
container - not required. Null can be specified here as it is not used at the moment.
Returns:
true if the specified user has permissions to create groups.

canExport

public boolean canExport(com.atlassian.user.User user,
                         Object target)
Unsupported.

Specified by:
canExport in interface PermissionDelegate

canSetPermissions

public boolean canSetPermissions(com.atlassian.user.User user,
                                 Object target)
Determines if the specified user can assign new permissions to or remove existing permissions from the target group. Only system administrators can set permissions on groups with system administrators permissions (or the confluence-administrator super group).

Specified by:
canSetPermissions in interface PermissionDelegate
Returns:
true if the specified user can set permissions on the target group, false otherwise.

canAdminister

public boolean canAdminister(com.atlassian.user.User user,
                             Object target)
Unsupported.

Specified by:
canAdminister in interface PermissionDelegate

setSpacePermissionManager

public void setSpacePermissionManager(SpacePermissionManager spacePermissionManager)


Copyright © 2003-2013 Atlassian. All Rights Reserved.