public class DenormalisedPermissionRouter extends Object implements BulkPermissionService
| Constructor and Description |
|---|
DenormalisedPermissionRouter(BulkPermissionService realDenormalisedPermissionService,
BulkPermissionService fallbackDenormalisedPermissionService,
DenormalisedPermissionStateManager denormalisedPermissionStateManager,
com.atlassian.event.api.EventPublisher eventPublisher) |
| Modifier and Type | Method and Description |
|---|---|
Map<String,Boolean> |
getAllSpaceKeysWithPermissionStatuses(ConfluenceUser confluenceUser,
String spacePermissionType)
Returns a map of spaces where key is space key, and value is flag (true if permitted, false is not)
|
List<SimpleContent> |
getAllVisiblePagesInSpace(ConfluenceUser confluenceUser,
long spaceId)
Returns the full list of visible pages in the space.
|
Set<Long> |
getPermittedSpaceIds(ConfluenceUser confluenceUser,
Set<Long> spaceIds,
String spacePermissionType)
Returns a set of permitted space ids.
|
List<Space> |
getPermittedSpaces(SpacesQuery spaceQuery,
int offset,
int limit)
Returns a list of permitted spaces filters by spaceQuery.
|
Map<Long,List<SimpleContent>> |
getVisibleChildPages(ConfluenceUser confluenceUser,
Set<Long> parentPageIdSet,
boolean checkInheritedPermissions)
Receives a set of page ids as a parameter and finds all visible children for them.
|
Set<Long> |
getVisiblePageIds(ConfluenceUser confluenceUser,
Set<Long> pageIds,
boolean checkSpacePermissions)
Returns a set of visible page ids.
|
List<SimpleContent> |
getVisibleTopLevelPages(ConfluenceUser confluenceUser,
long spaceId)
Finds all visible top-level pages.
|
void |
sendAnalyticsEventAboutFailure(DenormalisedPermissionFailAnalyticsEvent.Action action) |
public DenormalisedPermissionRouter(BulkPermissionService realDenormalisedPermissionService, BulkPermissionService fallbackDenormalisedPermissionService, DenormalisedPermissionStateManager denormalisedPermissionStateManager, com.atlassian.event.api.EventPublisher eventPublisher)
public Map<String,Boolean> getAllSpaceKeysWithPermissionStatuses(@Nullable ConfluenceUser confluenceUser, String spacePermissionType)
getAllSpaceKeysWithPermissionStatuses in interface BulkPermissionServiceconfluenceUser - confluence user.spacePermissionType - - permission type. Only "VIEWSPACE" or "EDITSPACE" are supportedpublic List<Space> getPermittedSpaces(SpacesQuery spaceQuery, int offset, int limit)
getPermittedSpaces in interface BulkPermissionServicespaceQuery - queryoffset - offset for the querylimit - maxResults for the query. Must be greater than 0public Set<Long> getPermittedSpaceIds(@Nullable ConfluenceUser confluenceUser, Set<Long> spaceIds, String spacePermissionType)
getPermittedSpaceIds in interface BulkPermissionServiceconfluenceUser - confluence user.spaceIds - space ids.spacePermissionType - - permission type. Only "VIEWSPACE" or "EDITSPACE" are supported.public Map<Long,List<SimpleContent>> getVisibleChildPages(@Nullable ConfluenceUser confluenceUser, Set<Long> parentPageIdSet, boolean checkInheritedPermissions)
getVisibleChildPages in interface BulkPermissionServiceconfluenceUser - the Confluence user, null if anonymousparentPageIdSet - set of parent page idsSimpleContent entities representing the child pages visible to the userpublic List<SimpleContent> getVisibleTopLevelPages(@Nullable ConfluenceUser confluenceUser, long spaceId)
getVisibleTopLevelPages in interface BulkPermissionServiceconfluenceUser - the Confluence user, null if anonymousspaceId - the space IDSimpleContent entities representing the child pages visible to the userpublic List<SimpleContent> getAllVisiblePagesInSpace(@Nullable ConfluenceUser confluenceUser, long spaceId)
getAllVisiblePagesInSpace in interface BulkPermissionServiceconfluenceUser - the Confluence user, null if anonymousspaceId - the space IDSimpleContent entities representing all pages visible to the user in a spacepublic Set<Long> getVisiblePageIds(@Nullable ConfluenceUser confluenceUser, Set<Long> pageIds, boolean checkSpacePermissions)
getVisiblePageIds in interface BulkPermissionServiceconfluenceUser - confluence user.pageIds - page ids.checkSpacePermissions - if false, "useConfluence" and corresponding space permissions will NOT be checked.
If true, "useConfluence" and corresponding space permissions will be checked too.@Internal public void sendAnalyticsEventAboutFailure(DenormalisedPermissionFailAnalyticsEvent.Action action)
Copyright © 2003–2022 Atlassian. All rights reserved.