Class ApplicationPermissionsDelegate

    • Constructor Detail

      • ApplicationPermissionsDelegate

        public ApplicationPermissionsDelegate()
    • Method Detail

      • canView

        public boolean canView​(com.atlassian.user.User user,
                               Object target)
        Return true if a user is licensed to use Confluence i.e. is included in the user count of Confluence license.

        Please note that although unlicensed, some authenticated users can still access certain features of Confluence if Unlicensed access is enabled in both global and space level. To check if a user can use Confluence in general, use ConfluenceAccessManager.getUserAccessStatus(User) then AccessStatus.canUseConfluence()

        Specified by:
        canView in interface PermissionDelegate
        Returns:
        true if user can view the specified target.
      • canView

        public boolean canView​(com.atlassian.user.User user)
        Specified by:
        canView in interface PermissionDelegate
        Returns:
        true if the user can view all instances of targets handled by this permission delegate
      • canCreate

        public boolean canCreate​(com.atlassian.user.User user,
                                 Object container)
        Specified by:
        canCreate in interface PermissionDelegate
        Returns:
        true if the specified user can create new instances of the target type in the specified container.
      • canCreateInTarget

        public boolean canCreateInTarget​(com.atlassian.user.User user,
                                         Class typeToCreate)
        Specified by:
        canCreateInTarget in interface PermissionDelegate
        Parameters:
        user - the user performing the create
        typeToCreate - 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.
      • setSpacePermissionManager

        public void setSpacePermissionManager​(SpacePermissionManager spacePermissionManager)