public class SoapServiceHelperImpl extends Object implements SoapServiceHelper
| Modifier and Type | Field and Description |
|---|---|
protected ContentEntityManager |
contentEntityManager |
protected PageManager |
pageManager |
protected PermissionManager |
permissionManager |
protected SpaceManager |
spaceManager |
protected UserAccessor |
userAccessor |
protected WebSudoManager |
webSudoManager |
| Constructor and Description |
|---|
SoapServiceHelperImpl() |
| Modifier and Type | Method and Description |
|---|---|
void |
assertCanAdminister() |
void |
assertCanAdminister(Space space) |
void |
assertCanCreateBlogPost(Space space) |
void |
assertCanCreatePage(Space space) |
void |
assertCanExport(Space space) |
void |
assertCanModify(AbstractPage page) |
void |
assertCanModifyObject(Object obj,
String typeDescription)
Determines if the current user can modify/edit the given object
|
void |
assertCanRemove(AbstractPage page)
Throw an exception if the user can't remove the given page.
|
void |
assertCanView(AbstractPage page) |
void |
assertCanView(Space space) |
void |
assertHasValidWebSudoSession() |
AbstractPage |
retrieveAbstractPage(long abstractPageId)
Retrieves a given page, and throws RemoteException if the page is not found or the user has no view perm.
|
ContentEntityObject |
retrieveContent(long contentId)
Retrieves the content with the given ID, throwing an exception if the content can not
be found, or the current user has not permission to view it.
|
Page |
retrievePage(String spaceKey,
String pageTitle)
Retrieves a given page by space key and page title, and throws RemoteException if the page is not found or the user has no view perm.
|
Space |
retrieveSpace(String spaceKey)
Retrieves a given space, and throws RemoteException if the space is not found or the user has no view perm.
|
ConfluenceUser |
retrieveUser(String username)
Retrieves the user with the given username
|
void |
setContentEntityManager(ContentEntityManager contentEntityManager) |
void |
setPageManager(PageManager pageManager) |
void |
setPermissionManager(PermissionManager permissionManager) |
void |
setSpaceManager(SpaceManager spaceManager) |
void |
setUserAccessor(UserAccessor userAccessor) |
void |
setWebSudoManager(WebSudoManager webSudoManager) |
protected SpaceManager spaceManager
protected PermissionManager permissionManager
protected PageManager pageManager
protected UserAccessor userAccessor
protected ContentEntityManager contentEntityManager
protected WebSudoManager webSudoManager
public void setWebSudoManager(WebSudoManager webSudoManager)
public void setUserAccessor(UserAccessor userAccessor)
public void setSpaceManager(SpaceManager spaceManager)
public void setPageManager(PageManager pageManager)
public void setPermissionManager(PermissionManager permissionManager)
public void setContentEntityManager(ContentEntityManager contentEntityManager)
public ContentEntityObject retrieveContent(long contentId) throws RemoteException
SoapServiceHelperretrieveContent in interface SoapServiceHelpercontentId - the ID of the content to retrieveRemoteException - if the user lacks VIEW permission or the content does not existpublic Space retrieveSpace(String spaceKey) throws RemoteException
retrieveSpace in interface SoapServiceHelperRemoteExceptionpublic AbstractPage retrieveAbstractPage(long abstractPageId) throws RemoteException
retrieveAbstractPage in interface SoapServiceHelperRemoteExceptionpublic Page retrievePage(String spaceKey, String pageTitle) throws RemoteException
retrievePage in interface SoapServiceHelperRemoteExceptionpublic ConfluenceUser retrieveUser(String username) throws RemoteException
SoapServiceHelperretrieveUser in interface SoapServiceHelperusername - the username of the userRemoteException - if the username is empty or nullpublic void assertCanView(AbstractPage page) throws RemoteException
assertCanView in interface SoapServiceHelperRemoteExceptionpublic void assertCanView(Space space) throws RemoteException
assertCanView in interface SoapServiceHelperRemoteExceptionpublic void assertCanModifyObject(Object obj, String typeDescription) throws NotPermittedException
SoapServiceHelperIf the current user is a super-user, they will automatically pass this test
assertCanModifyObject in interface SoapServiceHelperobj - the target objecttypeDescription - the type of object (e.g. "labels")NotPermittedException - if the user lacks EDIT permissionpublic void assertCanCreatePage(Space space) throws RemoteException
assertCanCreatePage in interface SoapServiceHelperRemoteExceptionpublic void assertCanCreateBlogPost(Space space) throws RemoteException
assertCanCreateBlogPost in interface SoapServiceHelperRemoteExceptionpublic void assertCanModify(AbstractPage page) throws RemoteException
assertCanModify in interface SoapServiceHelperRemoteExceptionpublic void assertCanRemove(AbstractPage page) throws RemoteException
assertCanRemove in interface SoapServiceHelperRemoteExceptionpublic void assertCanAdminister()
throws RemoteException
assertCanAdminister in interface SoapServiceHelperRemoteExceptionpublic void assertHasValidWebSudoSession()
throws RemoteException
assertHasValidWebSudoSession in interface SoapServiceHelperRemoteExceptionpublic void assertCanExport(Space space) throws RemoteException
assertCanExport in interface SoapServiceHelperRemoteExceptionpublic void assertCanAdminister(Space space) throws RemoteException
assertCanAdminister in interface SoapServiceHelperRemoteExceptionCopyright © 2003–2022 Atlassian. All rights reserved.