Interface PermissionDelegate<TARGET>
- All Known Implementing Classes:
AbstractPermissionsDelegate,ApplicationPermissionsDelegate,AttachmentPermissionsDelegate,BlogPostPermissionsDelegate,CommentPermissionsDelegate,DraftPermissionsDelegate,GlobalDescriptionPermissionsDelegate,GroupPermissionsDelegate,JsonPropertyPermissionDelegate,LabellingPermissionsDelegate,LinkPermissionsDelegate,NoPermissionDelegate,PagePermissionsDelegate,PageTemplatePermissionsDelegate,PeopleDirectoryPermissionsDelegate,PersonalInformationPermissionsDelegate,SharedAccessInterceptor,SpaceDescriptionPermissionsDelegate,SpacePermissionsDelegate,SystemPermissionsDelegate,TargetToLatestVersionDecorator,UserPermissionsDelegate
public interface PermissionDelegate<TARGET>
Each type of target that can have permissions checked against it will have a delegate. The delegate's job is to
separate out the different permissions checks in a cleaner, more maintainable fashion.
These delegates on check content access according to the permissions set.
If you need to verify other restrictions that are context dependant like ContentEntityObject.SHARE_ID
make sure you put them in the corresponding places.
-
Method Summary
Modifier and TypeMethodDescriptionbooleancanAdminister(ConfluenceUser user, TARGET target) default booleancanAdminister(com.atlassian.user.User user, TARGET target) Deprecated.booleancanCreate(ConfluenceUser user, Object container) default booleanDeprecated.booleancanCreateInTarget(ConfluenceUser user, Class typeToCreate) default booleancanCreateInTarget(com.atlassian.user.User user, Class typeToCreate) Deprecated.since 8.8 usecanCreateInTarget(ConfluenceUser, Class)booleancanEdit(ConfluenceUser user, TARGET target) default booleanDeprecated.booleancanExport(ConfluenceUser user, TARGET target) default booleanDeprecated.default booleancanMove(ConfluenceUser user, TARGET source, Object target, String movePoint) default booleanDeprecated.booleancanRemove(ConfluenceUser user, TARGET target) default booleanDeprecated.default booleancanRemoveHierarchy(ConfluenceUser user, TARGET target) default booleancanRemoveHierarchy(com.atlassian.user.User user, TARGET target) Deprecated.booleancanSetPermissions(ConfluenceUser user, TARGET target) default booleancanSetPermissions(com.atlassian.user.User user, TARGET target) Deprecated.booleancanView(ConfluenceUser user) booleancanView(ConfluenceUser user, TARGET target) default booleancanView(com.atlassian.user.User user) Deprecated.since 8.8 usecanView(ConfluenceUser)default booleanDeprecated.since 8.8 usecanView(ConfluenceUser, Object)
-
Method Details
-
canView
Deprecated.since 8.8 usecanView(ConfluenceUser, Object)- Returns:
- true if user can view the specified target.
-
canView
- Returns:
- true if user can view the specified target.
- Since:
- 8.8
-
canView
Deprecated.since 8.8 usecanView(ConfluenceUser)- Returns:
- true if the user can view all instances of targets handled by this permission delegate
-
canView
- Returns:
- true if the user can view all instances of targets handled by this permission delegate
- Since:
- 8.8
-
canEdit
Deprecated.- Since:
- 8.8 use
canEdit(ConfluenceUser, Object)
-
canEdit
- Since:
- 8.8
-
canSetPermissions
Deprecated.- Since:
- 8.8 use
canSetPermissions(ConfluenceUser, Object)
-
canSetPermissions
- Since:
- 8.8
-
canRemove
Deprecated.- Since:
- 8.8 use
canRemove(ConfluenceUser, Object)
-
canRemove
- Since:
- 8.8
-
canMove
@Deprecated default boolean canMove(com.atlassian.user.User user, TARGET source, Object target, String movePoint) Deprecated.- Since:
- 8.8 use
canMove(ConfluenceUser, Object, Object, String)
-
canMove
- Since:
- 8.8
-
canRemoveHierarchy
Deprecated.- Since:
- 8.8 use
canRemoveHierarchy(ConfluenceUser, Object)
-
canRemoveHierarchy
- Since:
- 8.8
-
canExport
Deprecated.- Since:
- 8.8 use
canExport(ConfluenceUser, Object)
-
canExport
- Since:
- 8.8
-
canAdminister
Deprecated.- Since:
- 8.8 use
canAdminister(ConfluenceUser, Object)
-
canAdminister
- Since:
- 8.8
-
canCreate
Deprecated.since 8.8 usecanCreate(ConfluenceUser, Object)- Returns:
- true if the specified user can create new instances of the target type in the specified container.
-
canCreate
- Returns:
- true if the specified user can create new instances of the target type in the specified container.
- Since:
- 8.8
-
canCreateInTarget
Deprecated.since 8.8 usecanCreateInTarget(ConfluenceUser, Class)- Parameters:
user- the user performing the createtypeToCreate- the class of the entity to create- Returns:
- true if the specified user can create new instances of the specified typeToCreate within instances of target handled by this PermissionDelegate.
-
canCreateInTarget
- Parameters:
user- the user performing the createtypeToCreate- the class of the entity to create- Returns:
- true if the specified user can create new instances of the specified typeToCreate within instances of target handled by this PermissionDelegate.
- Since:
- 8.8
-
canCreate(ConfluenceUser, Object)