The new rpc and rest clients may not have all the APIs yet - feel free to copy and refactor them over from here as they are needed.
@Deprecated public class ConfluenceRpc extends Object implements AutoCloseable
DO NOT add methods to this class! Per the manifesto in AdminRpc
, we should be trying to split this class
into smaller RPC clients that are accessed directly from tests. Deprecate and replace uses of methods in this
class whenever possible.
Modifier and Type | Class and Description |
---|---|
static class |
ConfluenceRpc.Version
Deprecated.
Enumeration of all supported versions of the Confluence remote API
|
Modifier and Type | Field and Description |
---|---|
AdminRpc |
admin
Deprecated.
|
AttachmentRpc |
attachments
Deprecated.
|
AuthenticatedWebResourceProvider |
baseResourceProvider
Deprecated.
|
ContentRpc |
content
Deprecated.
|
DarkFeaturesHelper |
darkFeatures
Deprecated.
|
LabelsRpc |
labels
Deprecated.
|
LikesRpc |
likes
Deprecated.
|
MailRpc |
mail
Deprecated.
|
NotificationsRpc |
notifications
Deprecated.
|
SpaceRpc |
spaces
Deprecated.
|
UserPreferencesRpc |
userPreferences
Deprecated.
|
Modifier and Type | Method and Description |
---|---|
boolean |
addExistingProfilePicture(String username,
String filename)
Deprecated.
Attempts to add a existing profile picture to a user's profile.
|
void |
addJobs(ScheduledJobKey job,
com.atlassian.scheduler.status.RunOutcome runOutcome,
Integer days,
Integer total)
Deprecated.
Add job run details that has been stored for more than the time threshold in days.
|
boolean |
addLabel(long labelId,
long contentId)
Deprecated.
Adds a label to the content specified by the supplied contentId
|
boolean |
addLabel(String label,
AbstractContentEntity target)
Deprecated.
|
boolean |
addLabelByObject(Object remoteLabel,
Page page)
Deprecated.
Adds a label to the specified page
|
boolean |
addLabelToSpace(String label,
Space space)
Deprecated.
Adds a label to the specified space
|
boolean |
addProfilePicture(String username,
String filename,
String mimeType,
byte[] pictureData)
Deprecated.
Attempts to add a profile picture to a user's profile
|
void |
addSmtpServer(String serverName,
String from,
String subjectPrefix,
String hostname,
int port)
Deprecated.
|
void |
addSmtpServer(String serverName,
String from,
String subjectPrefix,
String hostname,
int port,
String fromName)
Deprecated.
|
boolean |
addUserToGroup(String username,
String groupname)
Deprecated.
|
boolean |
addUserToGroup(User user,
Group group)
Deprecated.
|
void |
archiveSpace(Space space)
Deprecated.
|
protected Vector<Object> |
args(Object... params)
Deprecated.
|
void |
assertThatMostRecentIndexEntriesHaveBeenProcessed(ContentEntity... entities)
Deprecated.
|
void |
assertThatMostRecentIndexEntriesHaveBeenProcessed(Iterable<? extends ContentEntity> entities)
Deprecated.
|
void |
changeAttachmentCreatedDate(Attachment attachment,
Date createdDate)
Deprecated.
|
void |
changeBlogPostModificationDate(long blogId,
Date modificationDate)
Deprecated.
|
void |
changeCommentCreatedDate(Comment comment,
Date newCreationDate)
Deprecated.
|
boolean |
changeMyPassword(String oldPassword,
String newPassword)
Deprecated.
Attempts to change the current user's old password with the specified new password
|
void |
changePageCreatedDate(long id,
Date newDate)
Deprecated.
|
void |
changePageModificationDate(long pageId,
Date modificationDate)
Deprecated.
|
boolean |
changeUserPassword(String username,
String newPassword)
Deprecated.
Attempts to set the specified password for the specified user
|
void |
clearCustomHtml()
Deprecated.
|
void |
clearIndex()
Deprecated.
|
boolean |
clearIndexQueue()
Deprecated.
|
void |
clearMailQueue()
Deprecated.
|
void |
clearQueue(String queueName)
Deprecated.
|
void |
clearSystemProperty(String name)
Deprecated.
Clear the specified System property on the Confluence server.
|
void |
close()
Deprecated.
|
String |
convertWikiMarkupToXhtml(String wikiMarkup,
long pageId)
Deprecated.
|
String |
convertWikiToStorageFormat(String wiki)
Deprecated.
|
String |
convertXhtmlToWikiMarkup(String xhtml,
long pageId)
Deprecated.
|
int |
countDrafts(User user)
Deprecated.
|
long |
countJobRunDetails(ScheduledJobKey jobKey,
com.atlassian.scheduler.status.RunOutcome runOutcome)
Deprecated.
Count job run details
|
long |
createAttachment(Attachment attachment)
Deprecated.
|
long |
createAttachment(ContentEntity page,
Attachment attachment)
Deprecated.
|
long |
createAttachment(long contentId,
Attachment attachment)
Deprecated.
|
long |
createAttachmentOnDraft(Attachment attachment)
Deprecated.
|
long |
createBlogPost(BlogPost blogPost)
Deprecated.
|
long |
createComment(Comment comment)
Deprecated.
|
long |
createComment(Comment comment,
long parentCommentId)
Deprecated.
Since 5.5. Just call
createComment(Comment) with a Comment that has a parentId set. |
ContentId |
createContent(Content newContent)
Deprecated.
|
long |
createDraft(Draft draft)
Deprecated.
|
void |
createGroup(Group group)
Deprecated.
|
void |
createGroup(String groupname)
Deprecated.
|
void |
createJohnsonEvent(String message)
Deprecated.
|
long |
createPage(Page page)
Deprecated.
|
Map<String,String> |
createPage(String spaceKey,
String title,
String content,
long parentPageId)
Deprecated.
Since 5.4. Use
createPage(Page) . |
List<Page> |
createPageHierarchy(Space space,
int depth,
String pageTitlePrefix)
Deprecated.
Create a simple hierarchy of pages where each page is the parent of the next.
|
List<Page> |
createPagesFromPrototype(Page pageTemplate,
int count)
Deprecated.
|
Space |
createPersonalSpace(User user)
Deprecated.
|
Space |
createSpace(Space space)
Deprecated.
|
Space |
createSpace(String key,
String name,
String description)
Deprecated.
Since 5.5. Create a
Space and call createSpace(Space) . |
Iterable<String> |
createSpaces(int i)
Deprecated.
Creates a bunch of spaces.
|
long |
createTemplate(String templateName,
String content,
Space space)
Deprecated.
|
long |
createTemplateWithStorageFormat(String templateName,
String storageFormat,
Space space)
Deprecated.
|
int |
createTestUsers(int count)
Deprecated.
|
boolean |
createUser(User user)
Deprecated.
Adds the given user
|
boolean |
createUser(User user,
boolean notifyUser)
Deprecated.
Adds the given user
|
void |
createUserMacro(String name,
boolean hasBody,
String bodyType,
String outputType,
String template)
Deprecated.
|
void |
createUserMacro(String name,
boolean hasBody,
String bodyType,
String outputType,
String template,
String title,
String description,
String category,
String iconUrl,
String documentationUrl,
boolean hidden)
Deprecated.
|
long |
createWikiMarkupPage(Page page)
Deprecated.
Since 5.4. Use XHTML markup in your tests, and call
createPage(Page) |
boolean |
deactivateUser(String username)
Deprecated.
Deactivates the user matching the specified username
|
void |
disableAnonymousAccess()
Deprecated.
Old XML-RPC method.
Use
rpc.admin.permissions. PermissionsRpc.disableAnonymousUseConfluence() instead. |
boolean |
doesDraftExist(String contentId,
String draftCreator,
String draftType,
String spaceKey)
Deprecated.
|
void |
editAttachment(Attachment updatedAttachment)
Deprecated.
Edit either the owning page or the filename of the attachment.
|
void |
editPage(Space space,
String pageTitle,
String newTitle,
String newContent)
Deprecated.
Modifies the page with the given details
|
boolean |
editUser(User user)
Deprecated.
Attempts to edit the details of the specified user
|
void |
enableAnonymousAccess()
Deprecated.
Old XML-RPC method.
Use
rpc.admin.permissions. PermissionsRpc.enableAnonymousUseConfluence() instead. |
void |
enableCaptcha(boolean enable)
Deprecated.
|
void |
enableCaptchaDebugMode(boolean enable)
Deprecated.
|
boolean |
enableDailyReportNotification(User user,
boolean dailyReportEnabled)
Deprecated.
|
void |
enableElevatedSecurityCheck(boolean enabled)
Deprecated.
|
void |
enableNewUserEmailNotifications()
Deprecated.
|
void |
enablePublicSignUp(boolean enabled)
Deprecated.
|
void |
enableWebSudo(boolean enabled)
Deprecated.
|
Object |
execute(String method,
Object... args)
Deprecated.
Since 5.6. Use the less ambiguous
executeOnCurrentNode(String, Object...) |
Object |
executeAuthPluginXmlRpc(String servicePath,
String method,
Object... args)
Deprecated.
Since 5.6. Use the less ambiguous
executeAuthPluginXmlRpcOnCurrentNode(String, String, Object...) |
<T> T |
executeAuthPluginXmlRpcOnCurrentNode(String servicePath,
String method,
Object... args)
Deprecated.
|
Object |
executeFuncTest(String method,
Object... args)
Deprecated.
Since 5.6. Use the less ambiguous
executeFuncTestOnCurrentNode(String, Object...) |
<T> T |
executeFuncTestOnCurrentNode(String method,
Object... args)
Deprecated.
Instead of using the execute methods directly, consider adding a wrapper method to ConfluenceRpc.
|
protected Object |
executeFuncTestWithToken(String method,
String token,
Object... args)
Deprecated.
|
<T> T |
executeOnCurrentNode(String method,
Object... args)
Deprecated.
|
Object |
executePluginXmlRpc(String servicePath,
String method,
Object... args)
Deprecated.
Execute a Confluence plugin rpc method as anonymous user.
|
protected Object |
executeRpc(String rpcBase,
String methodToken,
String method,
Object... args)
Deprecated.
|
Object |
executeWithToken(String method,
@Nullable String token,
Object... args)
Deprecated.
Execute method with the specified token.
|
String |
exportSite(boolean exportAttachments)
Deprecated.
Returns the URL of the downloadable export.
|
String |
exportSpace(Space space,
String exportType)
Deprecated.
Returns the URL of the downloadable export.
|
void |
flushAllCaches()
Deprecated.
|
void |
flushEdgeIndexQueue()
Deprecated.
|
boolean |
flushIndexQueue()
Deprecated.
Triggers an index queue flush and blocks until flush is complete.
|
boolean |
flushIndexQueue(long time,
TimeUnit unit)
Deprecated.
|
void |
flushIndexQueueAndVerify(ContentEntity... contentEntities)
Deprecated.
Flush the entire index queue, and explicitly assert that the given content entities had their most recent
index queue journal entries processed.
|
void |
flushIndexQueueAndVerify(Iterable<? extends ContentEntity> contentEntities)
Deprecated.
|
void |
flushMailQueue()
Deprecated.
waits for all async events to be processed and flushes mail queue
waiting is needed because otherwise there's a chance that mail won't
be in queue at time of flushing
|
void |
follow(User user)
Deprecated.
Follows the given user with the logged in user.
|
void |
followUsers(User follower,
Iterable<User> followees)
Deprecated.
|
List<Map> |
getAliveThreads()
Deprecated.
|
List<Page> |
getAncestors(Page homePage)
Deprecated.
|
String |
getAnonymoizedCurrentClusterNodeIdentifier()
Deprecated.
|
Object |
getApplicationConfigProperty(String propertyKey)
Deprecated.
|
Attachment |
getAttachment(long contentId,
String fileName)
Deprecated.
|
byte[] |
getAttachmentData(Attachment attachment,
String version)
Deprecated.
|
byte[] |
getAttachmentData(long contentId,
String fileName,
String version)
Deprecated.
|
long |
getAttachmentId(long contentId,
String fileName)
Deprecated.
|
List<Attachment> |
getAttachments(Page homePage)
Deprecated.
|
Object |
getBandanaValue(String context,
String key)
Deprecated.
|
String |
getBaseUrl()
Deprecated.
|
BlogPost |
getBlogPost(long pageId)
Deprecated.
Returns the blog post with the specified page ID.
|
Integer |
getCacheMaximumNumberOfElements(String cacheName)
Deprecated.
since 5.6. Use
CacheRpc.getCacheMaxEntries(String) directly. |
CacheStatistics |
getCacheStatistics(CacheKey key)
Deprecated.
|
Set<CacheStatistics.Capability> |
getCacheStatisticsCapabilities()
Deprecated.
|
List<Page> |
getChildren(long parentPageId)
Deprecated.
|
Map<String,Object> |
getClusterInformation()
Deprecated.
|
Comment |
getComment(AbstractPageEntity pageEntity,
long commentId)
Deprecated.
|
List<Comment> |
getComments(Page page)
Deprecated.
|
String |
getConfiguredBaseUrl()
Deprecated.
Returns the configured base url on the server.
|
String |
getConfiguredThemeForSpace(String spaceKey)
Deprecated.
|
long |
getContentPermissionId(ContentPermission contentPermission,
long pageId)
Deprecated.
|
long |
getContentPermissionId(long pageId,
String permissionType,
String username)
Deprecated.
|
List<Map<String,String>> |
getContentPermissions(long contentId,
ContentPermissionType permissionType)
Deprecated.
|
Map<String,Object> |
getContentPermissionSet(long contentId,
ContentPermissionType permissionType)
Deprecated.
|
String |
getContentPropertiesString(long contentId,
String key)
Deprecated.
Uses
ContentProperties . |
String |
getContentPropertiesStringForSpace(String spaceKey,
String key)
Deprecated.
Uses
ContentProperties associated with the SpaceDescription . |
String |
getContentProperty(long contentId,
String key)
Deprecated.
Uses
ContentPropertyManager . |
List<String> |
getContentPropertyKeys(long contentId)
Deprecated.
Uses
ContentPropertyManager . |
String |
getContentTextProperty(long contentId,
String key)
Deprecated.
Uses
ContentPropertyManager . |
Vector<Hashtable> |
getCusterNodeStatuses()
Deprecated.
|
DarkFeaturesHelper |
getDarkFeaturesHelper()
Deprecated.
|
String |
getDatabaseStatistics()
Deprecated.
|
List<Page> |
getDescendents(Page homePage)
Deprecated.
|
Page |
getExistingPage(long pageId)
Deprecated.
Retrieve the
Page object for a page, known to
exist in confluence. |
Page |
getExistingPage(Space space,
String pageTitle)
Deprecated.
Retrieve the fully populated
Page object for a page, known to
exist in confluence. |
String |
getExportBuildNumber()
Deprecated.
|
String |
getFriendlyRelativeDate(Date now,
Date date,
TimeZone timeZone)
Deprecated.
Use the
FriendlyDateFormatter to format the date relative to the "now" time. |
String |
getGlobalConfiguredTheme()
Deprecated.
|
List<GlobalPermission> |
getGlobalPermissions(Group group)
Deprecated.
Old XML-RPC method.
|
List<Group> |
getGroups()
Deprecated.
Retrieves existing groups
|
List<SearchResult> |
getLabelContent(long labelId)
Deprecated.
|
List<SearchResult> |
getLabelContent(String labelName)
Deprecated.
|
List<SearchResult> |
getLabelContentByObject(Object remoteLabel)
Deprecated.
Returns the content for a given label object
|
List<Label> |
getLabels(long pageId)
Deprecated.
Retrieves the labels for the page matching the specified pageId
|
List<Label> |
getLabels(String labelName,
String namespace,
String spaceKey,
String owner)
Deprecated.
Retrieves the labels matching the given labelName, namespace or owner.
|
String |
getLocalisedText(String messageKey)
Deprecated.
Returns the localised message text for the given key, retrieved from the application via RPC.
|
String |
getLoggedInUser()
Deprecated.
|
int |
getMailQueueSize()
Deprecated.
|
List<Label> |
getMostPopularLabels(int maxCount)
Deprecated.
Returns the most popular labels
|
List<Label> |
getMostPopularLabelsInSpace(String spaceKey,
int maxCount)
Deprecated.
Returns the most popular labels in the space with the specified key
|
int |
getNumberOfActiveUsers()
Deprecated.
|
int |
getNumberOfIndexTasksInQueue()
Deprecated.
|
String |
getOldestSpaceImportAllowed()
Deprecated.
|
String |
getPageContent(long pageId)
Deprecated.
|
List<Map<String,String>> |
getPageHistory(Page homePage)
Deprecated.
|
long |
getPageId(Page page)
Deprecated.
|
long |
getPageId(String spaceKey,
String title)
Deprecated.
|
List<Long> |
getPageIdsInSpace(Space space)
Deprecated.
|
Collection<ContentPermissionEntry> |
getPagePermissions(long pageId)
Deprecated.
|
List<Page> |
getPagesInSpace(Space space)
Deprecated.
|
Page |
getPageWithDetails(long pageId)
Deprecated.
A heavier version of
getExistingPage(long) , that makes several calls to the server to flesh out
the space and the last modifier. |
long |
getParentId(long pageId)
Deprecated.
|
List<String> |
getPermissionsForUser(Space space,
User user)
Deprecated.
Old XML-RPC method.
|
List<String> |
getPermissionsForUser(String spaceKey,
String username)
Deprecated.
Old XML-RPC method.
|
long |
getPersonalInformationId(String username)
Deprecated.
|
String |
getPluginExportCompatibility(String pluginKey)
Deprecated.
|
PluginHelper |
getPluginHelper()
Deprecated.
Retrieve a PluginHelper that manipulates plugin using this ConfluenceRpc.
|
List<Label> |
getRecentlyUsedLabels(int maxCount)
Deprecated.
Returns the recently used labels for the Confluence instance, with a specified maximum number
of results.
|
List<Label> |
getRecentlyUsedLabelsInSpace(String spaceKey,
int maxCount)
Deprecated.
Returns the recently used labels in the space with the specified key
|
List<Label> |
getRelatedLabels(String labelName,
int maxCount)
Deprecated.
Returns the labels related to the given label name
|
List<Label> |
getRelatedLabelsInSpace(String labelName,
String spaceKey,
int maxCount)
Deprecated.
Returns the labels related to the given label name in the given space
|
Map<String,Object> |
getServerInfo()
Deprecated.
|
Space |
getSpace(String spaceKey)
Deprecated.
Returns the space with the specified key.
|
List<Space> |
getSpaces()
Deprecated.
Retrieves spaces visible to the currently logged in rpc user
|
List<Space> |
getSpacesContainingContentWithLabel(String labelName)
Deprecated.
|
List<Space> |
getSpacesWithLabel(String labelName)
Deprecated.
|
String |
getStackDump(String threadNameRegex)
Deprecated.
|
String |
getSystemProperty(String name)
Deprecated.
Retrieve the value of the specified System property on the Confluence server.
|
List<Page> |
getTopLevelPages(String spaceKey)
Deprecated.
|
UserWithKey |
getUser(String username)
Deprecated.
Retrieves a user with the given username
|
UserWithKey |
getUser(String username,
String password)
Deprecated.
|
UserWithKey |
getUser(User user)
Deprecated.
|
List<Group> |
getUserGroups(String username)
Deprecated.
Retrieves the groups that a user matching the specified username belongs to
|
UserInformation |
getUserInformation(String username)
Deprecated.
|
UserInformation |
getUserInformation(User user)
Deprecated.
|
Locale |
getUserLocale(User user)
Deprecated.
|
List<String> |
getUsernames(boolean viewAll)
Deprecated.
Retrieves the usernames of the current system users
|
void |
grantAllPermissions(Entity entity,
Space space)
Deprecated.
Use
rpc.admin.permissions. PermissionsRpc.addSpaceUserPermissions(java.lang.String, java.lang.String, com.atlassian.confluence.it.SpacePermission...)
or PermissionsRpc.addSpaceGroupPermissions(java.lang.String, java.lang.String, com.atlassian.confluence.it.SpacePermission...)
or PermissionsRpc.addSpaceAnonymousPermissions(java.lang.String, com.atlassian.confluence.it.SpacePermission...) instead. |
void |
grantAllPermissionsExceptAdmin(Entity entity,
Space space)
Deprecated.
|
void |
grantAnonymousPermission(SpacePermission permission,
Space space)
Deprecated.
Old XML-RPC method.
Use
rpc.admin.permissions. PermissionsRpc.addSpaceAnonymousPermissions(java.lang.String, com.atlassian.confluence.it.SpacePermission...) instead. |
void |
grantAnonymousUsePermission()
Deprecated.
Old XML-RPC method.
Use
rpc.admin.permissions. PermissionsRpc.enableAnonymousUseConfluence() instead. |
boolean |
grantAnonymousViewUserProfilePermission()
Deprecated.
Old XML-RPC method.
Use
rpc.admin.permissions. PermissionsRpc.addGlobalAnonymousPermissions(com.atlassian.confluence.it.GlobalPermission...) instead. |
void |
grantContentPermission(ContentEntity contentEntity,
Entity entity,
ContentPermissionType permissionType)
Deprecated.
|
void |
grantContentPermission(ContentPermission contentPermission,
ContentEntity contentEntity)
Deprecated.
|
void |
grantContentPermissions(ContentEntity contentEntity,
List<? extends Entity> entities,
ContentPermissionType permissionType)
Deprecated.
|
void |
grantPermission(GlobalPermission permission,
Entity entity)
Deprecated.
Old XML-RPC method.
Use
rpc.admin.permissions. PermissionsRpc.addGlobalUserPermissions(java.lang.String, com.atlassian.confluence.it.GlobalPermission...)
or PermissionsRpc.addGlobalGroupPermissions(java.lang.String, com.atlassian.confluence.it.GlobalPermission...) instead. |
void |
grantPermission(SpacePermission permission,
Space space,
Entity entity)
Deprecated.
Old XML-RPC method.
Use
rpc.admin.permissions. PermissionsRpc.addSpaceUserPermissions(java.lang.String, java.lang.String, com.atlassian.confluence.it.SpacePermission...)
or PermissionsRpc.addSpaceGroupPermissions(java.lang.String, java.lang.String, com.atlassian.confluence.it.SpacePermission...)
or PermissionsRpc.addSpaceAnonymousPermissions(java.lang.String, com.atlassian.confluence.it.SpacePermission...) instead. |
void |
grantPermission(SpacePermission permission,
String spaceKey,
Entity entity)
Deprecated.
Old XML-RPC method.
Use
rpc.admin.permissions. PermissionsRpc.addSpaceUserPermissions(java.lang.String, java.lang.String, com.atlassian.confluence.it.SpacePermission...)
or PermissionsRpc.addSpaceGroupPermissions(java.lang.String, java.lang.String, com.atlassian.confluence.it.SpacePermission...)
or PermissionsRpc.addSpaceAnonymousPermissions(java.lang.String, com.atlassian.confluence.it.SpacePermission...) instead. |
void |
grantPermissions(Space space,
Entity entity,
SpacePermission... permissions)
Deprecated.
Old XML-RPC method.
Use
rpc.admin.permissions. PermissionsRpc.addSpaceUserPermissions(java.lang.String, java.lang.String, com.atlassian.confluence.it.SpacePermission...)
or PermissionsRpc.addSpaceGroupPermissions(java.lang.String, java.lang.String, com.atlassian.confluence.it.SpacePermission...)
or PermissionsRpc.addSpaceAnonymousPermissions(java.lang.String, com.atlassian.confluence.it.SpacePermission...) instead. |
boolean |
hasGroup(String groupname)
Deprecated.
Checks whether or not a group matching the specified name exists
|
boolean |
hasUser(String username)
Deprecated.
Checks whether a user with the specified username exists
|
void |
importSpace(byte[] zippedXmlBackup)
Deprecated.
|
void |
importSpace(File zippedXmlBackup)
Deprecated.
|
void |
increaseHighValue()
Deprecated.
|
boolean |
isActiveUser(String username)
Deprecated.
Checks whether the user is active
|
boolean |
isClusteredInstance()
Deprecated.
|
boolean |
isDarkFeatureEnabled(String key)
Deprecated.
|
boolean |
isImportTaskRunning()
Deprecated.
|
boolean |
isPluginUpgradeTasksComplete()
Deprecated.
|
boolean |
isSpringComponentPresent(String componentName)
Deprecated.
|
boolean |
isUnlimitedUserLicense()
Deprecated.
|
void |
logIn(User user)
Deprecated.
Set the current user logged into this rpc client.
|
boolean |
logMessage(RpcLogDestination destination,
String message)
Deprecated.
Logs a message on the server at a specified log level or to sout or syserr.
|
void |
logOut()
Deprecated.
|
void |
moveBlogPost(BlogPost blogPost,
Space targetSpace)
Deprecated.
|
void |
movePage(long sourcePageId,
long targetPageId,
String position)
Deprecated.
|
void |
movePage(Page page,
Page target,
String position)
Deprecated.
Move a page "to" another page.
|
void |
movePageToTopLevel(Page page,
Space targetSpace)
Deprecated.
Moves a page to the top of the target space
|
static ConfluenceRpc |
newInstance(BaseUrlSelector baseUrlSelector)
Deprecated.
Create a new RPC stub pointed at the default version of the server-side API.
|
static ConfluenceRpc |
newInstance(BaseUrlSelector baseUrlSelector,
com.sun.jersey.api.client.Client restClient)
Deprecated.
|
static ConfluenceRpc |
newInstance(BaseUrlSelector baseUrlSelector,
ConfluenceRpc.Version version)
Deprecated.
Create a new RPC stub pointed at a specific version of the server-side API.
|
static ConfluenceRpc |
newInstance(String baseUrl)
Deprecated.
Create a new RPC stub pointed at the default version of the server-side API.
|
static ConfluenceRpc |
newInstance(String baseUrl,
com.sun.jersey.api.client.Client restClient)
Deprecated.
|
static ConfluenceRpc |
newInstance(String baseUrl,
ConfluenceRpc.Version version)
Deprecated.
Create a new RPC stub pointed at a specific version of the server-side API.
|
static ConfluenceRpc |
newInstanceForSetup(String baseUrl,
ConfluenceRpc.Version version)
Deprecated.
Create a new RPC stub pointed at a specific version of the server-side API, for use with Setup acceptance tests.
|
protected Hashtable<String,String> |
object(String... args)
Deprecated.
|
void |
pauseAllJobs()
Deprecated.
|
void |
pauseJob(QuartzJob job)
Deprecated.
since 5.10. Use
SchedulerRpc.pauseJob(ScheduledJobKey) . |
void |
pauseJob(ScheduledJobKey job)
Deprecated.
|
void |
pauseJob(String jobSpec)
Deprecated.
Since 5.6. Use
SchedulerRpc.pauseJob(ScheduledJobKey) . |
void |
pauseJobGroup(String jobGroupName)
Deprecated.
|
String |
performBackup(boolean exportAttachments)
Deprecated.
|
void |
purgeFromTrash(Space space,
long pageId)
Deprecated.
Since 5.6. Just call
ContentRpc.purge(ContentId) directly. |
void |
putStringMappingInCache(String cacheName,
String entryKey,
String value)
Deprecated.
|
boolean |
reactivateUser(String username)
Deprecated.
Reactivates the user matching the specified username
|
boolean |
recoverMainIndex()
Deprecated.
|
void |
registerEventListener(String eventClassName)
Deprecated.
|
void |
removeAllJohnsonEvents()
Deprecated.
|
void |
removeAllSpaces()
Deprecated.
|
void |
removeAttachment(long pageId,
String fileName)
Deprecated.
|
void |
removeAttachmentUncleanly(long pageId,
String fileName)
Deprecated.
|
void |
removeBandanaKey(String context,
String key)
Deprecated.
|
void |
removeComment(Comment comment)
Deprecated.
|
void |
removeComment(long commentId)
Deprecated.
Remove a comment, identified by its id.
|
void |
removeDrafts(User user)
Deprecated.
|
boolean |
removeGroup(Group group)
Deprecated.
Removes the group if it exists, otherwise does nothing
|
boolean |
removeGroup(String groupname,
String defaultGroupName)
Deprecated.
Removes the group if it exists, otherwise does nothing
|
boolean |
removeLabel(long labelId,
long contentId)
Deprecated.
Removes a label from the specified content
|
boolean |
removeLabel(String label,
Page page)
Deprecated.
Removes a label from the specified page
|
boolean |
removeLabelByObject(Object remoteLabel,
Page page)
Deprecated.
Removes a label from the specified page
|
boolean |
removeLabelFromSpace(String label,
Space space)
Deprecated.
Removes a label from the specified space
|
void |
removeMailServer(String serverName)
Deprecated.
|
boolean |
removePage(long pageId)
Deprecated.
|
boolean |
removePage(Page page)
Deprecated.
|
boolean |
removePageVersion(long historicalPageId)
Deprecated.
|
boolean |
removePageVersion(long pageId,
int version)
Deprecated.
|
void |
removePersonalInformation(User user)
Deprecated.
PersonalInformation gets created automatically by the rpc create user method.
|
boolean |
removeSpace(String spaceKey)
Deprecated.
Removes the space if it exists, otherwise does nothing.
|
void |
removeTestData(Set<User> usersToKeep,
Set<Group> groupsToKeep,
Map<Group,HashSet<User>> userGroupMembershipsToKeep)
Deprecated.
Perform all test-data reset tasks.
|
void |
removeTestDataAfterExternalUserManagement()
Deprecated.
Called on an instance that manages User/Group data externally, this will:
1.
|
boolean |
removeUser(String username)
Deprecated.
Removes the user if it exists, otherwise does nothing.
|
void |
removeUser(User user)
Deprecated.
|
boolean |
removeUserDirectory(long directoryId)
Deprecated.
|
boolean |
removeUserFromGroup(String username,
String groupname)
Deprecated.
|
boolean |
removeUserFromGroup(User user,
Group group)
Deprecated.
|
void |
removeUserMacro(String name)
Deprecated.
|
boolean |
renameUser(String oldUsername,
String newUsername)
Deprecated.
|
void |
resetDatabaseStatistics()
Deprecated.
|
boolean |
resetWelcomeMessage()
Deprecated.
|
void |
restoreAbstractPage(long id)
Deprecated.
|
void |
resumeJob(QuartzJob job)
Deprecated.
since 5.10. Use
SchedulerRpc.resumeJob(ScheduledJobKey) . |
void |
resumeJob(ScheduledJobKey job)
Deprecated.
|
void |
resumeJob(String jobSpec)
Deprecated.
Since 5.6. Use
SchedulerRpc.resumeJob(ScheduledJobKey) . |
boolean |
revokeAllPermissions(Group group)
Deprecated.
Old XML-RPC method.
No exact replacement.
Use
rpc.admin.permissions. PermissionsRpc.removeAllGlobalGroupPermissions(java.lang.String) ,
and PermissionsRpc.removeAllSpaceGroupPermissions(java.lang.String, java.lang.String) for the appropriate spaces. |
void |
revokeAnonymousPermission(SpacePermission permission,
Space space)
Deprecated.
Old XML-RPC method.
Use
rpc.admin.permissions. PermissionsRpc.removeSpaceAnonymousPermissions(java.lang.String, com.atlassian.confluence.it.SpacePermission...) instead. |
void |
revokeAnonymousUsePermission()
Deprecated.
Old XML-RPC method.
Use
rpc.admin.permissions. PermissionsRpc.disableAnonymousUseConfluence() instead. |
void |
revokeAnonymousViewUserProfilePermission()
Deprecated.
Old XML-RPC method.
Use
rpc.admin.permissions. PermissionsRpc.removeGlobalAnonymousPermissions(com.atlassian.confluence.it.GlobalPermission...) instead. |
void |
revokeContentPermission(ContentPermission contentPermission,
ContentEntity contentEntity)
Deprecated.
|
void |
revokePermission(GlobalPermission permission,
Entity entity)
Deprecated.
Old XML-RPC method.
Use
rpc.admin.permissions. PermissionsRpc.removeGlobalUserPermissions(java.lang.String, com.atlassian.confluence.it.GlobalPermission...)
or PermissionsRpc.removeGlobalGroupPermissions(java.lang.String, com.atlassian.confluence.it.GlobalPermission...) instead. |
void |
revokePermission(SpacePermission permission,
Space space,
Entity entity)
Deprecated.
Old XML-RPC method.
Use
rpc.admin.permissions. PermissionsRpc.removeSpaceUserPermissions(java.lang.String, java.lang.String, com.atlassian.confluence.it.SpacePermission...)
or PermissionsRpc.removeSpaceAnonymousPermissions(java.lang.String, com.atlassian.confluence.it.SpacePermission...)
or PermissionsRpc.removeSpaceGroupPermissions(java.lang.String, java.lang.String, com.atlassian.confluence.it.SpacePermission...) instead. |
void |
revokePermissions(Space space,
Entity entity,
SpacePermission... permissions)
Deprecated.
Old XML-RPC method.
Use
rpc.admin.permissions. PermissionsRpc.removeSpaceUserPermissions(java.lang.String, java.lang.String, com.atlassian.confluence.it.SpacePermission...)
or PermissionsRpc.removeSpaceAnonymousPermissions(java.lang.String, com.atlassian.confluence.it.SpacePermission...)
or PermissionsRpc.removeSpaceGroupPermissions(java.lang.String, java.lang.String, com.atlassian.confluence.it.SpacePermission...) instead. |
void |
runGarbageCollection()
Deprecated.
|
void |
runJob(QuartzJob job)
Deprecated.
since 5.10. Use
runJob(ScheduledJobKey) . |
void |
runJob(ScheduledJobKey job)
Deprecated.
Triggers a job on the server.
|
void |
runJob(String jobSpec)
Deprecated.
Since 5.6. Use
runJob(ScheduledJobKey) . |
long |
saveBlogPost(BlogPost blogPost)
Deprecated.
|
long |
saveComment(Comment comment)
Deprecated.
|
void |
saveDateFormat(String pattern)
Deprecated.
|
long |
savePage(Page page)
Deprecated.
|
List<Hashtable<String,String>> |
search(String queryString,
Hashtable<String,String> params,
int maxMatches)
Deprecated.
|
List<Hashtable<String,String>> |
search(String queryString,
int maxMatches)
Deprecated.
Search for the supplied query String.
|
void |
setApplicationConfigProperty(String propertyKey,
String propertyValue)
Deprecated.
|
void |
setBandanaKey(String context,
String key,
boolean value)
Deprecated.
|
void |
setBandanaKey(String context,
String key,
int value)
Deprecated.
|
void |
setBandanaKey(String context,
String key,
List<String> value)
Deprecated.
|
void |
setBandanaKey(String context,
String key,
Set<String> value)
Deprecated.
|
void |
setBandanaKey(String context,
String key,
String value)
Deprecated.
|
void |
setBlogRestriction(ContentPermission contentPermission,
BlogPost blogPost)
Deprecated.
Restricts blog post to single given user or group, wiping out any other existing restrictions.
|
void |
setCacheMaximumNumberOfElements(String cacheName,
int maxNumElements)
Deprecated.
since 5.6. Use
CacheRpc.setCacheMaxEntries(String, int) directly. |
void |
setContentPropertiesString(long contentId,
String key,
String value)
Deprecated.
Uses
ContentProperties . |
void |
setContentPropertiesStringForSpace(String spaceKey,
String key,
String value)
Deprecated.
Uses
ContentProperties associated with the SpaceDescription . |
void |
setContentRestriction(ContentPermission contentPermission,
AbstractPageEntity abstractPage)
Deprecated.
Restricts page or blog post to single given user or group, wiping out any other existing restrictions.
|
void |
setContentTextProperty(long contentId,
String key,
String value)
Deprecated.
Uses
ContentPropertyManager . |
void |
setDirectoryPasswordEncoder(String directoryName,
String encoder)
Deprecated.
|
void |
setDraftRestriction(ContentPermission contentPermission,
Draft draft)
Deprecated.
Restricts blog post to single given user or group, wiping out any other existing restrictions.
|
void |
setDraftSaveInterval(int seconds)
Deprecated.
|
void |
setEnableAnonymousAccess(boolean enable)
Deprecated.
Old XML-RPC method.
Use
rpc.admin.permissions. PermissionsRpc.enableAnonymousUseConfluence()
or PermissionsRpc.disableAnonymousUseConfluence() instead. |
void |
setEnableAnonymousRpc(boolean enable)
Deprecated.
|
void |
setGlobalLanguage(String locale)
Deprecated.
|
void |
setGlobalTheme(BundledTheme theme)
Deprecated.
|
void |
setKeyboardShortcutPref(User user,
boolean enabled)
Deprecated.
|
org.apache.log4j.Level |
setLogLevel(String logger,
org.apache.log4j.Level level)
Deprecated.
Sets the log level of the specified logger, returning the old value.
|
void |
setPageRestriction(ContentPermission contentPermission,
Page page)
Deprecated.
Restricts page to a single given user or group, wiping out any other existing restrictions.
|
void |
setPageRestriction(Page page,
Entity entity,
ContentPermissionType contentPermissionType)
Deprecated.
Restrict page to single given user or group.
|
void |
setSmtpServer(String serverName,
String from,
String subjectPrefix,
String hostname,
int port)
Deprecated.
|
void |
setSmtpServer(String serverName,
String from,
String subjectPrefix,
String hostname,
int port,
String fromName)
Deprecated.
|
void |
setSystemProperty(String name,
String value)
Deprecated.
Set the specified System property on the Confluence server.
|
void |
setThemeForSpace(Space space,
BundledTheme theme)
Deprecated.
|
boolean |
setUserDetailProperty(User user,
String key,
String value)
Deprecated.
Update a UserDetail property via the
UserDetailsManager . |
boolean |
setUserInformation(UserInformation userInfo)
Deprecated.
Updates a user's information
|
void |
setUserLocale(User user,
Locale language)
Deprecated.
|
boolean |
setUserPreference(User user,
String key,
boolean value)
Deprecated.
|
boolean |
setUserPreference(User user,
String key,
String value)
Deprecated.
|
long |
setUserStatus(String wikiStatus)
Deprecated.
Sets the current user's status.
|
void |
setWatchOwnContent(User user,
boolean enabled)
Deprecated.
|
void |
setWebSudoTimeout(int timeout)
Deprecated.
|
boolean |
setWelcomeMessage(String welcomeMessage)
Deprecated.
|
void |
stopFollowing(User user)
Deprecated.
Stop following the given user.
|
void |
synchroniseUserDirectories()
Deprecated.
Synchronises all the directories which support synchronisation (LDAP, remote Crowd, etc.)
|
com.atlassian.fugue.Option<Object> |
tryGetApplicationConfigProperty(String propertyKey)
Deprecated.
|
void |
unarchiveSpace(Space space)
Deprecated.
|
void |
unregisterEventListener(String eventClassName)
Deprecated.
|
long |
updateDraft(Draft draft)
Deprecated.
|
boolean |
updateGlobalSetting(String name,
boolean value)
Deprecated.
|
String |
updateGlobalSetting(String name,
String value)
Deprecated.
|
long |
updatePage(Page page,
boolean minorEdit,
String versionComment)
Deprecated.
Saves pages, but not blogs, see
saveBlogPost(BlogPost) . |
void |
useAnonymously()
Deprecated.
Indicate that further rpc calls should be made anonymously, rather than as a specific user.
|
void |
waitForEvent(String eventClassName,
String timeoutInSeconds)
Deprecated.
|
void |
waitForEventQueue()
Deprecated.
|
public final NotificationsRpc notifications
public final UserPreferencesRpc userPreferences
public final LikesRpc likes
public final MailRpc mail
public final DarkFeaturesHelper darkFeatures
public final ContentRpc content
public final SpaceRpc spaces
public final AttachmentRpc attachments
public final LabelsRpc labels
public final AdminRpc admin
public final AuthenticatedWebResourceProvider baseResourceProvider
public String getFriendlyRelativeDate(Date now, Date date, TimeZone timeZone)
FriendlyDateFormatter
to format the date relative to the "now" time.
Note that the output format varies greatly even from second to second -- see FriendlyDateFormatter
.now
- the date which the relative time is calculated in relation todate
- the date of some event which is to be formattedtimeZone
- the current time zoneFriendlyDateFormatter
public void flushIndexQueueAndVerify(ContentEntity... contentEntities)
public void flushIndexQueueAndVerify(Iterable<? extends ContentEntity> contentEntities)
public static ConfluenceRpc newInstance(String baseUrl, ConfluenceRpc.Version version)
baseUrl
- the base URL of the server to connect toversion
- the version of the API to usepublic static ConfluenceRpc newInstance(BaseUrlSelector baseUrlSelector, ConfluenceRpc.Version version)
baseUrlSelector
- the base URL of the server to connect toversion
- the version of the API to usepublic static ConfluenceRpc newInstanceForSetup(String baseUrl, ConfluenceRpc.Version version)
This method should only be called by Setup tests where the ConfluenceRpc instance is created *before* the
plugin system is started. Other tests should call newInstance(String)
.
baseUrl
- the base URL of the server to connect toversion
- the version of the API to usepublic static ConfluenceRpc newInstance(String baseUrl)
baseUrl
- the base URL of the server to connect topublic static ConfluenceRpc newInstance(BaseUrlSelector baseUrlSelector)
baseUrlSelector
- the base URL of the server to connect to@Deprecated public static ConfluenceRpc newInstance(String baseUrl, com.sun.jersey.api.client.Client restClient)
baseUrl
- the base URL of the server to connect torestClient
- the jersey client to use when create WebResourcespublic static ConfluenceRpc newInstance(BaseUrlSelector baseUrlSelector, com.sun.jersey.api.client.Client restClient)
public void close()
close
in interface AutoCloseable
@Deprecated public Object execute(String method, Object... args) throws RpcRuntimeException
executeOnCurrentNode(String, Object...)
method
- the name of the rpc method to callargs
- the arguments to be passed to the method. Token will automatically be included first. The rest should
be strings or HashTables or Vectors. Longs will be automatically converted to strings to save
the hassle of manually converting object IDsRpcRuntimeException
- wrapping the underlying remote exceptionlogIn(User)
,
useAnonymously()
public Object executeWithToken(String method, @Nullable String token, Object... args) throws RpcRuntimeException
execute(String, Object...)
as them instead. There only time when you should use this is when
testing something related to the tokens themselves (e.g. authentication tests)method
- the method to executetoken
- the tokenargs
- arguments to pass to the XML RPC methodRpcRuntimeException
- If the server throws an exceptionpublic Object executePluginXmlRpc(String servicePath, String method, Object... args) throws RpcRuntimeException
servicePath
- service path of the plugin xmlrpc modulemethod
- the name of the rpc method to callargs
- the arguments to be passed to the method. The rest should
be strings or HashTables or Vectors. Longs will be automatically converted to strings to save
the hassle of manually converting object IDsRpcRuntimeException
- wrapping the underlying remote exception@Deprecated public Object executeAuthPluginXmlRpc(String servicePath, String method, Object... args) throws RpcRuntimeException
executeAuthPluginXmlRpcOnCurrentNode(String, String, Object...)
servicePath
- service path of the plugin xmlrpc modulemethod
- the name of the rpc method to callargs
- the arguments to be passed to the method. The rest should
be strings or HashTables or Vectors. Longs will be automatically converted to strings to save
the hassle of manually converting object IDsRpcRuntimeException
- wrapping the underlying remote exceptionpublic <T> T executeAuthPluginXmlRpcOnCurrentNode(String servicePath, String method, Object... args)
@Deprecated public Object executeFuncTest(String method, Object... args) throws RpcRuntimeException
executeFuncTestOnCurrentNode(String, Object...)
method
- the name of the rpc method to callargs
- the arguments to be passed to the method. Token will automatically be included first. The rest should
be strings or HashTables or Vectors. Longs will be automatically converted to strings to save
the hassle of manually converting object IDsRpcRuntimeException
- wrapping the underlying remote exceptionpublic <T> T executeFuncTestOnCurrentNode(String method, Object... args)
method
- the name of the rpc method to callargs
- the arguments to be passed to the method. Token will automatically be included first. The rest should
be strings or HashTables or Vectors. Longs will be automatically converted to strings to save
the hassle of manually converting object IDsRpcRuntimeException
- wrapping the underlying remote exception@Deprecated protected Object executeFuncTestWithToken(String method, String token, Object... args) throws RpcRuntimeException
method
- the method to executetoken
- the tokenRpcRuntimeException
@Deprecated protected Object executeRpc(String rpcBase, String methodToken, String method, Object... args) throws RpcRuntimeException
RpcRuntimeException
public void logIn(User user)
logOut()
or useAnonymously()
are called.public void useAnonymously()
logIn(com.atlassian.confluence.it.User)
or logOut()
are called.public void logOut()
public long getPageId(Page page)
public String getPageContent(long pageId)
public String convertWikiMarkupToXhtml(String wikiMarkup, long pageId)
public String convertXhtmlToWikiMarkup(String xhtml, long pageId)
@Deprecated public Map<String,String> createPage(String spaceKey, String title, String content, long parentPageId)
createPage(Page)
.public long createPage(Page page)
page
- an uncreated page@Deprecated public long createWikiMarkupPage(Page page)
createPage(Page)
page
- an uncreated page with wiki markup contentpublic List<Page> createPagesFromPrototype(Page pageTemplate, int count)
public long createTemplate(String templateName, String content, Space space)
public long createTemplateWithStorageFormat(String templateName, String storageFormat, Space space)
public void editPage(Space space, String pageTitle, String newTitle, String newContent)
space
- the space that the page belongs topageTitle
- the current title of the PagenewTitle
- the new title of the Page (null if the same)newContent
- the new content of the Page (null if the same)public boolean removePage(Page page)
public boolean removePage(long pageId)
public boolean removePageVersion(long historicalPageId)
public boolean removePageVersion(long pageId, int version)
public void restoreAbstractPage(long id)
public void changePageCreatedDate(long id, Date newDate)
public Page getExistingPage(Space space, String pageTitle)
Page
object for a page, known to
exist in confluence.public Page getExistingPage(long pageId)
Page
object for a page, known to
exist in confluence.public Page getPageWithDetails(long pageId)
getExistingPage(long)
, that makes several calls to the server to flesh out
the space and the last modifier.public BlogPost getBlogPost(long pageId)
public Space getSpace(String spaceKey)
public List<Page> getChildren(long parentPageId)
public long getParentId(long pageId)
public long savePage(Page page)
public long updatePage(Page page, boolean minorEdit, String versionComment)
saveBlogPost(BlogPost)
.public long createDraft(Draft draft)
public long updateDraft(Draft draft)
public void setPageRestriction(ContentPermission contentPermission, Page page)
setContentRestriction(com.atlassian.confluence.it.content.security.ContentPermission, com.atlassian.confluence.it.AbstractPageEntity)
should be used instead.public void setBlogRestriction(ContentPermission contentPermission, BlogPost blogPost)
setContentRestriction(com.atlassian.confluence.it.content.security.ContentPermission, com.atlassian.confluence.it.AbstractPageEntity)
should be used instead.public void setDraftRestriction(ContentPermission contentPermission, Draft draft)
setContentRestriction(com.atlassian.confluence.it.content.security.ContentPermission, com.atlassian.confluence.it.AbstractPageEntity)
should be used instead.public void setContentRestriction(ContentPermission contentPermission, AbstractPageEntity abstractPage)
public void setPageRestriction(Page page, Entity entity, ContentPermissionType contentPermissionType)
public long getContentPermissionId(ContentPermission contentPermission, long pageId)
public long getContentPermissionId(long pageId, String permissionType, String username)
public long createBlogPost(BlogPost blogPost)
public long saveBlogPost(BlogPost blogPost)
public long createComment(Comment comment)
@Deprecated public long createComment(Comment comment, long parentCommentId)
createComment(Comment)
with a Comment that has a parentId set.public long saveComment(Comment comment)
public void removeComment(long commentId)
commentId
- the id of the comment to removepublic void removeComment(Comment comment)
public void changeCommentCreatedDate(Comment comment, Date newCreationDate)
public long createAttachment(long contentId, Attachment attachment)
public long createAttachment(ContentEntity page, Attachment attachment)
public long createAttachment(Attachment attachment)
public long createAttachmentOnDraft(Attachment attachment)
public void removeAttachment(long pageId, String fileName)
public void removeAttachmentUncleanly(long pageId, String fileName)
public boolean addProfilePicture(String username, String filename, String mimeType, byte[] pictureData)
username
- the user name of the profilefilename
- file name of the picturemimeType
- image mime type (must be from image/*)pictureData
- the image datapublic boolean addExistingProfilePicture(String username, String filename)
username
- the user name of the profilefilename
- file name of the picturepublic boolean enableDailyReportNotification(User user, boolean dailyReportEnabled)
public void editAttachment(Attachment updatedAttachment)
public Attachment getAttachment(long contentId, String fileName)
public long getAttachmentId(long contentId, String fileName)
public List<Attachment> getAttachments(Page homePage)
public byte[] getAttachmentData(long contentId, String fileName, String version)
public byte[] getAttachmentData(Attachment attachment, String version)
public void movePage(long sourcePageId, long targetPageId, String position)
public void movePage(Page page, Page target, String position)
position
- see com.atlassian.confluence.content.service.page.MovePageCommandpublic void movePageToTopLevel(Page page, Space targetSpace)
page
- page to movetargetSpace
- the target spacepublic boolean addLabel(String label, AbstractContentEntity target)
public boolean addLabel(long labelId, long contentId)
labelId
- id of the label to addcontentId
- id of a page or blogpost to add the label topublic boolean addLabelByObject(Object remoteLabel, Page page)
remoteLabel
- the object retrieved from a direct call to an rpc method that returns a label, i.e. this parameter
should be the return value of execute(String, Object...)
and not any of wrapper methods that return a Label objectpage
- page to add the label topublic boolean removeLabel(String label, Page page)
label
- the name of the label to removepage
- the page to remove the label frompublic boolean removeLabel(long labelId, long contentId)
labelId
- id of the label to removecontentId
- id of the page or blog to remove the label frompublic boolean removeLabelByObject(Object remoteLabel, Page page)
remoteLabel
- the object retrieved from a direct call to an rpc method that returns a label, i.e. this parameter
should be the return value of execute(String, Object...)
and not any of wrapper methods that return a Label objectpage
- page to remove the label frompublic boolean addLabelToSpace(String label, Space space)
label
- the label to addspace
- the space to add the label topublic boolean removeLabelFromSpace(String label, Space space)
label
- the label to removespace
- the space to remove the label frompublic List<Space> getSpacesContainingContentWithLabel(String labelName)
public List<SearchResult> getLabelContent(long labelId)
public List<SearchResult> getLabelContent(String labelName)
public List<SearchResult> getLabelContentByObject(Object remoteLabel)
remoteLabel
- the object retrieved from a direct call to an rpc method that returns a label, i.e. this parameter
should be the return value of execute(String, Object...)
and not any of wrapper methods that return a Label objectpublic List<Label> getLabels(long pageId)
public List<Label> getLabels(String labelName, String namespace, String spaceKey, String owner)
labelName
- the name of the label to search for (not parsed for prefixes)namespace
- the namespace to restrict byspaceKey
- the key of the space to restrict byowner
- the owner of the labelspublic List<Label> getMostPopularLabels(int maxCount)
maxCount
- the maximum number of labels to return, or no limit if this is 0public List<Label> getMostPopularLabelsInSpace(String spaceKey, int maxCount)
spaceKey
- key for the spacemaxCount
- the maximum number of labels to return, or no limit if this is 0public List<Label> getRecentlyUsedLabels(int maxCount)
maxCount
- the maximum number of labels to return, or the default if this is 0public List<Label> getRecentlyUsedLabelsInSpace(String spaceKey, int maxCount)
spaceKey
- key for the spacemaxCount
- the maximum number of labels to return, or the default if this is 0public List<Label> getRelatedLabels(String labelName, int maxCount)
labelName
- name of the label to find related labels withmaxCount
- the maximum number of labels to return, or the default if this is 0public List<Label> getRelatedLabelsInSpace(String labelName, String spaceKey, int maxCount)
labelName
- name of the label to find related labels withspaceKey
- the key of the space to search inmaxCount
- the maximum number of labels to return, or the default if this is 0@Deprecated public Space createSpace(String key, String name, String description)
Space
and call createSpace(Space)
.public boolean removeSpace(String spaceKey)
public List<Space> getSpaces()
public boolean createUser(User user)
public boolean createUser(User user, boolean notifyUser)
public int createTestUsers(int count)
public UserWithKey getUser(String username)
public UserWithKey getUser(User user)
public UserWithKey getUser(String username, String password)
public UserInformation getUserInformation(User user)
public UserInformation getUserInformation(String username)
public boolean setUserInformation(UserInformation userInfo)
public boolean setUserDetailProperty(User user, String key, String value)
UserDetailsManager
.public boolean setUserPreference(User user, String key, boolean value)
public List<String> getUsernames(boolean viewAll)
viewAll
- If false, all usernames in the default users group will be returned. Otherwise, every registered username is returned.public boolean changeUserPassword(String username, String newPassword)
public boolean changeMyPassword(String oldPassword, String newPassword)
public boolean editUser(User user)
public void removeUser(User user)
public boolean removeUser(String username)
public boolean hasUser(String username)
public boolean deactivateUser(String username)
public boolean reactivateUser(String username)
public boolean isActiveUser(String username)
username
- The username of the user whose status to checkpublic void createGroup(String groupname)
public void createGroup(Group group)
public boolean removeGroup(Group group)
public boolean removeGroup(String groupname, String defaultGroupName)
groupname
- the group to removedefaultGroupName
- another group to put existing members of the group in. Can be an empty
string if users should not be added to any other group.public boolean hasGroup(String groupname)
public List<Group> getGroups()
public List<Group> getUserGroups(String username)
public boolean removeUserFromGroup(String username, String groupname)
public String exportSpace(Space space, String exportType)
public String exportSite(boolean exportAttachments)
public String performBackup(boolean exportAttachments)
public Map<String,Object> getContentPermissionSet(long contentId, ContentPermissionType permissionType)
public List<Map<String,String>> getContentPermissions(long contentId, ContentPermissionType permissionType)
@Deprecated public List<String> getPermissionsForUser(String spaceKey, String username)
@Deprecated public List<String> getPermissionsForUser(Space space, User user)
@Deprecated public void grantPermission(SpacePermission permission, Space space, Entity entity)
rpc.admin.permissions.
PermissionsRpc.addSpaceUserPermissions(java.lang.String, java.lang.String, com.atlassian.confluence.it.SpacePermission...)
or PermissionsRpc.addSpaceGroupPermissions(java.lang.String, java.lang.String, com.atlassian.confluence.it.SpacePermission...)
or PermissionsRpc.addSpaceAnonymousPermissions(java.lang.String, com.atlassian.confluence.it.SpacePermission...)
instead.@Deprecated public void grantPermission(SpacePermission permission, String spaceKey, Entity entity)
rpc.admin.permissions.
PermissionsRpc.addSpaceUserPermissions(java.lang.String, java.lang.String, com.atlassian.confluence.it.SpacePermission...)
or PermissionsRpc.addSpaceGroupPermissions(java.lang.String, java.lang.String, com.atlassian.confluence.it.SpacePermission...)
or PermissionsRpc.addSpaceAnonymousPermissions(java.lang.String, com.atlassian.confluence.it.SpacePermission...)
instead.@Deprecated public void grantPermissions(Space space, Entity entity, SpacePermission... permissions)
rpc.admin.permissions.
PermissionsRpc.addSpaceUserPermissions(java.lang.String, java.lang.String, com.atlassian.confluence.it.SpacePermission...)
or PermissionsRpc.addSpaceGroupPermissions(java.lang.String, java.lang.String, com.atlassian.confluence.it.SpacePermission...)
or PermissionsRpc.addSpaceAnonymousPermissions(java.lang.String, com.atlassian.confluence.it.SpacePermission...)
instead.@Deprecated public void grantAllPermissionsExceptAdmin(Entity entity, Space space)
rpc.admin.permissions.
PermissionsRpc.addAllSpaceUserPermissionsExceptAdmin(java.lang.String, java.lang.String)
or PermissionsRpc.addAllSpaceGroupPermissionsExceptAdmin(java.lang.String, java.lang.String)
instead.@Deprecated public void grantAllPermissions(Entity entity, Space space)
rpc.admin.permissions.
PermissionsRpc.addSpaceUserPermissions(java.lang.String, java.lang.String, com.atlassian.confluence.it.SpacePermission...)
or PermissionsRpc.addSpaceGroupPermissions(java.lang.String, java.lang.String, com.atlassian.confluence.it.SpacePermission...)
or PermissionsRpc.addSpaceAnonymousPermissions(java.lang.String, com.atlassian.confluence.it.SpacePermission...)
instead.public void grantContentPermission(ContentPermission contentPermission, ContentEntity contentEntity)
public void grantContentPermission(ContentEntity contentEntity, Entity entity, ContentPermissionType permissionType)
public void grantContentPermissions(ContentEntity contentEntity, List<? extends Entity> entities, ContentPermissionType permissionType)
public void revokeContentPermission(ContentPermission contentPermission, ContentEntity contentEntity)
@Deprecated public void grantAnonymousPermission(SpacePermission permission, Space space)
rpc.admin.permissions.
PermissionsRpc.addSpaceAnonymousPermissions(java.lang.String, com.atlassian.confluence.it.SpacePermission...)
instead.@Deprecated public void revokePermission(SpacePermission permission, Space space, Entity entity)
rpc.admin.permissions.
PermissionsRpc.removeSpaceUserPermissions(java.lang.String, java.lang.String, com.atlassian.confluence.it.SpacePermission...)
or PermissionsRpc.removeSpaceAnonymousPermissions(java.lang.String, com.atlassian.confluence.it.SpacePermission...)
or PermissionsRpc.removeSpaceGroupPermissions(java.lang.String, java.lang.String, com.atlassian.confluence.it.SpacePermission...)
instead.@Deprecated public void revokePermissions(Space space, Entity entity, SpacePermission... permissions)
rpc.admin.permissions.
PermissionsRpc.removeSpaceUserPermissions(java.lang.String, java.lang.String, com.atlassian.confluence.it.SpacePermission...)
or PermissionsRpc.removeSpaceAnonymousPermissions(java.lang.String, com.atlassian.confluence.it.SpacePermission...)
or PermissionsRpc.removeSpaceGroupPermissions(java.lang.String, java.lang.String, com.atlassian.confluence.it.SpacePermission...)
instead.@Deprecated public void revokeAnonymousPermission(SpacePermission permission, Space space)
rpc.admin.permissions.
PermissionsRpc.removeSpaceAnonymousPermissions(java.lang.String, com.atlassian.confluence.it.SpacePermission...)
instead.@Deprecated public void grantPermission(GlobalPermission permission, Entity entity)
rpc.admin.permissions.
PermissionsRpc.addGlobalUserPermissions(java.lang.String, com.atlassian.confluence.it.GlobalPermission...)
or PermissionsRpc.addGlobalGroupPermissions(java.lang.String, com.atlassian.confluence.it.GlobalPermission...)
instead.@Deprecated public void revokePermission(GlobalPermission permission, Entity entity)
rpc.admin.permissions.
PermissionsRpc.removeGlobalUserPermissions(java.lang.String, com.atlassian.confluence.it.GlobalPermission...)
or PermissionsRpc.removeGlobalGroupPermissions(java.lang.String, com.atlassian.confluence.it.GlobalPermission...)
instead.@Deprecated public List<GlobalPermission> getGlobalPermissions(Group group)
@Deprecated public boolean revokeAllPermissions(Group group)
rpc.admin.permissions.
PermissionsRpc.removeAllGlobalGroupPermissions(java.lang.String)
,
and PermissionsRpc.removeAllSpaceGroupPermissions(java.lang.String, java.lang.String)
for the appropriate spaces.@Deprecated public void grantAnonymousUsePermission()
rpc.admin.permissions.
PermissionsRpc.enableAnonymousUseConfluence()
instead.@Deprecated public void revokeAnonymousUsePermission()
rpc.admin.permissions.
PermissionsRpc.disableAnonymousUseConfluence()
instead.@Deprecated public boolean grantAnonymousViewUserProfilePermission()
rpc.admin.permissions.
PermissionsRpc.addGlobalAnonymousPermissions(com.atlassian.confluence.it.GlobalPermission...)
instead.@Deprecated public void revokeAnonymousViewUserProfilePermission()
rpc.admin.permissions.
PermissionsRpc.removeGlobalAnonymousPermissions(com.atlassian.confluence.it.GlobalPermission...)
instead.public void setContentTextProperty(long contentId, String key, String value)
ContentPropertyManager
.public void setContentPropertiesString(long contentId, String key, String value)
ContentProperties
.public void setContentPropertiesStringForSpace(String spaceKey, String key, String value)
ContentProperties
associated with the SpaceDescription
.public List<String> getContentPropertyKeys(long contentId)
ContentPropertyManager
.public String getContentProperty(long contentId, String key)
ContentPropertyManager
.public String getContentTextProperty(long contentId, String key)
ContentPropertyManager
.public String getContentPropertiesString(long contentId, String key)
ContentProperties
.public String getContentPropertiesStringForSpace(String spaceKey, String key)
ContentProperties
associated with the SpaceDescription
.public boolean flushIndexQueue()
public boolean flushIndexQueue(long time, TimeUnit unit)
public void assertThatMostRecentIndexEntriesHaveBeenProcessed(ContentEntity... entities)
public void assertThatMostRecentIndexEntriesHaveBeenProcessed(Iterable<? extends ContentEntity> entities)
public void clearIndex()
public boolean clearIndexQueue()
public boolean recoverMainIndex()
public void runJob(ScheduledJobKey job)
public long countJobRunDetails(ScheduledJobKey jobKey, com.atlassian.scheduler.status.RunOutcome runOutcome)
public void addJobs(ScheduledJobKey job, com.atlassian.scheduler.status.RunOutcome runOutcome, Integer days, Integer total)
job
- days
- @Deprecated public void runJob(QuartzJob job)
runJob(ScheduledJobKey)
.@Deprecated public void runJob(String jobSpec)
runJob(ScheduledJobKey)
.public String getLocalisedText(String messageKey)
If the key is not found, the key itself will be returned, as per
ConfluenceActionSupport.getText(String)
.
messageKey
- the message key to internationalise.FuncTestRpcHandler.getLocalisedText(String, String)
,
ConfluenceActionSupport.getText(String)
public int getMailQueueSize()
public void clearMailQueue()
public void clearQueue(String queueName)
public int getNumberOfIndexTasksInQueue()
public void flushEdgeIndexQueue()
public void setGlobalLanguage(String locale) throws org.apache.xmlrpc.XmlRpcException, IOException
org.apache.xmlrpc.XmlRpcException
IOException
public void setKeyboardShortcutPref(User user, boolean enabled)
public void setWatchOwnContent(User user, boolean enabled)
public void removeDrafts(User user)
public void removeTestData(Set<User> usersToKeep, Set<Group> groupsToKeep, Map<Group,HashSet<User>> userGroupMembershipsToKeep)
public void removeTestDataAfterExternalUserManagement()
public void removeAllSpaces()
public void changeBlogPostModificationDate(long blogId, Date modificationDate)
public void changePageModificationDate(long pageId, Date modificationDate)
public void changeAttachmentCreatedDate(Attachment attachment, Date createdDate)
public void pauseAllJobs()
public void pauseJobGroup(String jobGroupName)
public void pauseJob(ScheduledJobKey job)
@Deprecated public void pauseJob(QuartzJob job)
SchedulerRpc.pauseJob(ScheduledJobKey)
.@Deprecated public void pauseJob(String jobSpec)
SchedulerRpc.pauseJob(ScheduledJobKey)
.public void resumeJob(ScheduledJobKey job)
@Deprecated public void resumeJob(QuartzJob job)
SchedulerRpc.resumeJob(ScheduledJobKey)
.@Deprecated public void resumeJob(String jobSpec)
SchedulerRpc.resumeJob(ScheduledJobKey)
.public String getGlobalConfiguredTheme()
public void setGlobalTheme(BundledTheme theme)
public void setThemeForSpace(Space space, BundledTheme theme)
public void clearCustomHtml()
public void createJohnsonEvent(String message)
public void removeAllJohnsonEvents()
public void enableCaptcha(boolean enable)
public void enableCaptchaDebugMode(boolean enable)
public void setDraftSaveInterval(int seconds)
public boolean doesDraftExist(String contentId, String draftCreator, String draftType, String spaceKey)
public int countDrafts(User user)
public List<Hashtable<String,String>> search(String queryString, int maxMatches)
queryString
- the querymaxMatches
- the maximum number of matches to be returnedpublic List<Hashtable<String,String>> search(String queryString, Hashtable<String,String> params, int maxMatches)
public void importSpace(File zippedXmlBackup) throws IOException
IOException
public void importSpace(byte[] zippedXmlBackup) throws IOException
IOException
public Collection<ContentPermissionEntry> getPagePermissions(long pageId)
public String getSystemProperty(String name)
name
- the property to retrievepublic void setSystemProperty(String name, String value)
name
- the property to setvalue
- the value to setpublic void clearSystemProperty(String name)
name
- the property to setpublic PluginHelper getPluginHelper()
public DarkFeaturesHelper getDarkFeaturesHelper()
public String getBaseUrl()
public void createUserMacro(String name, boolean hasBody, String bodyType, String outputType, String template)
public void createUserMacro(String name, boolean hasBody, String bodyType, String outputType, String template, String title, String description, String category, String iconUrl, String documentationUrl, boolean hidden)
public void removeUserMacro(String name)
public long getPersonalInformationId(String username)
public void removePersonalInformation(User user)
user
- whose personalInformation will be removedpublic org.apache.log4j.Level setLogLevel(String logger, org.apache.log4j.Level level)
logger
- the logger to change the logging for, e.g. com.atlassian.confluence.core.ConfluenceActionSupportlevel
- the level to set the logger to, e.g. Level.ERROR
public boolean logMessage(RpcLogDestination destination, String message)
@Deprecated public void setEnableAnonymousAccess(boolean enable)
rpc.admin.permissions.
PermissionsRpc.enableAnonymousUseConfluence()
or PermissionsRpc.disableAnonymousUseConfluence()
instead.public void setEnableAnonymousRpc(boolean enable)
public void flushAllCaches()
public CacheStatistics getCacheStatistics(CacheKey key)
public Set<CacheStatistics.Capability> getCacheStatisticsCapabilities()
@Deprecated public Integer getCacheMaximumNumberOfElements(String cacheName)
CacheRpc.getCacheMaxEntries(String)
directly.@Deprecated public void setCacheMaximumNumberOfElements(String cacheName, int maxNumElements)
CacheRpc.setCacheMaxEntries(String, int)
directly.public void putStringMappingInCache(String cacheName, String entryKey, String value) throws org.apache.xmlrpc.XmlRpcException, IOException
org.apache.xmlrpc.XmlRpcException
IOException
public String getAnonymoizedCurrentClusterNodeIdentifier()
public boolean isClusteredInstance()
public List<Page> createPageHierarchy(Space space, int depth, String pageTitlePrefix)
public void addSmtpServer(String serverName, String from, String subjectPrefix, String hostname, int port)
public void addSmtpServer(String serverName, String from, String subjectPrefix, String hostname, int port, String fromName)
public void setSmtpServer(String serverName, String from, String subjectPrefix, String hostname, int port)
public void setSmtpServer(String serverName, String from, String subjectPrefix, String hostname, int port, String fromName)
public void removeMailServer(String serverName)
public void flushMailQueue()
public void registerEventListener(String eventClassName)
public void unregisterEventListener(String eventClassName)
public void waitForEventQueue()
public void setApplicationConfigProperty(String propertyKey, String propertyValue)
public Object getApplicationConfigProperty(String propertyKey)
public com.atlassian.fugue.Option<Object> tryGetApplicationConfigProperty(String propertyKey)
public void follow(User user)
user
- the user to follow.stopFollowing(com.atlassian.confluence.it.User)
public void stopFollowing(User user)
user
- the user to follow.follow(com.atlassian.confluence.it.User)
public long setUserStatus(String wikiStatus)
wikiStatus
- the new status of the user as wiki markup.public String getConfiguredBaseUrl()
public void enableWebSudo(boolean enabled)
public void setWebSudoTimeout(int timeout)
public void enableElevatedSecurityCheck(boolean enabled)
public void enablePublicSignUp(boolean enabled)
public void synchroniseUserDirectories()
public void setDirectoryPasswordEncoder(String directoryName, String encoder)
public boolean removeUserDirectory(long directoryId)
@Deprecated public void purgeFromTrash(Space space, long pageId)
ContentRpc.purge(ContentId)
directly.public Comment getComment(AbstractPageEntity pageEntity, long commentId)
public boolean isSpringComponentPresent(String componentName)
public boolean updateGlobalSetting(String name, boolean value)
public void saveDateFormat(String pattern)
public String getLoggedInUser()
public Iterable<String> createSpaces(int i)
i
- the number of spaces to createpublic void archiveSpace(Space space)
public void unarchiveSpace(Space space)
public boolean isDarkFeatureEnabled(String key)
public int getNumberOfActiveUsers()
public boolean isUnlimitedUserLicense()
public boolean setWelcomeMessage(String welcomeMessage)
public boolean resetWelcomeMessage()
@Deprecated public void enableAnonymousAccess()
rpc.admin.permissions.
PermissionsRpc.enableAnonymousUseConfluence()
instead.@Deprecated public void disableAnonymousAccess()
rpc.admin.permissions.
PermissionsRpc.disableAnonymousUseConfluence()
instead.public String getExportBuildNumber()
public String getOldestSpaceImportAllowed()
public String getPluginExportCompatibility(String pluginKey)
public boolean isPluginUpgradeTasksComplete()
public void resetDatabaseStatistics()
public String getDatabaseStatistics()
public void runGarbageCollection()
public void enableNewUserEmailNotifications()
public boolean isImportTaskRunning()
public void increaseHighValue()
Copyright © 2003–2020 Atlassian. All rights reserved.