com.atlassian.confluence.test.rpc
Class FuncTestRpcHandlerImpl

java.lang.Object
  extended by com.atlassian.confluence.test.rpc.FuncTestRpcHandlerImpl
All Implemented Interfaces:
FuncTestRpcHandler

public class FuncTestRpcHandlerImpl
extends java.lang.Object
implements FuncTestRpcHandler


Field Summary
static java.lang.String ALACARTE_USERS
           
static int INDEXING_WAIT
           
static java.lang.String ONDEMAND_CONFLUENCE_ADMINISTRATORS
           
static java.lang.String ONDEMAND_SYSTEM_ADMINISTRATORS
           
static java.lang.String SOUT
           
 
Constructor Summary
FuncTestRpcHandlerImpl()
           
 
Method Summary
 boolean addExistingProfilePicture(java.lang.String token, java.lang.String userName, java.lang.String fileName)
          Attempts to add a existing profile picture to a user's profile.
 boolean addGroupAnyCase(java.lang.String token, java.lang.String groupname)
          Allows addition of a group without enforcing that the name be all lower case.
 int addLabelToLabelable(java.lang.String token, java.lang.String labelName, java.lang.String labelableId, java.lang.String labelableType)
          Adds a label to a labelable, because the public RPC API doesn't let you do it.
 boolean addMailServer(java.lang.String token, java.lang.String serverName, java.lang.String protocol, java.lang.String hostname, int port, java.lang.String username, java.lang.String password, java.lang.String toAddress)
          Add a POP server to poll for emails in a particular account.
 boolean addMailServer(java.lang.String token, java.lang.String name, java.lang.String from, java.lang.String subjectPrefix, java.lang.String hostname, int port)
           
 boolean addMailServer(java.lang.String token, java.lang.String name, java.lang.String from, java.lang.String subjectPrefix, java.lang.String hostname, int port, java.lang.String fromName)
           
 boolean addSmtpServer(java.lang.String token, java.lang.String name, java.lang.String from, java.lang.String subjectPrefix, java.lang.String hostname, int port)
          Add an SMTP mail server.
 boolean addSmtpServer(java.lang.String token, java.lang.String name, java.lang.String from, java.lang.String subjectPrefix, java.lang.String hostname, int port, java.lang.String fromName)
           
 boolean addUserAnyCase(java.lang.String token, java.lang.String username, java.lang.String email, java.lang.String fullname, java.lang.String password)
          Allows addition of a user without enforcing that the username be all lower case.
 boolean changeAttachmentCreatedDate(java.lang.String token, java.lang.String contentId, java.lang.String attachmentFileName, java.util.Date createdDate)
          Change the created date of an attachment
 boolean changeBlogPostModificationDate(java.lang.String token, java.lang.String blogId, java.util.Date modificationDate)
          Change the modification date of a blog post
 boolean changeCommentCreatedDate(java.lang.String token, java.lang.String commentId, java.util.Date createdDate)
          Change the created date of a comment
 java.lang.String changeLoggerLevel(java.lang.String token, java.lang.String loggerName, java.lang.String level)
           Change the level of the specified logger.
 boolean changePageCreatedDate(java.lang.String token, java.lang.String pageId, java.util.Date createdDate)
          Change the created date of a page
 boolean changePageModificationDate(java.lang.String token, java.lang.String pageId, java.util.Date modificationDate)
          Change the modification date of a page
 boolean changeSpaceCreatedDate(java.lang.String token, java.lang.String spaceKey, java.util.Date createdDate)
          Change the created date of a space
 boolean clearCustomHtml(java.lang.String token)
          Clears the global custom html.
 boolean clearEventListeners(java.lang.String token)
          Removes all temporary event listeners, regardless of their state.
 boolean clearIndex(java.lang.String token)
          Blows away the main Confluence search index.
 boolean clearQueue(java.lang.String token, java.lang.String queueName)
          Removes all items from the specified queue
 java.lang.Boolean clearSystemProperty(java.lang.String token, java.lang.String name)
          Unset a system property.
 java.lang.String convertMarkupToXhtml(java.lang.String token, java.lang.String wikiMarkup, java.lang.String pageId)
          Render a page as XHTML.
 java.lang.String convertXhtmlToMarkup(java.lang.String token, java.lang.String xhtml, java.lang.String pageId)
          Convert XHTML to WikiMarkup.
 int countDrafts(java.lang.String token, java.lang.String owner)
           
 java.util.Hashtable createDraft(java.lang.String token, java.util.Hashtable draftStruct)
          Creates a draft for the draft owner and draft type with the specified title and content.
 boolean createJohnsonEvent(java.lang.String token, java.lang.String message)
          Creates a Johnson event inside Confluence.
 java.util.Vector<java.util.Hashtable> createPagesFromPrototype(java.lang.String token, java.util.Hashtable pageStruct, int count)
          Creates a series of pages based on a prototype.
 java.util.Vector<java.lang.String> createSpaces(java.lang.String token, int count)
          Creates a bunch of spaces.
 java.lang.String createTemplate(java.lang.String token, java.lang.String templateName, java.lang.String content, java.lang.String spaceKey)
          Create a new template.
 java.lang.String createTemplateWithStorageFormat(java.lang.String token, java.lang.String templateName, java.lang.String storageFormat, java.lang.String spaceKey)
          Create a new template from storage format code.
 int createTestUsers(java.lang.String token, int count)
          Create test users with usernames "testuser0", "testuser1", etc.
 boolean createUserMacro(java.lang.String token, java.lang.String name, boolean hasBody, java.lang.String bodyType, java.lang.String outputType, java.lang.String template, java.lang.String title, java.lang.String description, java.lang.String category, java.lang.String iconUrl, java.lang.String documentationUrl, boolean hidden)
          Create a User Macro
 boolean disablePlugin(java.lang.String token, java.lang.String pluginKey)
          Disable a plugin.
 boolean disablePluginModule(java.lang.String token, java.lang.String pluginKey, java.lang.String moduleKey)
          Disable plugin module
 boolean disableSiteFeature(java.lang.String token, java.lang.String featureKey)
          Disables a given dark feature for the entire site.
 boolean disableUserFeature(java.lang.String token, java.lang.String featureKey)
          Disables a given dark feature for the logged in user.
 boolean disconnectGroup(java.lang.String token, java.lang.String groupName)
          Disconnect a group from Confluence.
 boolean disconnectUser(java.lang.String token, java.lang.String userName)
          Disconnect a user from Confluence.
 boolean doesDraftExist(java.lang.String token, java.lang.String contentId, java.lang.String owner, java.lang.String draftType, java.lang.String spaceKey)
          Determines if a draft of the specified type and belonging to the specified owner exists.
 boolean enableCaptcha(java.lang.String token, boolean enable)
          Sets the captcha mode
 boolean enableCaptchaDebugMode(java.lang.String token, boolean enable)
          Sets the captcha mode into debug mode.
 boolean enableDailyReportNotification(java.lang.String token, java.lang.String userName, boolean dailyReportEnabled)
          Sets the Daily Report email for a user to enabled or disabled.
 boolean enablePlugin(java.lang.String token, java.lang.String pluginKey)
          Enable a plugin.
 boolean enablePluginModule(java.lang.String token, java.lang.String pluginKey, java.lang.String moduleKey)
          Enable plugin module
 boolean enablePublicSignUp(java.lang.String token, boolean enabled)
          Sets the public sign up enabled status
 boolean enableSiteFeature(java.lang.String token, java.lang.String featureKey)
          Enables a given dark feature for the entire site.
 boolean enableUserFeature(java.lang.String token, java.lang.String featureKey)
          Enables a given dark feature for the logged in user.
 boolean enableWebSudo(java.lang.String token, boolean enabled)
          Sets the web sudo enabled status
 java.util.Vector<java.lang.String> finishLoggingRequests(java.lang.String token)
          Finish logging http request and return any requests made.
 boolean flushAllCaches(java.lang.String token)
          Flushes all the caches.
 boolean followUser(java.lang.String token, java.lang.String userName, boolean follow)
          Follows or stops following a user.
 java.util.Vector<java.util.Hashtable> getAliveThreads(java.lang.String token)
           
 java.util.Hashtable<java.lang.String,java.lang.Object> getAllContentForAllLabels(java.lang.String token, int offset, int maxResults, java.lang.String labelsString)
          Returns current and trashed CEOs having all of the labels supplied in the string.
 java.lang.Object getApplicationConfigProperty(java.lang.String token, java.lang.String propertyKey)
          Returns a property of the global ApplicationConfiguration instance.
 java.lang.Object getBandanaValue(java.lang.String token, java.lang.String space, java.lang.String key)
          Gets a value from Bandana
 java.lang.Integer getCacheMaximumNumberOfElements(java.lang.String token, java.lang.String cacheName)
          Returns the configured maximum number of elements in the given cache
 java.util.Hashtable getCacheStatistics(java.lang.String token, java.lang.String cacheName)
          Returns the cache statistics for a particular named cache.
 java.util.Vector<java.lang.String> getCacheStatisticsCapabilities(java.lang.String token)
          Returns the capabiltiies exposed by the cache statics service.
 java.lang.String getConfiguredThemeForSpace(java.lang.String token, java.lang.String spaceKey)
          Get the key of the configured theme for a space, whether or not that theme exists.
 java.util.Hashtable<java.lang.String,java.lang.Object> getContentForAllLabels(java.lang.String token, int offset, int maxResults, java.lang.String labelsString)
          Returns CEOs having all of the labels supplied in the string.
 java.util.Hashtable<java.lang.String,java.lang.Object> getContentInSpacesForAllLabels(java.lang.String token, int offset, int maxResults, java.lang.String spaceKeysString, java.lang.String labelsString)
          Returns CEOs in the given spaces having all of the labels supplied in the string.
 java.lang.String getContentProperty(java.lang.String token, java.lang.String entityId, java.lang.String key)
          Get the content property value for a content entity given its id and the property key
 java.util.Vector getContentPropertyKeys(java.lang.String token, java.lang.String entityId)
          Get the content property keys for a content entity given its id
 java.lang.String getDatabaseStatistics(java.lang.String token)
          Return database statistics.
 java.lang.String getExportBuildNumber(java.lang.String token)
          Returns the backward-compatibility of an export
 java.util.Hashtable<java.lang.String,java.lang.Object> getForLabels(java.lang.String token, java.lang.String labelableType, int offset, int maxResults, java.lang.String labelsString)
          Returns any kind of Labelable entities having all of the labels supplied in the string.
 java.lang.String getGlobalConfiguredTheme(java.lang.String token)
          Get the key of the configured global theme, whether or not that theme exists.
 java.lang.String[] getGlobalPermissionsForGroup(java.lang.String token, java.lang.String groupName)
          Gets the global permissions that the given group has.
 java.lang.String getIdOfPagePermission(java.lang.String token, java.lang.String contentId, java.lang.String permissionType, java.lang.String username)
           
 boolean getIgnoreBaseURLWarning(java.lang.String token)
          Whether the warning message for an un-advisable value for the Base URL is ignored or not.
 java.lang.String getLeastRecentTestAppenderLogMessage(java.lang.String token, java.lang.String className)
           
 java.lang.String getLocaleForUser(java.lang.String token, java.lang.String username)
          Gets the locale preference for the user.
 java.lang.String getLocalisedText(java.lang.String token, java.lang.String messageKey)
          Get the localised string for given the message key in the logged-in user's locale.
 java.lang.Iterable<java.lang.String> getNames(java.lang.Iterable<? extends com.atlassian.user.User> iterable)
           
 int getNumberOfActiveUsers(java.lang.String token)
          Returns the number of active users, i.e.
 int getNumberOfIndexTasksInQueue(java.lang.String token)
          Returns the size of the index queue.
 java.lang.String getOldestSpaceImportAllowed(java.lang.String token)
          Returns the backwards-compatibility of a space import
 java.lang.String getPersonalInformationId(java.lang.String token, java.lang.String username)
          Gets the personal information id for a given username
 java.lang.String getPluginExportCompatibility(java.lang.String token, java.lang.String pluginKey)
          Returns the plugin compatibility matrix for exports
 int getQueueSize(java.lang.String token, java.lang.String queueName)
          Returns the size of the task queue with the specified name.
 java.util.Hashtable<java.lang.String,java.lang.String> getSystemProperty(java.lang.String token, java.lang.String name)
          Retrieve the value of a system property.
 java.util.Vector getUsersForActivity(java.lang.String key)
          Call getUsersForActivity on the heartbeatManager bean
 int getVersionForPage(java.lang.String token, java.lang.String pageId)
          Get the version number for the page with pageId
 boolean isCurrentApplicationSet(java.lang.String token)
          Check whether or not the trustedApplicationManager has its currentApplication set.
 boolean isPluginModuleEnabled(java.lang.String token, java.lang.String pluginKey, java.lang.String moduleKey)
          Find out if a plugin module is enabled or not.
 boolean isPluginUpgradeTasksComplete(java.lang.String token)
          Returns true if the plugin dependent upgrade tasks
 boolean isSpringComponentPresent(java.lang.String token, java.lang.String name)
          Returns true if a Spring component with the given name exists in the application context.
 boolean isUnlimitedUserLicense(java.lang.String token)
           
 boolean logMessage(java.lang.String token, java.lang.String destination, java.lang.String message)
          Log a message to the server's console.
 boolean logTestMessageForClass(java.lang.String token, java.lang.String className, java.lang.String message, java.lang.String level)
           
 boolean massCreateAttachments(java.lang.String token, java.lang.String pageId, java.lang.String prefix, java.lang.String numAttachments)
          Create a whole series of attachments on a single page.
 boolean pauseAllJobs(java.lang.String token)
          Pauses the quartz scheduler.
 boolean pauseJob(java.lang.String token, java.lang.String jobSpecStr)
          Pauses the named job in the quartz scheduler.
 boolean pauseJobGroup(java.lang.String token, java.lang.String jobGroupName)
          Pauses the named job group in the quartz scheduler.
 boolean putStringMappingInCache(java.lang.String token, java.lang.String cacheName, java.lang.String key, java.lang.String value)
          Map a key to a value for a given cache.
 boolean registerEventListener(java.lang.String token, java.lang.String eventClassName)
          Registers a temporary event listener on the server to listen for the specified event.
 boolean registerTestAppenderForClass(java.lang.String token, java.lang.String className)
           
 boolean removeAllJohnsonEvents(java.lang.String token)
          Removes all Johnson events from Confluence
 boolean removeAllSpaces(java.lang.String token)
          Kill all the spaces and flush all the queues and caches.
 boolean removeAllTrustedApplications(java.lang.String token)
          Removes all trusted applications from the database.
 boolean removeAttachmentUncleanly(java.lang.String token, java.lang.String contentId, java.lang.String attachmentFileName)
          Removes an attachment without cleaning up associated attachment info
 boolean removeBandanaKey(java.lang.String token, java.lang.String space, java.lang.String key)
          Remove a key from Bandana
 boolean removeDrafts(java.lang.String token, java.lang.String username)
          Removes all drafts owned by the specified User.
 boolean removeGroupUncleanly(java.lang.String token, java.lang.String groupname)
          Remove a Group without removing the things that refer to that group.
 boolean removeMailServer(java.lang.String token, java.lang.String serverName)
          Remove the named mail server.
 boolean removePersonalInformation(java.lang.String token, java.lang.String username)
          PersonalInformation gets created automatically by the standard create user methods.
 boolean removeTestData(java.lang.String token, java.util.Vector<java.lang.String> usersToKeep, java.util.Vector<java.lang.String> groupsToKeep, java.util.Hashtable<java.lang.String,java.util.Vector<java.lang.String>> userGroupMembershipsToKeep)
          Big Kahuna remove method.
 boolean removeTestDataAfterExternalUserManagement(java.lang.String token)
          Remove the dependencies of all users and groups, except the default dependencies of the default groups, the listed extra groups, the current user, and the listed extra users.
 int removeTestUsers(java.lang.String token, int count)
          Removes test users with usernames "testuser0", "testuser1", etc.
 boolean removeUserDirectory(java.lang.String token, java.lang.String directoryId)
          Removes user directory
 boolean removeUserMacro(java.lang.String token, java.lang.String name)
          Remove a User Macro with the given name if it exists.
 boolean removeUserUncleanly(java.lang.String token, java.lang.String username)
          Remove a User without removing the things that refer to that user.
 boolean resetDatabaseStatistics(java.lang.String token)
          Reset database statistics.
 boolean resetWelcomeMessage(java.lang.String token)
           
 boolean restoreAbstractPage(java.lang.String token, java.lang.String abstractPageId)
          Restores an abstract page from the trash.
 boolean resumeAllJobs(java.lang.String token)
          Resume the quartz scheduler.
 boolean resumeJob(java.lang.String token, java.lang.String jobSpecStr)
          Resumes the named job in the quartz scheduler.
 boolean runGarbageCollection(java.lang.String token)
           
 boolean saveDateFormat(java.lang.String token, java.lang.String dateFormat)
           
 boolean saveDateTimeFormat(java.lang.String token, java.lang.String dateTimeFormat)
           
 void setAnonymousUserPermissionsService(AnonymousUserPermissionsService anonymousUserPermissionsService)
           
 void setAnyTypeDao(AnyTypeDao anyTypeDao)
           
 void setApplicationConfig(com.atlassian.config.ApplicationConfiguration applicationConfiguration)
           
 boolean setApplicationConfigProperty(java.lang.String token, java.lang.String propertyKey, java.lang.String propertyValue)
          Sets a property on the global ApplicationConfiguration instance.
 void setAttachmentManager(AttachmentManager attachmentManager)
           
 boolean setBandanaKey(java.lang.String token, java.lang.String space, java.lang.String key, java.lang.String value)
          Sets a key in Bandana
 boolean setBandanaKeyBoolean(java.lang.String token, java.lang.String space, java.lang.String key, boolean value)
          Sets a key in Bandana
 boolean setBandanaKeyInteger(java.lang.String token, java.lang.String space, java.lang.String key, int value)
          Sets a key in Bandana
 void setBandanaManager(com.atlassian.bandana.BandanaManager bandanaManager)
           
 boolean setBandanaStringList(java.lang.String token, java.lang.String space, java.lang.String key, java.util.Vector<java.lang.String> value)
          Sets a key in Bandana with a List of Strings as value
 boolean setBandanaStringSet(java.lang.String token, java.lang.String space, java.lang.String key, java.util.Vector<java.lang.String> value)
          Sets a key in Bandana with a Set of Strings as value
 void setBatchOperationManager(BatchOperationManager batchOperationManager)
           
 boolean setBooleanUserPreference(java.lang.String token, java.lang.String userName, java.lang.String preferenceKey, java.lang.String value)
          Sets a boolean user preference.
 void setCacheManager(com.atlassian.cache.CacheManager cacheManager)
           
 boolean setCacheMaximumNumberOfElements(java.lang.String token, java.lang.String cacheName, int maxNumElements)
          (Re)configures the maximum number of elements in the given cache
 void setCacheStatisticsManager(CacheStatisticsManager cacheStatisticsManager)
           
 void setCaptchaManager(CaptchaManager captchaManager)
           
 void setCommentManager(CommentManager commentManager)
           
 void setConfluenceUserDao(ConfluenceUserDao confluenceUserDao)
           
 void setConfluenceWysiwygConverter(ConfluenceWysiwygConverter wysiwygConverter)
           
 void setContentEntityManager(ContentEntityManager contentEntityManager)
           
 void setContentPermissionManager(ContentPermissionManager contentPermissionManager)
           
 void setContentPropertyManager(ContentPropertyManager contentPropertyManager)
           
 boolean setContentTextProperty(java.lang.String token, java.lang.String entityId, java.lang.String key, java.lang.String value)
          Sets a text content property for a content entity given its id
 void setCrowdDirectoryService(com.atlassian.crowd.embedded.api.CrowdDirectoryService crowdDirectoryService)
           
 void setCustomContentManager(CustomContentManager customContentManager)
           
 void setDarkFeaturesManager(DarkFeaturesManager darkFeaturesManager)
           
 void setDbStatCollector(DbStatCollector dbStatCollector)
           
 boolean setDirectoryPasswordEncoder(java.lang.String token, java.lang.String directoryName, java.lang.String encoder)
          Changes the password encoder for the given directory
 void setDraftManager(DraftManager draftManager)
           
 boolean setDraftSaveInterval(java.lang.String token, int seconds)
          Sets the given draft save interval.
 boolean setEnableAnonymousRpc(java.lang.String token, java.lang.String value)
          Toggle the setting to allow/deny anonymous RPC calls.
 void setEventDispatcher(com.atlassian.event.spi.EventDispatcher eventDispatcher)
           
 void setEventLatchManager(EventLatchManager eventLatchManager)
           
 void setEventManager(com.atlassian.event.EventManager eventManager)
           
 void setEventPublisher(com.atlassian.event.api.EventPublisher eventPublisher)
           
 void setFollowManager(FollowManager followManager)
           
 void setFormatConverter(FormatConverter formatConverter)
           
 boolean setGlobalLanguage(java.lang.String token, java.lang.String language)
          Changes to the default site language
 boolean setGlobalTheme(java.lang.String token, java.lang.String themeKey)
          Sets the global theme
 void setGroupManager(com.atlassian.user.GroupManager groupManager)
           
 void setHeartbeatManager(HeartbeatManager heartbeatManager)
           
 void setHibernateSessionManager(HibernateSessionManager sessionManager)
           
 boolean setIgnoreBaseURLWarning(java.lang.String token, boolean ignored)
          Affects whether the warning message for an un-advisable value for the Base URL is ignored or not.
 void setIndexManager(ConfluenceIndexManager indexManager)
           
 boolean setKeyboardShortcutPref(java.lang.String token, java.lang.String username, java.lang.String enabled)
          Enables/Disables keyboard shortcuts for the given uesr
 void setLabelManager(LabelManager labelManager)
           
 boolean setLocaleForUser(java.lang.String token, java.lang.String username, java.lang.String locale)
          Sets the locale preference for the user to the given named locale.
 void setLuceneConnection(com.atlassian.bonnie.ILuceneConnection luceneConnection)
           
 void setMailServerManager(com.atlassian.mail.server.MailServerManager mailServerManager)
           
 boolean setNetworkNotificationForUser(java.lang.String token, java.lang.String userName, boolean watchNetwork)
          Sets Network watch emails for a user to enabled or disabled.
 void setNotificationManager(NotificationManager notificationManager)
           
 void setPageManager(PageManager pageManager)
           
 void setPageTemplateManager(PageTemplateManager pageTemplateManager)
           
 void setPermissionManager(PermissionManager permissionManager)
           
 void setPersonalInformationManager(PersonalInformationManager personalInformationManager)
           
 void setPluginAccessor(com.atlassian.plugin.PluginAccessor pluginAccessor)
           
 void setPluginController(com.atlassian.plugin.PluginController pluginController)
           
 void setRequestLogger(RequestLogger requestLogger)
           
 void setScheduler(org.quartz.Scheduler scheduler)
           
 void setSettingsManager(SettingsManager settingsManager)
           
 boolean setSiteBlogNotificationForUser(java.lang.String token, java.lang.String userName, boolean globalBlogWatchForUser)
          Sets Site Blog watch emails for a user to enabled or disabled.
 boolean setSmtpServer(java.lang.String token, java.lang.String name, java.lang.String from, java.lang.String subjectPrefix, java.lang.String hostname, int port)
          Remove all existing SMTP servers and add the given server.
 boolean setSmtpServer(java.lang.String token, java.lang.String name, java.lang.String from, java.lang.String subjectPrefix, java.lang.String hostname, int port, java.lang.String fromName)
          Remove all existing SMTP servers and add the given server.
 void setSpaceManager(SpaceManager spaceManager)
           
 void setSpacePermissionDefaultsStoreFactory(SpacePermissionDefaultsStoreFactory spacePermissionDefaultsStoreFactory)
           
 void setSpacePermissionManager(SpacePermissionManager spacePermissionManager)
           
 boolean setStringUserPreference(java.lang.String token, java.lang.String userName, java.lang.String preferenceKey, java.lang.String value)
          Sets a string user preference.
 java.lang.Boolean setSystemProperty(java.lang.String token, java.lang.String name, java.lang.String value)
          Set a system property on the server to the supplied value.
 void setTaskManager(com.atlassian.core.task.MultiQueueTaskManager taskManager)
           
 boolean setThemeForSpace(java.lang.String token, java.lang.String spaceKey, java.lang.String themeKey)
          Sets the theme for the specified space
 void setThemeManager(ThemeManager themeManager)
           
 void setTransactionManager(org.springframework.transaction.PlatformTransactionManager transactionManager)
           
 void setTrustedApplicationsManager(TrustedApplicationsManager trustedApplicationsManager)
           
 void setUpgradeGate(UpgradeGate upgradeGate)
           
 void setUpgradeManager(UpgradeManager upgradeManager)
           
 void setUserAccessor(UserAccessor userAccessor)
           
 void setUserChecker(UserChecker userChecker)
           
 boolean setUserDetailProperty(java.lang.String token, java.lang.String username, java.lang.String propertyKey, java.lang.String propertyValue)
          Sets a single UserDetails property through the UserDetailsManager.
 boolean setUserDetails(java.lang.String token, java.lang.String username, java.lang.String fullName, java.lang.String email)
          Sets the fullname and email address of a user with a given username.
 void setUserDetailsManager(UserDetailsManager userDetailsManager)
           
 void setUserMacroLibrary(UserMacroLibrary userMacroLibrary)
           
 void setUserManager(com.atlassian.user.UserManager userManager)
           
 java.lang.String setUserStatus(java.lang.String token, java.lang.String wikiStatus)
          Set the current user's status.
 void setUserStatusManager(UserStatusManager userStatusManager)
           
 boolean setWatchOwnContentPref(java.lang.String token, java.lang.String username, java.lang.String enabled)
          Enables/Disables autowatching for the given uesr
 boolean setWatchSpace(java.lang.String token, java.lang.String username, java.lang.String spaceKey, java.lang.String contentTypeStr, java.lang.String enabled)
          Enables/Disables watching a space for the given user and content type.
 boolean setWebSudoTimeout(java.lang.String token, int timeout)
          Sets the web sudo timeout in minutes
 boolean setWelcomeMessage(java.lang.String token, java.lang.String welcomeMessage)
           
 void setWelcomeMessageService(WelcomeMessageService welcomeMessageService)
           
 void setXhtmlRpcHandler(ConfluenceXmlRpcHandler confluenceXmlRpcHandler)
           
 boolean shutdownQuartz(java.lang.String token)
          Shutdown the quartz scheduler to ensure single threadedness for testing
 boolean startActivity(java.lang.String key, java.lang.String user)
          Call startActivity on the heartbeatManager bean
 boolean startLoggingRequests(java.lang.String token)
          Start logging http request urls.
 java.util.Hashtable storeXhtmlPage(java.lang.String token, java.util.Hashtable pageStruct)
          The Confluence remote API store page performs wiki to XHTML conversion on the page content.
 boolean synchroniseUserDirectories(java.lang.String token)
          Synchronizes all remote user directories with the local database cache
 boolean triggerJob(java.lang.String token, java.lang.String jobSpecStr, boolean pauseBackgroundJobs)
          Triggers the named job in the quartz scheduler synchronously.
 boolean uninstallPlugin(java.lang.String token, java.lang.String pluginKey)
          Uninstall a plugin.
 boolean unregisterEventListener(java.lang.String token, java.lang.String eventClassName)
          Unregisters the temporary listener registered for the specified event.
 boolean unregisterTestAppenderForClass(java.lang.String token, java.lang.String className)
           
 java.util.Hashtable updateDraft(java.lang.String token, java.util.Hashtable draftStruct)
          Updates a draft located using the draft owner and draft type.
 boolean updateGlobalSettingBoolean(java.lang.String token, java.lang.String name, boolean value)
          Update a Settings boolean field.
 java.lang.String updateGlobalSettingString(java.lang.String token, java.lang.String name, java.lang.String value)
          Update a Settings String field.
 boolean waitForEvent(java.lang.String token, java.lang.String eventClassName, java.lang.String timeoutStr, java.lang.String timeUnitStr)
          Waits for an event to occur and returns when it has finished.
 boolean waitForEventQueue(java.lang.String token, java.lang.String timeoutStr, java.lang.String timeUnitStr)
          Waits for all events in queue to be processed.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

ONDEMAND_SYSTEM_ADMINISTRATORS

public static final java.lang.String ONDEMAND_SYSTEM_ADMINISTRATORS
See Also:
Constant Field Values

ONDEMAND_CONFLUENCE_ADMINISTRATORS

public static final java.lang.String ONDEMAND_CONFLUENCE_ADMINISTRATORS
See Also:
Constant Field Values

ALACARTE_USERS

public static final java.lang.String ALACARTE_USERS
See Also:
Constant Field Values

INDEXING_WAIT

public static final int INDEXING_WAIT
See Also:
Constant Field Values

SOUT

public static final java.lang.String SOUT
See Also:
Constant Field Values
Constructor Detail

FuncTestRpcHandlerImpl

public FuncTestRpcHandlerImpl()
Method Detail

logMessage

public boolean logMessage(java.lang.String token,
                          java.lang.String destination,
                          java.lang.String message)
Description copied from interface: FuncTestRpcHandler
Log a message to the server's console.

Only administrators can log messages.

The destination of the message has the following valid values:

Specified by:
logMessage in interface FuncTestRpcHandler
Parameters:
token - The token idenfitying the user.
destination - The destination of the message to be logged
message - The text message to be logged to the console
Returns:
boolean True if the message is logged (ie destination is a valid level)

changeLoggerLevel

public java.lang.String changeLoggerLevel(java.lang.String token,
                                          java.lang.String loggerName,
                                          java.lang.String level)
                                   throws RemoteException
Description copied from interface: FuncTestRpcHandler

Change the level of the specified logger.

The level parameter can be one of -


createTemplate

public java.lang.String createTemplate(java.lang.String token,
                                       java.lang.String templateName,
                                       java.lang.String content,
                                       java.lang.String spaceKey)
                                throws RemoteException,
                                       XhtmlException
Description copied from interface: FuncTestRpcHandler
Create a new template. If spaceKey is not defined, a global template will be created.

Specified by:
createTemplate in interface FuncTestRpcHandler
Returns:
template id
Throws:
RemoteException
XhtmlException

createTemplateWithStorageFormat

public java.lang.String createTemplateWithStorageFormat(java.lang.String token,
                                                        java.lang.String templateName,
                                                        java.lang.String storageFormat,
                                                        java.lang.String spaceKey)
                                                 throws RemoteException,
                                                        XhtmlException
Description copied from interface: FuncTestRpcHandler
Create a new template from storage format code. If spaceKey is not defined, a global template will be created.

Specified by:
createTemplateWithStorageFormat in interface FuncTestRpcHandler
Returns:
template id
Throws:
RemoteException
XhtmlException

removeAllSpaces

public boolean removeAllSpaces(java.lang.String token)
                        throws RemoteException
Description copied from interface: FuncTestRpcHandler
Kill all the spaces and flush all the queues and caches.

Specified by:
removeAllSpaces in interface FuncTestRpcHandler
Throws:
RemoteException

removeTestData

public boolean removeTestData(java.lang.String token,
                              java.util.Vector<java.lang.String> usersToKeep,
                              java.util.Vector<java.lang.String> groupsToKeep,
                              java.util.Hashtable<java.lang.String,java.util.Vector<java.lang.String>> userGroupMembershipsToKeep)
                       throws RemoteException
Description copied from interface: FuncTestRpcHandler
Big Kahuna remove method. Removes EVERYTHING that is meant to be removed on test setup, keeping only the users, groups and memberships specified. This includes removing global templates.

Specified by:
removeTestData in interface FuncTestRpcHandler
Parameters:
token - the token identifying the user.
usersToKeep - users like admin and sysadmin that should not be removed
groupsToKeep - groups like admins and users that should not be removed
userGroupMembershipsToKeep - a map where the keys are group names and the values are lists of usernames in the group
Throws:
NotPermittedException
RemoteException

removeTestDataAfterExternalUserManagement

public boolean removeTestDataAfterExternalUserManagement(java.lang.String token)
                                                  throws java.lang.Exception
Remove the dependencies of all users and groups, except the default dependencies of the default groups, the listed extra groups, the current user, and the listed extra users. This also deletes all mail servers, as it is significantly faster to batch up RPC invocations. Note that all memberships of kept users in kept groups will also be kept.

Specified by:
removeTestDataAfterExternalUserManagement in interface FuncTestRpcHandler
Throws:
java.lang.Exception

disconnectUser

public boolean disconnectUser(java.lang.String token,
                              java.lang.String userName)
                       throws NotPermittedException
Description copied from interface: FuncTestRpcHandler
Disconnect a user from Confluence. Removes all their permissions, group memberships, their profile information and their personal space.

Specified by:
disconnectUser in interface FuncTestRpcHandler
Throws:
NotPermittedException

disconnectGroup

public boolean disconnectGroup(java.lang.String token,
                               java.lang.String groupName)
                        throws NotPermittedException
Description copied from interface: FuncTestRpcHandler
Disconnect a group from Confluence. Removes all its permissions.

Specified by:
disconnectGroup in interface FuncTestRpcHandler
Throws:
NotPermittedException

getGlobalPermissionsForGroup

public java.lang.String[] getGlobalPermissionsForGroup(java.lang.String token,
                                                       java.lang.String groupName)
                                                throws RemoteException
Description copied from interface: FuncTestRpcHandler
Gets the global permissions that the given group has.

Specified by:
getGlobalPermissionsForGroup in interface FuncTestRpcHandler
Throws:
RemoteException

isCurrentApplicationSet

public boolean isCurrentApplicationSet(java.lang.String token)
                                throws NotPermittedException
Description copied from interface: FuncTestRpcHandler
Check whether or not the trustedApplicationManager has its currentApplication set.

Specified by:
isCurrentApplicationSet in interface FuncTestRpcHandler
Throws:
NotPermittedException

removeAllTrustedApplications

public boolean removeAllTrustedApplications(java.lang.String token)
Description copied from interface: FuncTestRpcHandler
Removes all trusted applications from the database.

Specified by:
removeAllTrustedApplications in interface FuncTestRpcHandler

massCreateAttachments

public boolean massCreateAttachments(java.lang.String token,
                                     java.lang.String pageId,
                                     java.lang.String prefix,
                                     java.lang.String numAttachments)
                              throws java.lang.Exception
Description copied from interface: FuncTestRpcHandler
Create a whole series of attachments on a single page.

Specified by:
massCreateAttachments in interface FuncTestRpcHandler
Throws:
java.lang.Exception

getGlobalConfiguredTheme

public java.lang.String getGlobalConfiguredTheme(java.lang.String token)
                                          throws java.lang.Exception
Description copied from interface: FuncTestRpcHandler
Get the key of the configured global theme, whether or not that theme exists.

Specified by:
getGlobalConfiguredTheme in interface FuncTestRpcHandler
Throws:
java.lang.Exception

getConfiguredThemeForSpace

public java.lang.String getConfiguredThemeForSpace(java.lang.String token,
                                                   java.lang.String spaceKey)
                                            throws java.lang.Exception
Description copied from interface: FuncTestRpcHandler
Get the key of the configured theme for a space, whether or not that theme exists.

Specified by:
getConfiguredThemeForSpace in interface FuncTestRpcHandler
Throws:
java.lang.Exception

setGlobalTheme

public boolean setGlobalTheme(java.lang.String token,
                              java.lang.String themeKey)
                       throws java.lang.Exception
Description copied from interface: FuncTestRpcHandler
Sets the global theme

Specified by:
setGlobalTheme in interface FuncTestRpcHandler
themeKey - - the complete theme key
Throws:
java.lang.Exception

setThemeForSpace

public boolean setThemeForSpace(java.lang.String token,
                                java.lang.String spaceKey,
                                java.lang.String themeKey)
                         throws java.lang.Exception
Description copied from interface: FuncTestRpcHandler
Sets the theme for the specified space

Specified by:
setThemeForSpace in interface FuncTestRpcHandler
spaceKey - - the key of the space to change
themeKey - - the complete theme key
Throws:
java.lang.Exception

clearCustomHtml

public boolean clearCustomHtml(java.lang.String token)
                        throws java.lang.Exception
Description copied from interface: FuncTestRpcHandler
Clears the global custom html.

Specified by:
clearCustomHtml in interface FuncTestRpcHandler
Returns:
true always.
Throws:
java.lang.Exception

uninstallPlugin

public boolean uninstallPlugin(java.lang.String token,
                               java.lang.String pluginKey)
                        throws NotPermittedException
Description copied from interface: FuncTestRpcHandler
Uninstall a plugin. (There's an install method in the standard rpc plugin)

Specified by:
uninstallPlugin in interface FuncTestRpcHandler
Returns:
true because a return type is required by XMLRPC
Throws:
NotPermittedException

disablePlugin

public boolean disablePlugin(java.lang.String token,
                             java.lang.String pluginKey)
                      throws NotPermittedException
Description copied from interface: FuncTestRpcHandler
Disable a plugin.

Specified by:
disablePlugin in interface FuncTestRpcHandler
Returns:
true because a return type is required by XMLRPC
Throws:
NotPermittedException

enablePlugin

public boolean enablePlugin(java.lang.String token,
                            java.lang.String pluginKey)
                     throws NotPermittedException
Description copied from interface: FuncTestRpcHandler
Enable a plugin.

Specified by:
enablePlugin in interface FuncTestRpcHandler
Returns:
true because a return type is required by XMLRPC
Throws:
NotPermittedException

enablePluginModule

public boolean enablePluginModule(java.lang.String token,
                                  java.lang.String pluginKey,
                                  java.lang.String moduleKey)
                           throws NotPermittedException
Description copied from interface: FuncTestRpcHandler
Enable plugin module

Specified by:
enablePluginModule in interface FuncTestRpcHandler
pluginKey - the key of the plugin
moduleKey - the key of the module
Returns:
true because a return type is required by XMLRPC
Throws:
NotPermittedException

disablePluginModule

public boolean disablePluginModule(java.lang.String token,
                                   java.lang.String pluginKey,
                                   java.lang.String moduleKey)
                            throws NotPermittedException
Description copied from interface: FuncTestRpcHandler
Disable plugin module

Specified by:
disablePluginModule in interface FuncTestRpcHandler
pluginKey - the key of the plugin
moduleKey - the key of the module
Returns:
true because a return type is required by XMLRPC
Throws:
NotPermittedException

isPluginModuleEnabled

public boolean isPluginModuleEnabled(java.lang.String token,
                                     java.lang.String pluginKey,
                                     java.lang.String moduleKey)
                              throws NotPermittedException
Description copied from interface: FuncTestRpcHandler
Find out if a plugin module is enabled or not. If the plugin exists and is enabled and the module exists and is enabled, then this method should return true, otherwise it should return false.

Specified by:
isPluginModuleEnabled in interface FuncTestRpcHandler
pluginKey - the key of the plugin
moduleKey - the key of the module excluding the plugin key
Returns:
true if the plugin module exists and is enabled, false otherwise
Throws:
NotPermittedException

isSpringComponentPresent

public boolean isSpringComponentPresent(java.lang.String token,
                                        java.lang.String name)
Description copied from interface: FuncTestRpcHandler
Returns true if a Spring component with the given name exists in the application context.

Specified by:
isSpringComponentPresent in interface FuncTestRpcHandler

isPluginUpgradeTasksComplete

public boolean isPluginUpgradeTasksComplete(java.lang.String token)
Description copied from interface: FuncTestRpcHandler
Returns true if the plugin dependent upgrade tasks

Specified by:
isPluginUpgradeTasksComplete in interface FuncTestRpcHandler

pauseAllJobs

public boolean pauseAllJobs(java.lang.String token)
                     throws java.lang.Exception
Description copied from interface: FuncTestRpcHandler
Pauses the quartz scheduler.

Specified by:
pauseAllJobs in interface FuncTestRpcHandler
Throws:
java.lang.Exception

resumeAllJobs

public boolean resumeAllJobs(java.lang.String token)
                      throws java.lang.Exception
Description copied from interface: FuncTestRpcHandler
Resume the quartz scheduler. Returns true on success and exception on error.

Specified by:
resumeAllJobs in interface FuncTestRpcHandler
Throws:
java.lang.Exception

pauseJobGroup

public boolean pauseJobGroup(java.lang.String token,
                             java.lang.String jobGroupName)
                      throws java.lang.Exception
Description copied from interface: FuncTestRpcHandler
Pauses the named job group in the quartz scheduler.

Specified by:
pauseJobGroup in interface FuncTestRpcHandler
Throws:
java.lang.Exception

pauseJob

public boolean pauseJob(java.lang.String token,
                        java.lang.String jobSpecStr)
                 throws java.lang.Exception
Description copied from interface: FuncTestRpcHandler
Pauses the named job in the quartz scheduler. Supports groupname:jobname for the jobSpec.

Specified by:
pauseJob in interface FuncTestRpcHandler
Throws:
java.lang.Exception

resumeJob

public boolean resumeJob(java.lang.String token,
                         java.lang.String jobSpecStr)
                  throws java.lang.Exception
Description copied from interface: FuncTestRpcHandler
Resumes the named job in the quartz scheduler. Supports groupname:jobname for the jobSpec.

Specified by:
resumeJob in interface FuncTestRpcHandler
Throws:
java.lang.Exception

triggerJob

public boolean triggerJob(java.lang.String token,
                          java.lang.String jobSpecStr,
                          boolean pauseBackgroundJobs)
                   throws java.lang.Exception
Description copied from interface: FuncTestRpcHandler
Triggers the named job in the quartz scheduler synchronously. Note that Quartz's triggerJob function is asynchronous, but we use a listener internally to provide synchronicity. Supports groupname:jobname for the jobSpec.

Specified by:
triggerJob in interface FuncTestRpcHandler
Throws:
java.lang.Exception

registerEventListener

public boolean registerEventListener(java.lang.String token,
                                     java.lang.String eventClassName)
                              throws java.lang.Exception
Description copied from interface: FuncTestRpcHandler
Registers a temporary event listener on the server to listen for the specified event. It is recommended that clients also unregister the event listener using FuncTestRpcHandler.unregisterEventListener(String, String) in a finally clause to ensure the temporary listener is cleaned up.

Once the listener is registered, clients can use FuncTestRpcHandler.waitForEvent(String, String, String, String) to block until the event is published.

Specified by:
registerEventListener in interface FuncTestRpcHandler
Throws:
java.lang.Exception

unregisterEventListener

public boolean unregisterEventListener(java.lang.String token,
                                       java.lang.String eventClassName)
                                throws java.lang.Exception
Description copied from interface: FuncTestRpcHandler
Unregisters the temporary listener registered for the specified event.

Specified by:
unregisterEventListener in interface FuncTestRpcHandler
Throws:
java.lang.Exception

clearEventListeners

public boolean clearEventListeners(java.lang.String token)
                            throws java.lang.Exception
Description copied from interface: FuncTestRpcHandler
Removes all temporary event listeners, regardless of their state.

Specified by:
clearEventListeners in interface FuncTestRpcHandler
Returns:
true because some result is required.
Throws:
java.lang.Exception

waitForEvent

public boolean waitForEvent(java.lang.String token,
                            java.lang.String eventClassName,
                            java.lang.String timeoutStr,
                            java.lang.String timeUnitStr)
                     throws java.lang.Exception
Description copied from interface: FuncTestRpcHandler
Waits for an event to occur and returns when it has finished.

Specified by:
waitForEvent in interface FuncTestRpcHandler
eventClassName - the fully qualified classname of the event to wait for.
timeoutStr - number of milliseconds to wait for the event before giving up completely.
timeUnitStr - See TimeUnit.name
Returns:
true if the event occurs within the timeout.
Throws:
java.lang.Exception

waitForEventQueue

public boolean waitForEventQueue(java.lang.String token,
                                 java.lang.String timeoutStr,
                                 java.lang.String timeUnitStr)
                          throws java.lang.Exception
Description copied from interface: FuncTestRpcHandler
Waits for all events in queue to be processed.

Specified by:
waitForEventQueue in interface FuncTestRpcHandler
Returns:
true if queue was exhausted, false on timeout or any error.
Throws:
java.lang.Exception

shutdownQuartz

public boolean shutdownQuartz(java.lang.String token)
                       throws java.lang.Exception
Description copied from interface: FuncTestRpcHandler
Shutdown the quartz scheduler to ensure single threadedness for testing

Specified by:
shutdownQuartz in interface FuncTestRpcHandler
Throws:
java.lang.Exception

removeBandanaKey

public boolean removeBandanaKey(java.lang.String token,
                                java.lang.String space,
                                java.lang.String key)
Description copied from interface: FuncTestRpcHandler
Remove a key from Bandana

Specified by:
removeBandanaKey in interface FuncTestRpcHandler

setBandanaStringSet

public boolean setBandanaStringSet(java.lang.String token,
                                   java.lang.String space,
                                   java.lang.String key,
                                   java.util.Vector<java.lang.String> value)
Description copied from interface: FuncTestRpcHandler
Sets a key in Bandana with a Set of Strings as value

Specified by:
setBandanaStringSet in interface FuncTestRpcHandler

setBandanaStringList

public boolean setBandanaStringList(java.lang.String token,
                                    java.lang.String space,
                                    java.lang.String key,
                                    java.util.Vector<java.lang.String> value)
Description copied from interface: FuncTestRpcHandler
Sets a key in Bandana with a List of Strings as value

Specified by:
setBandanaStringList in interface FuncTestRpcHandler

setBandanaKey

public boolean setBandanaKey(java.lang.String token,
                             java.lang.String space,
                             java.lang.String key,
                             java.lang.String value)
Description copied from interface: FuncTestRpcHandler
Sets a key in Bandana

Specified by:
setBandanaKey in interface FuncTestRpcHandler

setBandanaKeyBoolean

public boolean setBandanaKeyBoolean(java.lang.String token,
                                    java.lang.String space,
                                    java.lang.String key,
                                    boolean value)
Description copied from interface: FuncTestRpcHandler
Sets a key in Bandana

Specified by:
setBandanaKeyBoolean in interface FuncTestRpcHandler

setBandanaKeyInteger

public boolean setBandanaKeyInteger(java.lang.String token,
                                    java.lang.String space,
                                    java.lang.String key,
                                    int value)
Description copied from interface: FuncTestRpcHandler
Sets a key in Bandana

Specified by:
setBandanaKeyInteger in interface FuncTestRpcHandler

getBandanaValue

public java.lang.Object getBandanaValue(java.lang.String token,
                                        java.lang.String space,
                                        java.lang.String key)
Description copied from interface: FuncTestRpcHandler
Gets a value from Bandana

Specified by:
getBandanaValue in interface FuncTestRpcHandler

getContentPropertyKeys

public java.util.Vector getContentPropertyKeys(java.lang.String token,
                                               java.lang.String entityId)
Description copied from interface: FuncTestRpcHandler
Get the content property keys for a content entity given its id

Specified by:
getContentPropertyKeys in interface FuncTestRpcHandler

getContentProperty

public java.lang.String getContentProperty(java.lang.String token,
                                           java.lang.String entityId,
                                           java.lang.String key)
Description copied from interface: FuncTestRpcHandler
Get the content property value for a content entity given its id and the property key

Specified by:
getContentProperty in interface FuncTestRpcHandler

setContentTextProperty

public boolean setContentTextProperty(java.lang.String token,
                                      java.lang.String entityId,
                                      java.lang.String key,
                                      java.lang.String value)
Description copied from interface: FuncTestRpcHandler
Sets a text content property for a content entity given its id

Specified by:
setContentTextProperty in interface FuncTestRpcHandler

getPersonalInformationId

public java.lang.String getPersonalInformationId(java.lang.String token,
                                                 java.lang.String username)
Description copied from interface: FuncTestRpcHandler
Gets the personal information id for a given username

Specified by:
getPersonalInformationId in interface FuncTestRpcHandler

removePersonalInformation

public boolean removePersonalInformation(java.lang.String token,
                                         java.lang.String username)
                                  throws NotPermittedException
Description copied from interface: FuncTestRpcHandler
PersonalInformation gets created automatically by the standard create user methods. This method exists to allow testing that the PersonalInformation will get created appropriately when it doesn't exist (eg for LDAP users logging in).

Specified by:
removePersonalInformation in interface FuncTestRpcHandler
username - user whose personalInformation will be removed
Returns:
true because it has to return something
Throws:
NotPermittedException

getLocaleForUser

public java.lang.String getLocaleForUser(java.lang.String token,
                                         java.lang.String username)
Description copied from interface: FuncTestRpcHandler
Gets the locale preference for the user.

Specified by:
getLocaleForUser in interface FuncTestRpcHandler

setLocaleForUser

public boolean setLocaleForUser(java.lang.String token,
                                java.lang.String username,
                                java.lang.String locale)
                         throws RemoteException
Description copied from interface: FuncTestRpcHandler
Sets the locale preference for the user to the given named locale.

Specified by:
setLocaleForUser in interface FuncTestRpcHandler
Throws:
RemoteException

setGlobalLanguage

public boolean setGlobalLanguage(java.lang.String token,
                                 java.lang.String language)
                          throws RemoteException
Description copied from interface: FuncTestRpcHandler
Changes to the default site language

Specified by:
setGlobalLanguage in interface FuncTestRpcHandler
Throws:
RemoteException

setKeyboardShortcutPref

public boolean setKeyboardShortcutPref(java.lang.String token,
                                       java.lang.String username,
                                       java.lang.String enabled)
                                throws RemoteException
Description copied from interface: FuncTestRpcHandler
Enables/Disables keyboard shortcuts for the given uesr

Specified by:
setKeyboardShortcutPref in interface FuncTestRpcHandler
Throws:
RemoteException

setWatchOwnContentPref

public boolean setWatchOwnContentPref(java.lang.String token,
                                      java.lang.String username,
                                      java.lang.String enabled)
                               throws RemoteException
Description copied from interface: FuncTestRpcHandler
Enables/Disables autowatching for the given uesr

Specified by:
setWatchOwnContentPref in interface FuncTestRpcHandler
Throws:
RemoteException

setWatchSpace

public boolean setWatchSpace(java.lang.String token,
                             java.lang.String username,
                             java.lang.String spaceKey,
                             java.lang.String contentTypeStr,
                             java.lang.String enabled)
                      throws RemoteException
Description copied from interface: FuncTestRpcHandler
Enables/Disables watching a space for the given user and content type.

Specified by:
setWatchSpace in interface FuncTestRpcHandler
Throws:
RemoteException

setUserDetails

public boolean setUserDetails(java.lang.String token,
                              java.lang.String username,
                              java.lang.String fullName,
                              java.lang.String email)
                       throws NotPermittedException
Description copied from interface: FuncTestRpcHandler
Sets the fullname and email address of a user with a given username.

Specified by:
setUserDetails in interface FuncTestRpcHandler
Returns:
true because XMLRPC methods have to return something
Throws:
NotPermittedException

setUserDetailProperty

public boolean setUserDetailProperty(java.lang.String token,
                                     java.lang.String username,
                                     java.lang.String propertyKey,
                                     java.lang.String propertyValue)
Description copied from interface: FuncTestRpcHandler
Sets a single UserDetails property through the UserDetailsManager.

Specified by:
setUserDetailProperty in interface FuncTestRpcHandler
Returns:
true because XMLRPC methods have to return something

putStringMappingInCache

public boolean putStringMappingInCache(java.lang.String token,
                                       java.lang.String cacheName,
                                       java.lang.String key,
                                       java.lang.String value)
                                throws NotPermittedException
Description copied from interface: FuncTestRpcHandler
Map a key to a value for a given cache. Only accepts strings. This allows us to manipulate the number of entries in the cache. This method will create the named cache if it doesn't exist.

Specified by:
putStringMappingInCache in interface FuncTestRpcHandler
Returns:
true because void is not allowed.
Throws:
NotPermittedException

getCacheStatistics

public java.util.Hashtable getCacheStatistics(java.lang.String token,
                                              java.lang.String cacheName)
                                       throws NotPermittedException
Description copied from interface: FuncTestRpcHandler
Returns the cache statistics for a particular named cache.

Specified by:
getCacheStatistics in interface FuncTestRpcHandler
cacheName - the key of the cache, rather than the "niceName"
Returns:
A hashtable representing the cache statistics
Throws:
NotPermittedException

getCacheStatisticsCapabilities

public java.util.Vector<java.lang.String> getCacheStatisticsCapabilities(java.lang.String token)
                                                                  throws NotPermittedException
Description copied from interface: FuncTestRpcHandler
Returns the capabiltiies exposed by the cache statics service.

Specified by:
getCacheStatisticsCapabilities in interface FuncTestRpcHandler
Throws:
NotPermittedException

getCacheMaximumNumberOfElements

public java.lang.Integer getCacheMaximumNumberOfElements(java.lang.String token,
                                                         java.lang.String cacheName)
                                                  throws java.lang.Exception
Description copied from interface: FuncTestRpcHandler
Returns the configured maximum number of elements in the given cache

Specified by:
getCacheMaximumNumberOfElements in interface FuncTestRpcHandler
cacheName - the key of the cache, rather than the "niceName"
Throws:
java.lang.Exception

setCacheMaximumNumberOfElements

public boolean setCacheMaximumNumberOfElements(java.lang.String token,
                                               java.lang.String cacheName,
                                               int maxNumElements)
                                        throws java.lang.Exception
Description copied from interface: FuncTestRpcHandler
(Re)configures the maximum number of elements in the given cache

Specified by:
setCacheMaximumNumberOfElements in interface FuncTestRpcHandler
cacheName - the key of the cache, rather than the "niceName"
Throws:
java.lang.Exception

flushAllCaches

public boolean flushAllCaches(java.lang.String token)
                       throws NotPermittedException
Description copied from interface: FuncTestRpcHandler
Flushes all the caches.

Specified by:
flushAllCaches in interface FuncTestRpcHandler
Returns:
true because void isn't allowed.
Throws:
NotPermittedException

enableWebSudo

public boolean enableWebSudo(java.lang.String token,
                             boolean enabled)
                      throws java.lang.Exception
Description copied from interface: FuncTestRpcHandler
Sets the web sudo enabled status

Specified by:
enableWebSudo in interface FuncTestRpcHandler
Returns:
true because void isn't allowed.
Throws:
java.lang.Exception

setWebSudoTimeout

public boolean setWebSudoTimeout(java.lang.String token,
                                 int timeout)
                          throws java.lang.Exception
Description copied from interface: FuncTestRpcHandler
Sets the web sudo timeout in minutes

Specified by:
setWebSudoTimeout in interface FuncTestRpcHandler
Returns:
true because void isn't allowed.
Throws:
java.lang.Exception

enablePublicSignUp

public boolean enablePublicSignUp(java.lang.String token,
                                  boolean enabled)
                           throws java.lang.Exception
Description copied from interface: FuncTestRpcHandler
Sets the public sign up enabled status

Specified by:
enablePublicSignUp in interface FuncTestRpcHandler
Returns:
true because void isn't allowed.
Throws:
java.lang.Exception

startActivity

public boolean startActivity(java.lang.String key,
                             java.lang.String user)
                      throws java.lang.Exception
Description copied from interface: FuncTestRpcHandler
Call startActivity on the heartbeatManager bean

Specified by:
startActivity in interface FuncTestRpcHandler
Throws:
java.lang.Exception

getUsersForActivity

public java.util.Vector getUsersForActivity(java.lang.String key)
                                     throws java.lang.Exception
Description copied from interface: FuncTestRpcHandler
Call getUsersForActivity on the heartbeatManager bean

Specified by:
getUsersForActivity in interface FuncTestRpcHandler
Throws:
java.lang.Exception

removeUserUncleanly

public boolean removeUserUncleanly(java.lang.String token,
                                   java.lang.String username)
                            throws com.atlassian.user.EntityException
Description copied from interface: FuncTestRpcHandler
Remove a User without removing the things that refer to that user.

Specified by:
removeUserUncleanly in interface FuncTestRpcHandler
Throws:
com.atlassian.user.EntityException

removeGroupUncleanly

public boolean removeGroupUncleanly(java.lang.String token,
                                    java.lang.String groupname)
                             throws com.atlassian.user.EntityException
Description copied from interface: FuncTestRpcHandler
Remove a Group without removing the things that refer to that group.

Specified by:
removeGroupUncleanly in interface FuncTestRpcHandler
Throws:
com.atlassian.user.EntityException

doesDraftExist

public boolean doesDraftExist(java.lang.String token,
                              java.lang.String contentId,
                              java.lang.String owner,
                              java.lang.String draftType,
                              java.lang.String spaceKey)
Description copied from interface: FuncTestRpcHandler
Determines if a draft of the specified type and belonging to the specified owner exists.

Specified by:
doesDraftExist in interface FuncTestRpcHandler
Parameters:
token - rpc authentication token
contentId - id of the content this draft is for ('0' for new content)
owner - owner/author of the draft
draftType - type of content this draft is for
spaceKey - space key, to allow new drafts in multiple spaces
Returns:
true if a draft of the specified type and belonging to the specified owner exists, else false

countDrafts

public int countDrafts(java.lang.String token,
                       java.lang.String owner)
Specified by:
countDrafts in interface FuncTestRpcHandler

createDraft

public java.util.Hashtable createDraft(java.lang.String token,
                                       java.util.Hashtable draftStruct)
Description copied from interface: FuncTestRpcHandler
Creates a draft for the draft owner and draft type with the specified title and content. If the draft already exists the current draft is updated.

Specified by:
createDraft in interface FuncTestRpcHandler
Parameters:
token - rpc authentication token
draftStruct - the draft object to create Required: "owner" - the username of owner/author of the draft. Set to null for anonymous users. "draftType" - type of content the draft is for i.e. BlogPost.getType() or Page.getType(). "title" - title of the draft. "content" - content of the draft as a String in Confluence XML storage format. Optional: "pageId" - page that the draft is associated with. "spaceKey" - if no there is no page, the space that the draft is written in.
Returns:
the draft created returned in the same format as above, with the additional field id.

updateDraft

public java.util.Hashtable updateDraft(java.lang.String token,
                                       java.util.Hashtable draftStruct)
Description copied from interface: FuncTestRpcHandler
Updates a draft located using the draft owner and draft type. Draft is then updated with the specified title and content

Specified by:
updateDraft in interface FuncTestRpcHandler
Parameters:
token - rpc authentication token
draftStruct - the draft object to create see #createDraft(java.lang.String, java.util.Hashtable)
Returns:
the draft updated returns null if the draft does not exist

removeDrafts

public boolean removeDrafts(java.lang.String token,
                            java.lang.String username)
Description copied from interface: FuncTestRpcHandler
Removes all drafts owned by the specified User.

Specified by:
removeDrafts in interface FuncTestRpcHandler
Parameters:
token - rpc authentication token
username - user to remove drafts for
Returns:
true if this is successful, false if no user with this name.

setDraftSaveInterval

public boolean setDraftSaveInterval(java.lang.String token,
                                    int seconds)
Description copied from interface: FuncTestRpcHandler
Sets the given draft save interval.

Specified by:
setDraftSaveInterval in interface FuncTestRpcHandler
Parameters:
token - rpc authentication token
seconds - number of seconds for which the draft save interval should be
Returns:
true if this is successful, false if not set

clearQueue

public boolean clearQueue(java.lang.String token,
                          java.lang.String queueName)
Description copied from interface: FuncTestRpcHandler
Removes all items from the specified queue

Specified by:
clearQueue in interface FuncTestRpcHandler
Returns:
true if this is successful, false if no queue with this name exists

getQueueSize

public int getQueueSize(java.lang.String token,
                        java.lang.String queueName)
Description copied from interface: FuncTestRpcHandler
Returns the size of the task queue with the specified name.

Specified by:
getQueueSize in interface FuncTestRpcHandler
Returns:
the size of the task queue with the specified name.
Throws:
java.lang.IllegalArgumentException - if no queue could be found with the specified queueName.

getNumberOfIndexTasksInQueue

public int getNumberOfIndexTasksInQueue(java.lang.String token)
Description copied from interface: FuncTestRpcHandler
Returns the size of the index queue.

Specified by:
getNumberOfIndexTasksInQueue in interface FuncTestRpcHandler
Returns:

removeMailServer

public boolean removeMailServer(java.lang.String token,
                                java.lang.String serverName)
                         throws java.lang.Exception
Description copied from interface: FuncTestRpcHandler
Remove the named mail server.

Specified by:
removeMailServer in interface FuncTestRpcHandler
Parameters:
token - the rpc authentication token
serverName - the name of the server to be removed.
Returns:
true if the named server was removed (or there was no server by that name), otherwise false.
Throws:
java.lang.Exception

addUserAnyCase

public boolean addUserAnyCase(java.lang.String token,
                              java.lang.String username,
                              java.lang.String email,
                              java.lang.String fullname,
                              java.lang.String password)
                       throws RemoteException
Description copied from interface: FuncTestRpcHandler
Allows addition of a user without enforcing that the username be all lower case. This is for use in tests where you need mixed case user - useful for emulating an external provider such as LDAP.

Specified by:
addUserAnyCase in interface FuncTestRpcHandler
Throws:
NotPermittedException - if you do not have permissions to add the user.
RemoteException

getNames

public java.lang.Iterable<java.lang.String> getNames(java.lang.Iterable<? extends com.atlassian.user.User> iterable)

addGroupAnyCase

public boolean addGroupAnyCase(java.lang.String token,
                               java.lang.String groupname)
                        throws RemoteException
Description copied from interface: FuncTestRpcHandler
Allows addition of a group without enforcing that the name be all lower case. This is for use in tests where you need mixed case user - useful for emulating an external provider such as LDAP.

Specified by:
addGroupAnyCase in interface FuncTestRpcHandler
groupname - the name of the group to add
Returns:
true if successfully added, otherwise false
Throws:
RemoteException

changeSpaceCreatedDate

public boolean changeSpaceCreatedDate(java.lang.String token,
                                      java.lang.String spaceKey,
                                      java.util.Date createdDate)
                               throws RemoteException
Description copied from interface: FuncTestRpcHandler
Change the created date of a space

Specified by:
changeSpaceCreatedDate in interface FuncTestRpcHandler
spaceKey - the space key of the space to change the created date
Throws:
RemoteException

changeCommentCreatedDate

public boolean changeCommentCreatedDate(java.lang.String token,
                                        java.lang.String commentId,
                                        java.util.Date createdDate)
                                 throws RemoteException
Description copied from interface: FuncTestRpcHandler
Change the created date of a comment

Specified by:
changeCommentCreatedDate in interface FuncTestRpcHandler
Throws:
RemoteException

changePageCreatedDate

public boolean changePageCreatedDate(java.lang.String token,
                                     java.lang.String pageId,
                                     java.util.Date createdDate)
                              throws RemoteException
Description copied from interface: FuncTestRpcHandler
Change the created date of a page

Specified by:
changePageCreatedDate in interface FuncTestRpcHandler
pageId - the page id of the page to change the created date
Throws:
RemoteException

removeAttachmentUncleanly

public boolean removeAttachmentUncleanly(java.lang.String token,
                                         java.lang.String contentId,
                                         java.lang.String attachmentFileName)
                                  throws RemoteException
Description copied from interface: FuncTestRpcHandler
Removes an attachment without cleaning up associated attachment info

Specified by:
removeAttachmentUncleanly in interface FuncTestRpcHandler
Parameters:
token - the authentication
contentId - the content that the attachment is attached to
attachmentFileName - the attachment
Returns:
true
Throws:
RemoteException

changeAttachmentCreatedDate

public boolean changeAttachmentCreatedDate(java.lang.String token,
                                           java.lang.String contentId,
                                           java.lang.String attachmentFileName,
                                           java.util.Date createdDate)
                                    throws RemoteException
Description copied from interface: FuncTestRpcHandler
Change the created date of an attachment

Specified by:
changeAttachmentCreatedDate in interface FuncTestRpcHandler
contentId - the id of the page or blogpost the attachment is attached to
attachmentFileName - the attachment file name of the attachment to change the created date
Throws:
RemoteException

changeBlogPostModificationDate

public boolean changeBlogPostModificationDate(java.lang.String token,
                                              java.lang.String blogId,
                                              java.util.Date modificationDate)
                                       throws RemoteException
Description copied from interface: FuncTestRpcHandler
Change the modification date of a blog post

Specified by:
changeBlogPostModificationDate in interface FuncTestRpcHandler
blogId - the id of the blog to modify
modificationDate - the last modification date to be set.
Returns:
true if successful, otherwise false.
Throws:
RemoteException

changePageModificationDate

public boolean changePageModificationDate(java.lang.String token,
                                          java.lang.String pageId,
                                          java.util.Date modificationDate)
                                   throws RemoteException
Description copied from interface: FuncTestRpcHandler
Change the modification date of a page

Specified by:
changePageModificationDate in interface FuncTestRpcHandler
pageId - the page id of the page to change the modification date
modificationDate - the last modification date to be set.
Throws:
RemoteException

getVersionForPage

public int getVersionForPage(java.lang.String token,
                             java.lang.String pageId)
                      throws RemoteException
Description copied from interface: FuncTestRpcHandler
Get the version number for the page with pageId

Specified by:
getVersionForPage in interface FuncTestRpcHandler
Throws:
RemoteException

getLeastRecentTestAppenderLogMessage

public java.lang.String getLeastRecentTestAppenderLogMessage(java.lang.String token,
                                                             java.lang.String className)
Specified by:
getLeastRecentTestAppenderLogMessage in interface FuncTestRpcHandler

registerTestAppenderForClass

public boolean registerTestAppenderForClass(java.lang.String token,
                                            java.lang.String className)
Specified by:
registerTestAppenderForClass in interface FuncTestRpcHandler

unregisterTestAppenderForClass

public boolean unregisterTestAppenderForClass(java.lang.String token,
                                              java.lang.String className)
Specified by:
unregisterTestAppenderForClass in interface FuncTestRpcHandler

logTestMessageForClass

public boolean logTestMessageForClass(java.lang.String token,
                                      java.lang.String className,
                                      java.lang.String message,
                                      java.lang.String level)
Specified by:
logTestMessageForClass in interface FuncTestRpcHandler

followUser

public boolean followUser(java.lang.String token,
                          java.lang.String userName,
                          boolean follow)
                   throws RemoteException
Description copied from interface: FuncTestRpcHandler
Follows or stops following a user. Can be done by any user, not just admins.

Specified by:
followUser in interface FuncTestRpcHandler
follow - true to follow a user, false to stop following
Throws:
RemoteException

setUserStatus

public java.lang.String setUserStatus(java.lang.String token,
                                      java.lang.String wikiStatus)
                               throws RemoteException
Description copied from interface: FuncTestRpcHandler
Set the current user's status. Can be done by any user, not just admins.

Specified by:
setUserStatus in interface FuncTestRpcHandler
wikiStatus - the status string in wiki markup.
Returns:
the id of the new status, converted to a String
Throws:
RemoteException

synchroniseUserDirectories

public boolean synchroniseUserDirectories(java.lang.String token)
                                   throws java.lang.Exception
Description copied from interface: FuncTestRpcHandler
Synchronizes all remote user directories with the local database cache

Specified by:
synchroniseUserDirectories in interface FuncTestRpcHandler
Returns:
true
Throws:
java.lang.Exception

setDirectoryPasswordEncoder

public boolean setDirectoryPasswordEncoder(java.lang.String token,
                                           java.lang.String directoryName,
                                           java.lang.String encoder)
                                    throws java.lang.Exception
Description copied from interface: FuncTestRpcHandler
Changes the password encoder for the given directory

Specified by:
setDirectoryPasswordEncoder in interface FuncTestRpcHandler
Returns:
true
Throws:
java.lang.Exception

removeUserDirectory

public boolean removeUserDirectory(java.lang.String token,
                                   java.lang.String directoryId)
                            throws java.lang.Exception
Description copied from interface: FuncTestRpcHandler
Removes user directory

Specified by:
removeUserDirectory in interface FuncTestRpcHandler
directoryId - the id of the directory
Returns:
true if the directory existed and was removed
Throws:
java.lang.Exception

convertMarkupToXhtml

public java.lang.String convertMarkupToXhtml(java.lang.String token,
                                             java.lang.String wikiMarkup,
                                             java.lang.String pageId)
Description copied from interface: FuncTestRpcHandler
Render a page as XHTML.

Specified by:
convertMarkupToXhtml in interface FuncTestRpcHandler

convertXhtmlToMarkup

public java.lang.String convertXhtmlToMarkup(java.lang.String token,
                                             java.lang.String xhtml,
                                             java.lang.String pageId)
Description copied from interface: FuncTestRpcHandler
Convert XHTML to WikiMarkup.

Specified by:
convertXhtmlToMarkup in interface FuncTestRpcHandler

getLocalisedText

public java.lang.String getLocalisedText(java.lang.String token,
                                         java.lang.String messageKey)
Description copied from interface: FuncTestRpcHandler
Get the localised string for given the message key in the logged-in user's locale.

Specified by:
getLocalisedText in interface FuncTestRpcHandler
Parameters:
token - the rpc authentication token
messageKey - the i18n message key
Returns:
the localised version of the message key in the logged-in user's locale, or the message key itself if it does not have a corresponding value.

setIndexManager

public void setIndexManager(ConfluenceIndexManager indexManager)

setSpaceManager

public void setSpaceManager(SpaceManager spaceManager)

setPermissionManager

public void setPermissionManager(PermissionManager permissionManager)

setUserAccessor

public void setUserAccessor(UserAccessor userAccessor)

setConfluenceUserDao

public void setConfluenceUserDao(ConfluenceUserDao confluenceUserDao)

setAttachmentManager

public void setAttachmentManager(AttachmentManager attachmentManager)

setPageManager

public void setPageManager(PageManager pageManager)

setThemeManager

public void setThemeManager(ThemeManager themeManager)

setCaptchaManager

public void setCaptchaManager(CaptchaManager captchaManager)

setScheduler

public void setScheduler(org.quartz.Scheduler scheduler)

setBandanaManager

public void setBandanaManager(com.atlassian.bandana.BandanaManager bandanaManager)

setContentPropertyManager

public void setContentPropertyManager(ContentPropertyManager contentPropertyManager)

setContentEntityManager

public void setContentEntityManager(ContentEntityManager contentEntityManager)

setCustomContentManager

public void setCustomContentManager(CustomContentManager customContentManager)

setPersonalInformationManager

public void setPersonalInformationManager(PersonalInformationManager personalInformationManager)

setCacheManager

public void setCacheManager(com.atlassian.cache.CacheManager cacheManager)

setCacheStatisticsManager

public void setCacheStatisticsManager(CacheStatisticsManager cacheStatisticsManager)

setHeartbeatManager

public void setHeartbeatManager(HeartbeatManager heartbeatManager)

setSettingsManager

public void setSettingsManager(SettingsManager settingsManager)

setUserManager

public void setUserManager(com.atlassian.user.UserManager userManager)

setGroupManager

public void setGroupManager(com.atlassian.user.GroupManager groupManager)

setDraftManager

public void setDraftManager(DraftManager draftManager)

setHibernateSessionManager

public void setHibernateSessionManager(HibernateSessionManager sessionManager)

setTaskManager

public void setTaskManager(com.atlassian.core.task.MultiQueueTaskManager taskManager)

setMailServerManager

public void setMailServerManager(com.atlassian.mail.server.MailServerManager mailServerManager)

setEventManager

public void setEventManager(com.atlassian.event.EventManager eventManager)

setEventPublisher

public void setEventPublisher(com.atlassian.event.api.EventPublisher eventPublisher)

setEventDispatcher

public void setEventDispatcher(com.atlassian.event.spi.EventDispatcher eventDispatcher)

setUserStatusManager

public void setUserStatusManager(UserStatusManager userStatusManager)

setCrowdDirectoryService

public void setCrowdDirectoryService(com.atlassian.crowd.embedded.api.CrowdDirectoryService crowdDirectoryService)

setFollowManager

public void setFollowManager(FollowManager followManager)

setNotificationManager

public void setNotificationManager(NotificationManager notificationManager)

setSpacePermissionManager

public void setSpacePermissionManager(SpacePermissionManager spacePermissionManager)

setSpacePermissionDefaultsStoreFactory

public void setSpacePermissionDefaultsStoreFactory(SpacePermissionDefaultsStoreFactory spacePermissionDefaultsStoreFactory)

setUserDetailsManager

public void setUserDetailsManager(UserDetailsManager userDetailsManager)

setTransactionManager

public void setTransactionManager(org.springframework.transaction.PlatformTransactionManager transactionManager)

setTrustedApplicationsManager

public void setTrustedApplicationsManager(TrustedApplicationsManager trustedApplicationsManager)

setCommentManager

public void setCommentManager(CommentManager commentManager)

setConfluenceWysiwygConverter

public void setConfluenceWysiwygConverter(ConfluenceWysiwygConverter wysiwygConverter)

setContentPermissionManager

public void setContentPermissionManager(ContentPermissionManager contentPermissionManager)

setAnonymousUserPermissionsService

public void setAnonymousUserPermissionsService(AnonymousUserPermissionsService anonymousUserPermissionsService)

setUpgradeManager

public void setUpgradeManager(UpgradeManager upgradeManager)

setLabelManager

public void setLabelManager(LabelManager labelManager)

setRequestLogger

public void setRequestLogger(RequestLogger requestLogger)

setDbStatCollector

public void setDbStatCollector(DbStatCollector dbStatCollector)

saveDateFormat

public boolean saveDateFormat(java.lang.String token,
                              java.lang.String dateFormat)
Specified by:
saveDateFormat in interface FuncTestRpcHandler

saveDateTimeFormat

public boolean saveDateTimeFormat(java.lang.String token,
                                  java.lang.String dateTimeFormat)
Specified by:
saveDateTimeFormat in interface FuncTestRpcHandler

addMailServer

public boolean addMailServer(java.lang.String token,
                             java.lang.String name,
                             java.lang.String from,
                             java.lang.String subjectPrefix,
                             java.lang.String hostname,
                             int port)
Specified by:
addMailServer in interface FuncTestRpcHandler

addMailServer

public boolean addMailServer(java.lang.String token,
                             java.lang.String name,
                             java.lang.String from,
                             java.lang.String subjectPrefix,
                             java.lang.String hostname,
                             int port,
                             java.lang.String fromName)
Specified by:
addMailServer in interface FuncTestRpcHandler

addSmtpServer

public boolean addSmtpServer(java.lang.String token,
                             java.lang.String name,
                             java.lang.String from,
                             java.lang.String subjectPrefix,
                             java.lang.String hostname,
                             int port)
Description copied from interface: FuncTestRpcHandler
Add an SMTP mail server.

Specified by:
addSmtpServer in interface FuncTestRpcHandler

addSmtpServer

public boolean addSmtpServer(java.lang.String token,
                             java.lang.String name,
                             java.lang.String from,
                             java.lang.String subjectPrefix,
                             java.lang.String hostname,
                             int port,
                             java.lang.String fromName)
Specified by:
addSmtpServer in interface FuncTestRpcHandler

setSmtpServer

public boolean setSmtpServer(java.lang.String token,
                             java.lang.String name,
                             java.lang.String from,
                             java.lang.String subjectPrefix,
                             java.lang.String hostname,
                             int port)
Description copied from interface: FuncTestRpcHandler
Remove all existing SMTP servers and add the given server.

Specified by:
setSmtpServer in interface FuncTestRpcHandler

setSmtpServer

public boolean setSmtpServer(java.lang.String token,
                             java.lang.String name,
                             java.lang.String from,
                             java.lang.String subjectPrefix,
                             java.lang.String hostname,
                             int port,
                             java.lang.String fromName)
Description copied from interface: FuncTestRpcHandler
Remove all existing SMTP servers and add the given server.

Specified by:
setSmtpServer in interface FuncTestRpcHandler

addMailServer

public boolean addMailServer(java.lang.String token,
                             java.lang.String serverName,
                             java.lang.String protocol,
                             java.lang.String hostname,
                             int port,
                             java.lang.String username,
                             java.lang.String password,
                             java.lang.String toAddress)
Description copied from interface: FuncTestRpcHandler
Add a POP server to poll for emails in a particular account. The account's associated email address must also be passed.

Specified by:
addMailServer in interface FuncTestRpcHandler

removeAllJohnsonEvents

public boolean removeAllJohnsonEvents(java.lang.String token)
Description copied from interface: FuncTestRpcHandler
Removes all Johnson events from Confluence

Specified by:
removeAllJohnsonEvents in interface FuncTestRpcHandler

createJohnsonEvent

public boolean createJohnsonEvent(java.lang.String token,
                                  java.lang.String message)
Description copied from interface: FuncTestRpcHandler
Creates a Johnson event inside Confluence. This method is used to test the ConfluenceJohnsonFilter.

Specified by:
createJohnsonEvent in interface FuncTestRpcHandler
message - the description of the event to create

enableCaptcha

public boolean enableCaptcha(java.lang.String token,
                             boolean enable)
Description copied from interface: FuncTestRpcHandler
Sets the captcha mode

Specified by:
enableCaptcha in interface FuncTestRpcHandler

enableCaptchaDebugMode

public boolean enableCaptchaDebugMode(java.lang.String token,
                                      boolean enable)
Description copied from interface: FuncTestRpcHandler
Sets the captcha mode into debug mode. See CaptchaManager.setDebugMode(boolean).

Specified by:
enableCaptchaDebugMode in interface FuncTestRpcHandler

getSystemProperty

public java.util.Hashtable<java.lang.String,java.lang.String> getSystemProperty(java.lang.String token,
                                                                                java.lang.String name)
Description copied from interface: FuncTestRpcHandler
Retrieve the value of a system property. The property is returned as a map of the property key to its value, as XML-RPC doesn't support nulls and it's reasonably important to be able to tell if the property is set.

Specified by:
getSystemProperty in interface FuncTestRpcHandler
name - the name of the property
Returns:
a hash mapping the requested key to its value, if the property is set. Otherwise an empty map.

setSystemProperty

public java.lang.Boolean setSystemProperty(java.lang.String token,
                                           java.lang.String name,
                                           java.lang.String value)
Description copied from interface: FuncTestRpcHandler
Set a system property on the server to the supplied value.

Specified by:
setSystemProperty in interface FuncTestRpcHandler
name - the name of the property
value - the value of the property
Returns:
always true since XML RPC can't handle void

clearSystemProperty

public java.lang.Boolean clearSystemProperty(java.lang.String token,
                                             java.lang.String name)
Description copied from interface: FuncTestRpcHandler
Unset a system property.

Specified by:
clearSystemProperty in interface FuncTestRpcHandler
name - the name of the property
Returns:
always true since XML RPC can't handle void

clearIndex

public boolean clearIndex(java.lang.String token)
Description copied from interface: FuncTestRpcHandler
Blows away the main Confluence search index.

Specified by:
clearIndex in interface FuncTestRpcHandler

restoreAbstractPage

public boolean restoreAbstractPage(java.lang.String token,
                                   java.lang.String abstractPageId)
Description copied from interface: FuncTestRpcHandler
Restores an abstract page from the trash.

Specified by:
restoreAbstractPage in interface FuncTestRpcHandler

setLuceneConnection

public void setLuceneConnection(com.atlassian.bonnie.ILuceneConnection luceneConnection)

getIdOfPagePermission

public java.lang.String getIdOfPagePermission(java.lang.String token,
                                              java.lang.String contentId,
                                              java.lang.String permissionType,
                                              java.lang.String username)
Specified by:
getIdOfPagePermission in interface FuncTestRpcHandler
Returns:
the id of the identified content permission or 0 if there is no match found.

createTestUsers

public int createTestUsers(java.lang.String token,
                           int count)
Description copied from interface: FuncTestRpcHandler
Create test users with usernames "testuser0", "testuser1", etc. Each user's password is the same as their username.

Specified by:
createTestUsers in interface FuncTestRpcHandler
Returns:
the number of users created

removeTestUsers

public int removeTestUsers(java.lang.String token,
                           int count)
Description copied from interface: FuncTestRpcHandler
Removes test users with usernames "testuser0", "testuser1", etc. Logs a warning if a user cannot be removed.

Specified by:
removeTestUsers in interface FuncTestRpcHandler
Returns:
the number of users removed

createUserMacro

public boolean createUserMacro(java.lang.String token,
                               java.lang.String name,
                               boolean hasBody,
                               java.lang.String bodyType,
                               java.lang.String outputType,
                               java.lang.String template,
                               java.lang.String title,
                               java.lang.String description,
                               java.lang.String category,
                               java.lang.String iconUrl,
                               java.lang.String documentationUrl,
                               boolean hidden)
                        throws NotPermittedException
Description copied from interface: FuncTestRpcHandler
Create a User Macro

Specified by:
createUserMacro in interface FuncTestRpcHandler
bodyType - how the body should be treated. "raw", "escapehtml", or "rendered". May be null only if hasBody is false.
outputType - whether the macro is expected to return html or wiki markup. "html" or "wiki".
template - the velocity rendered by the macro
title - the title of the macro that appears in the Macro Browser
description - the description of the macro that appears in the Macro Browser
category - the category the macro should be listed under in the Macro Browser
iconUrl - the URL of the macro icon that appears in the Macro Browser
documentationUrl - the URL of the macro documentation
hidden - true if the Macro should not be searchable in the Macro Browser
Returns:
true all the time because XMLRPC methods need a non-void return type.
Throws:
NotPermittedException

removeUserMacro

public boolean removeUserMacro(java.lang.String token,
                               java.lang.String name)
                        throws NotPermittedException
Description copied from interface: FuncTestRpcHandler
Remove a User Macro with the given name if it exists.

Specified by:
removeUserMacro in interface FuncTestRpcHandler
Returns:
true all the time because XMLRPC methods need a non-void return type.
Throws:
NotPermittedException

setApplicationConfigProperty

public boolean setApplicationConfigProperty(java.lang.String token,
                                            java.lang.String propertyKey,
                                            java.lang.String propertyValue)
Description copied from interface: FuncTestRpcHandler
Sets a property on the global ApplicationConfiguration instance.

Specified by:
setApplicationConfigProperty in interface FuncTestRpcHandler
Returns:
the previous value of the property

storeXhtmlPage

public java.util.Hashtable storeXhtmlPage(java.lang.String token,
                                          java.util.Hashtable pageStruct)
                                   throws RemoteException
Description copied from interface: FuncTestRpcHandler
The Confluence remote API store page performs wiki to XHTML conversion on the page content. This version will store the supplied content exactly as it is. This is necessary for tests where the automatic conversion is not helpful, such as user macro testing.

Specified by:
storeXhtmlPage in interface FuncTestRpcHandler
Returns:
the created page
Throws:
RemoteException

getApplicationConfigProperty

public java.lang.Object getApplicationConfigProperty(java.lang.String token,
                                                     java.lang.String propertyKey)
Description copied from interface: FuncTestRpcHandler
Returns a property of the global ApplicationConfiguration instance.

Specified by:
getApplicationConfigProperty in interface FuncTestRpcHandler
Returns:
the property mapped to propertyKey

setBooleanUserPreference

public boolean setBooleanUserPreference(java.lang.String token,
                                        java.lang.String userName,
                                        java.lang.String preferenceKey,
                                        java.lang.String value)
                                 throws RemoteException
Description copied from interface: FuncTestRpcHandler
Sets a boolean user preference.

Specified by:
setBooleanUserPreference in interface FuncTestRpcHandler
userName - the user name to set the preference for
preferenceKey - the key of the preference to set
value - the string "true" or "false" to set as the preference
Throws:
RemoteException

setStringUserPreference

public boolean setStringUserPreference(java.lang.String token,
                                       java.lang.String userName,
                                       java.lang.String preferenceKey,
                                       java.lang.String value)
                                throws RemoteException
Description copied from interface: FuncTestRpcHandler
Sets a string user preference.

Specified by:
setStringUserPreference in interface FuncTestRpcHandler
userName - the user name to set the preference for
preferenceKey - the key of the preference to set
value - a string to set as the preference
Throws:
RemoteException

enableDailyReportNotification

public boolean enableDailyReportNotification(java.lang.String token,
                                             java.lang.String userName,
                                             boolean dailyReportEnabled)
Description copied from interface: FuncTestRpcHandler
Sets the Daily Report email for a user to enabled or disabled.

Specified by:
enableDailyReportNotification in interface FuncTestRpcHandler
userName - the user name to set the report state for
dailyReportEnabled - true if the daily report should be sent, false if not

setNetworkNotificationForUser

public boolean setNetworkNotificationForUser(java.lang.String token,
                                             java.lang.String userName,
                                             boolean watchNetwork)
Description copied from interface: FuncTestRpcHandler
Sets Network watch emails for a user to enabled or disabled.

Specified by:
setNetworkNotificationForUser in interface FuncTestRpcHandler
userName - the user name to set the watch state for
watchNetwork - true if the user should watch their network, false if not

setSiteBlogNotificationForUser

public boolean setSiteBlogNotificationForUser(java.lang.String token,
                                              java.lang.String userName,
                                              boolean globalBlogWatchForUser)
Description copied from interface: FuncTestRpcHandler
Sets Site Blog watch emails for a user to enabled or disabled.

Specified by:
setSiteBlogNotificationForUser in interface FuncTestRpcHandler
userName - the user name to set the watch state for
globalBlogWatchForUser - true if the user should watch all blogs on the site network, false if not

getIgnoreBaseURLWarning

public boolean getIgnoreBaseURLWarning(java.lang.String token)
Description copied from interface: FuncTestRpcHandler
Whether the warning message for an un-advisable value for the Base URL is ignored or not.

Specified by:
getIgnoreBaseURLWarning in interface FuncTestRpcHandler
Returns:
true if the warning message is ignored.

setIgnoreBaseURLWarning

public boolean setIgnoreBaseURLWarning(java.lang.String token,
                                       boolean ignored)
                                throws RemoteException
Description copied from interface: FuncTestRpcHandler
Affects whether the warning message for an un-advisable value for the Base URL is ignored or not. If ignored, any warning messages about the Base URL will not be displayed.

Specified by:
setIgnoreBaseURLWarning in interface FuncTestRpcHandler
ignored - set to true to ignore the warning.
Throws:
RemoteException

enableUserFeature

public boolean enableUserFeature(java.lang.String token,
                                 java.lang.String featureKey)
                          throws RemoteException
Description copied from interface: FuncTestRpcHandler
Enables a given dark feature for the logged in user.

Specified by:
enableUserFeature in interface FuncTestRpcHandler
featureKey - - the key of the feature to enable
Throws:
RemoteException

disableUserFeature

public boolean disableUserFeature(java.lang.String token,
                                  java.lang.String featureKey)
                           throws RemoteException
Description copied from interface: FuncTestRpcHandler
Disables a given dark feature for the logged in user.

Specified by:
disableUserFeature in interface FuncTestRpcHandler
featureKey - - the key of the feature to disable
Throws:
RemoteException

enableSiteFeature

public boolean enableSiteFeature(java.lang.String token,
                                 java.lang.String featureKey)
                          throws RemoteException
Description copied from interface: FuncTestRpcHandler
Enables a given dark feature for the entire site.

Specified by:
enableSiteFeature in interface FuncTestRpcHandler
featureKey - - the key of the feature to enable
Throws:
RemoteException

disableSiteFeature

public boolean disableSiteFeature(java.lang.String token,
                                  java.lang.String featureKey)
                           throws RemoteException
Description copied from interface: FuncTestRpcHandler
Disables a given dark feature for the entire site.

Specified by:
disableSiteFeature in interface FuncTestRpcHandler
featureKey - - the key of the feature to disable
Throws:
RemoteException

setWelcomeMessage

public boolean setWelcomeMessage(java.lang.String token,
                                 java.lang.String welcomeMessage)
Specified by:
setWelcomeMessage in interface FuncTestRpcHandler

resetWelcomeMessage

public boolean resetWelcomeMessage(java.lang.String token)
Specified by:
resetWelcomeMessage in interface FuncTestRpcHandler

getExportBuildNumber

public java.lang.String getExportBuildNumber(java.lang.String token)
Description copied from interface: FuncTestRpcHandler
Returns the backward-compatibility of an export

Specified by:
getExportBuildNumber in interface FuncTestRpcHandler
Parameters:
token - the authentication
Returns:
the build number

getOldestSpaceImportAllowed

public java.lang.String getOldestSpaceImportAllowed(java.lang.String token)
Description copied from interface: FuncTestRpcHandler
Returns the backwards-compatibility of a space import

Specified by:
getOldestSpaceImportAllowed in interface FuncTestRpcHandler
Parameters:
token - the authentication
Returns:
the oldest build number allowed

getPluginExportCompatibility

public java.lang.String getPluginExportCompatibility(java.lang.String token,
                                                     java.lang.String pluginKey)
Description copied from interface: FuncTestRpcHandler
Returns the plugin compatibility matrix for exports

Specified by:
getPluginExportCompatibility in interface FuncTestRpcHandler
Parameters:
token - the authentication
pluginKey - the plugin key
Returns:
a version range in the form "4.3..5.0", separated by 2 dots, or null

createPagesFromPrototype

public java.util.Vector<java.util.Hashtable> createPagesFromPrototype(java.lang.String token,
                                                                      java.util.Hashtable pageStruct,
                                                                      int count)
                                                               throws RemoteException
Description copied from interface: FuncTestRpcHandler
Creates a series of pages based on a prototype. Each page will have the same parent and content, and the title will be that of the template plus a space and an index. e.g. if the page title passed is "Hey Ho", the created pages will be "Hey Ho 1", "Hey Ho 2" and so on.

Specified by:
createPagesFromPrototype in interface FuncTestRpcHandler
pageStruct - a template page to create multiple pages from
count - the number of pages to create - pages created are 1-indexed
Throws:
RemoteException

updateGlobalSettingBoolean

public boolean updateGlobalSettingBoolean(java.lang.String token,
                                          java.lang.String name,
                                          boolean value)
                                   throws RemoteException
Description copied from interface: FuncTestRpcHandler
Update a Settings boolean field.

Specified by:
updateGlobalSettingBoolean in interface FuncTestRpcHandler
name - name of the field used to store the setting (see field names inside Settings.
Returns:
the old value
Throws:
RemoteException

updateGlobalSettingString

public java.lang.String updateGlobalSettingString(java.lang.String token,
                                                  java.lang.String name,
                                                  java.lang.String value)
                                           throws RemoteException
Description copied from interface: FuncTestRpcHandler
Update a Settings String field.

Specified by:
updateGlobalSettingString in interface FuncTestRpcHandler
name - name of the field used to store the setting (see field names inside Settings.
value - the String value the field should take
Returns:
the old value
Throws:
RemoteException

createSpaces

public java.util.Vector<java.lang.String> createSpaces(java.lang.String token,
                                                       int count)
                                                throws RemoteException
Description copied from interface: FuncTestRpcHandler
Creates a bunch of spaces.

Specified by:
createSpaces in interface FuncTestRpcHandler
count - the number to create
Returns:
the keys of the spaces created
Throws:
RemoteException - if you are not awesome enough to use this method

getNumberOfActiveUsers

public int getNumberOfActiveUsers(java.lang.String token)
                           throws RemoteException
Description copied from interface: FuncTestRpcHandler
Returns the number of active users, i.e. the number of users used for license purposes.

Specified by:
getNumberOfActiveUsers in interface FuncTestRpcHandler
Returns:
the number of active users
Throws:
RemoteException

isUnlimitedUserLicense

public boolean isUnlimitedUserLicense(java.lang.String token)
                               throws RemoteException
Specified by:
isUnlimitedUserLicense in interface FuncTestRpcHandler
Returns:
true if the current licence has no user limit, false otherwise
Throws:
RemoteException

setPluginController

public void setPluginController(com.atlassian.plugin.PluginController pluginController)

setPluginAccessor

public void setPluginAccessor(com.atlassian.plugin.PluginAccessor pluginAccessor)

setUserMacroLibrary

public void setUserMacroLibrary(UserMacroLibrary userMacroLibrary)

setEventLatchManager

public void setEventLatchManager(EventLatchManager eventLatchManager)

setApplicationConfig

public void setApplicationConfig(com.atlassian.config.ApplicationConfiguration applicationConfiguration)

setDarkFeaturesManager

public void setDarkFeaturesManager(DarkFeaturesManager darkFeaturesManager)

addExistingProfilePicture

public boolean addExistingProfilePicture(java.lang.String token,
                                         java.lang.String userName,
                                         java.lang.String fileName)
Description copied from interface: FuncTestRpcHandler
Attempts to add a existing profile picture to a user's profile.

Specified by:
addExistingProfilePicture in interface FuncTestRpcHandler
userName - the user name of the profile
fileName - file name of the picture
Returns:
true if the picture is successfully added

setXhtmlRpcHandler

public void setXhtmlRpcHandler(ConfluenceXmlRpcHandler confluenceXmlRpcHandler)

setBatchOperationManager

public void setBatchOperationManager(BatchOperationManager batchOperationManager)

setPageTemplateManager

public void setPageTemplateManager(PageTemplateManager pageTemplateManager)

setAnyTypeDao

public void setAnyTypeDao(AnyTypeDao anyTypeDao)

setUpgradeGate

public void setUpgradeGate(UpgradeGate upgradeGate)

setUserChecker

public void setUserChecker(UserChecker userChecker)

setWelcomeMessageService

public void setWelcomeMessageService(WelcomeMessageService welcomeMessageService)

setFormatConverter

public void setFormatConverter(FormatConverter formatConverter)

getAliveThreads

public java.util.Vector<java.util.Hashtable> getAliveThreads(java.lang.String token)
                                                      throws RemoteException
Specified by:
getAliveThreads in interface FuncTestRpcHandler
Throws:
RemoteException

setEnableAnonymousRpc

public boolean setEnableAnonymousRpc(java.lang.String token,
                                     java.lang.String value)
                              throws RemoteException
Description copied from interface: FuncTestRpcHandler
Toggle the setting to allow/deny anonymous RPC calls. You will also need to enable anonymous access at the permissions level using the Admin RPC interface.

Specified by:
setEnableAnonymousRpc in interface FuncTestRpcHandler
Throws:
RemoteException

getContentForAllLabels

public java.util.Hashtable<java.lang.String,java.lang.Object> getContentForAllLabels(java.lang.String token,
                                                                                     int offset,
                                                                                     int maxResults,
                                                                                     java.lang.String labelsString)
Description copied from interface: FuncTestRpcHandler
Returns CEOs having all of the labels supplied in the string. Labels are space-separated.

Specified by:
getContentForAllLabels in interface FuncTestRpcHandler

getContentInSpacesForAllLabels

public java.util.Hashtable<java.lang.String,java.lang.Object> getContentInSpacesForAllLabels(java.lang.String token,
                                                                                             int offset,
                                                                                             int maxResults,
                                                                                             java.lang.String spaceKeysString,
                                                                                             java.lang.String labelsString)
Description copied from interface: FuncTestRpcHandler
Returns CEOs in the given spaces having all of the labels supplied in the string. Labels and space keys are space-separated.

Specified by:
getContentInSpacesForAllLabels in interface FuncTestRpcHandler

getAllContentForAllLabels

public java.util.Hashtable<java.lang.String,java.lang.Object> getAllContentForAllLabels(java.lang.String token,
                                                                                        int offset,
                                                                                        int maxResults,
                                                                                        java.lang.String labelsString)
Description copied from interface: FuncTestRpcHandler
Returns current and trashed CEOs having all of the labels supplied in the string. Labels are space-separated.

Specified by:
getAllContentForAllLabels in interface FuncTestRpcHandler

getForLabels

public java.util.Hashtable<java.lang.String,java.lang.Object> getForLabels(java.lang.String token,
                                                                           java.lang.String labelableType,
                                                                           int offset,
                                                                           int maxResults,
                                                                           java.lang.String labelsString)
Description copied from interface: FuncTestRpcHandler
Returns any kind of Labelable entities having all of the labels supplied in the string. Labels are space-separated.

Specified by:
getForLabels in interface FuncTestRpcHandler

addLabelToLabelable

public int addLabelToLabelable(java.lang.String token,
                               java.lang.String labelName,
                               java.lang.String labelableId,
                               java.lang.String labelableType)
Description copied from interface: FuncTestRpcHandler
Adds a label to a labelable, because the public RPC API doesn't let you do it. Feel free to turn it all into REST to make the pain go away.

Specified by:
addLabelToLabelable in interface FuncTestRpcHandler

startLoggingRequests

public boolean startLoggingRequests(java.lang.String token)
Description copied from interface: FuncTestRpcHandler
Start logging http request urls.

Call FuncTestRpcHandler.finishLoggingRequests(String) to stop logging and to retrieve results.

Specified by:
startLoggingRequests in interface FuncTestRpcHandler
Returns:
true

finishLoggingRequests

public java.util.Vector<java.lang.String> finishLoggingRequests(java.lang.String token)
Description copied from interface: FuncTestRpcHandler
Finish logging http request and return any requests made.

Logging must have been previously started using FuncTestRpcHandler.startLoggingRequests(String).

Specified by:
finishLoggingRequests in interface FuncTestRpcHandler
Returns:
url of each request made

resetDatabaseStatistics

public boolean resetDatabaseStatistics(java.lang.String token)
Description copied from interface: FuncTestRpcHandler
Reset database statistics.

Call FuncTestRpcHandler.getDatabaseStatistics(String) to get results since the last reset.

Specified by:
resetDatabaseStatistics in interface FuncTestRpcHandler
Returns:
true

getDatabaseStatistics

public java.lang.String getDatabaseStatistics(java.lang.String token)
Description copied from interface: FuncTestRpcHandler
Return database statistics.

Statistics since the last call to FuncTestRpcHandler.resetDatabaseStatistics(String) are returned.

Specified by:
getDatabaseStatistics in interface FuncTestRpcHandler
Returns:
stabase statistics

runGarbageCollection

public boolean runGarbageCollection(java.lang.String token)
Specified by:
runGarbageCollection in interface FuncTestRpcHandler


Copyright © 2003-2014 Atlassian. All Rights Reserved.