public class WCMCommands extends Object
| Modifier and Type | Field and Description |
|---|---|
static String |
CMD_CLONE_LAUNCH |
static String |
CMD_COPY_LANGUAGE |
static String |
CMD_COPY_PAGE |
static String |
CMD_CREATE_CATALOG |
static String |
CMD_CREATE_LAUNCH |
static String |
CMD_CREATE_LIVECOPY |
static String |
CMD_CREATE_PAGE |
static String |
CMD_CREATE_SITE |
static String |
CMD_CREATE_VERSION |
static String |
CMD_DELETE_COMMENT |
static String |
CMD_DELETE_LAUNCH |
static String |
CMD_DELETE_PAGE |
static String |
CMD_EDIT_LAUNCH |
static String |
CMD_LOCK_PAGE |
static String |
CMD_MARK_COMMENT_AS_SPAM |
static String |
CMD_MODERATE_COMMENT |
static String |
CMD_MOVE_PAGE |
static String |
CMD_PROMOTE_LAUNCH |
static String |
CMD_RESTORE_TREE |
static String |
CMD_RESTORE_VERSION |
static String |
CMD_ROLLOUT |
static String |
CMD_ROLLOUT_SECTION |
static String |
CMD_UNLOCK_PAGE |
| Constructor and Description |
|---|
WCMCommands(org.apache.sling.testing.clients.SlingClient client) |
| Modifier and Type | Method and Description |
|---|---|
org.apache.sling.testing.clients.SlingHttpResponse |
cloneLaunch(String orgPath,
int... expectedStatus)
Clones an existing launch section
|
org.apache.sling.testing.clients.SlingHttpResponse |
copyLanguages(String sitePath,
List<org.apache.http.message.BasicNameValuePair> relPaths,
int... expectedStatus) |
org.apache.sling.testing.clients.SlingHttpResponse |
copyPage(String[] srcPaths,
String destName,
String destParentPath,
String before,
boolean shallow,
int... expectedStatus) |
org.apache.sling.testing.clients.SlingHttpResponse |
createCatalog(String source,
String dest,
String label,
String title,
int... expectedStatus)
Creates a catalog from a blueprint
|
org.apache.sling.testing.clients.SlingHttpResponse |
createLaunch(String title,
ArrayList<String> srcPathList,
Calendar liveDate,
ArrayList<Boolean> ignoreSubPagesList,
boolean isLiveCopy,
String template,
String[] sourceRolloutConfigs,
String[] promoteRolloutConfigs)
Creates a new launch copy.
|
org.apache.sling.testing.clients.SlingHttpResponse |
createLaunch(String title,
String srcPath,
Calendar liveDate,
boolean ignoreSubPages,
boolean isLiveCopy,
String template,
String[] sourceRolloutConfigs,
String[] promoteRolloutConfigs,
int... expectedStatus)
Creates a new launch copy.
|
org.apache.sling.testing.clients.SlingHttpResponse |
createLiveCopy(String label,
String title,
String destPath,
String srcPath,
boolean shallow,
String[] rolloutConfigs,
String[] missingPages,
boolean excludeSubPages,
int... expectedStatus)
Create liveCopy
|
org.apache.sling.testing.clients.SlingHttpResponse |
createPage(String pageLabel,
String pageTitle,
String parentPath,
String templatePath,
int... expectedStatus) |
org.apache.sling.testing.clients.SlingHttpResponse |
createSite(String label,
String title,
String destPath,
boolean isLiveCopy,
String[] languages,
String[] chapterPages,
String bluePrintPath,
String[] rolloutConfigs,
String siteOwner,
int... expectedStatus)
Creates an new site
|
org.apache.sling.testing.clients.SlingHttpResponse |
createVersion(String pagePath,
String comment,
String label,
int... expectedStatus) |
org.apache.sling.testing.clients.SlingHttpResponse |
deleteComment(String commentPath,
int... expectedStatus) |
org.apache.sling.testing.clients.SlingHttpResponse |
deleteLaunch(String path,
int... expectedStatus)
Deletes a launch section
|
org.apache.sling.testing.clients.SlingHttpResponse |
deletePage(String[] pagePaths,
boolean force,
boolean shallow,
int... expectedStatus) |
org.apache.sling.testing.clients.SlingHttpResponse |
editLaunch(String launchPath,
ArrayList<String> srcPathList,
ArrayList<Boolean> ignoreSubPagesList) |
org.apache.sling.testing.clients.SlingHttpResponse |
lockPage(String path,
int... expectedStatus)
Lock a page
|
org.apache.sling.testing.clients.SlingHttpResponse |
markCommentAsSpam(String commentPath,
boolean spam,
int... expectedStatus) |
org.apache.sling.testing.clients.SlingHttpResponse |
moderateComment(String commentPath,
boolean approve,
int... expectedStatus) |
org.apache.sling.testing.clients.SlingHttpResponse |
movePage(String[] srcPaths,
String destName,
String destParentPath,
String before,
boolean shallow,
boolean integrity,
String[] adjusts,
int... expectedStatus) |
org.apache.sling.testing.clients.SlingHttpResponse |
movePage(String[] srcPaths,
String destName,
String destParentPath,
String before,
boolean shallow,
boolean integrity,
String[] adjusts,
String[] publishes,
int... expectedStatus) |
org.apache.sling.testing.clients.SlingHttpResponse |
promoteLaunch(String path,
boolean promoteSubPages,
String target,
String workflowPackage,
int... expectedStatus)
Promotes a launch section
|
org.apache.sling.testing.clients.SlingHttpResponse |
restoreTree(String path,
Date date,
boolean preserveNVP,
int... expectedStatus) |
org.apache.sling.testing.clients.SlingHttpResponse |
restoreVersion(String[] versionIds,
String pagePath,
int... expectedStatus) |
org.apache.sling.testing.clients.SlingHttpResponse |
rollout(String[] sourcePaths,
String[] targetPaths,
String[] paragraphPaths,
String type,
boolean reset,
boolean useBackgroundJob,
int... expectedStatus)
type deep, delete, page (=deep)
|
org.apache.sling.testing.clients.SlingHttpResponse |
rolloutSection(String source,
String dest,
boolean force,
int... expectedStatus)
Rolls out a section
|
org.apache.sling.testing.clients.SlingHttpResponse |
unlockPage(String path,
int... expectedStatus)
Unlock a page
|
public static final String CMD_CREATE_PAGE
public static final String CMD_DELETE_PAGE
public static final String CMD_COPY_PAGE
public static final String CMD_MOVE_PAGE
public static final String CMD_COPY_LANGUAGE
public static final String CMD_CREATE_VERSION
public static final String CMD_RESTORE_VERSION
public static final String CMD_RESTORE_TREE
public static final String CMD_LOCK_PAGE
public static final String CMD_UNLOCK_PAGE
public static final String CMD_ROLLOUT
public static final String CMD_CREATE_SITE
public static final String CMD_CREATE_LIVECOPY
public static final String CMD_MODERATE_COMMENT
public static final String CMD_MARK_COMMENT_AS_SPAM
public static final String CMD_DELETE_COMMENT
public static final String CMD_CREATE_LAUNCH
public static final String CMD_DELETE_LAUNCH
public static final String CMD_EDIT_LAUNCH
public static final String CMD_CLONE_LAUNCH
public static final String CMD_PROMOTE_LAUNCH
public static final String CMD_CREATE_CATALOG
public static final String CMD_ROLLOUT_SECTION
public WCMCommands(org.apache.sling.testing.clients.SlingClient client)
public org.apache.sling.testing.clients.SlingHttpResponse createPage(String pageLabel, String pageTitle, String parentPath, String templatePath, int... expectedStatus) throws org.apache.sling.testing.clients.ClientException
org.apache.sling.testing.clients.ClientExceptionpublic org.apache.sling.testing.clients.SlingHttpResponse deletePage(String[] pagePaths, boolean force, boolean shallow, int... expectedStatus) throws org.apache.sling.testing.clients.ClientException
org.apache.sling.testing.clients.ClientExceptionpublic org.apache.sling.testing.clients.SlingHttpResponse copyPage(String[] srcPaths, String destName, String destParentPath, String before, boolean shallow, int... expectedStatus) throws org.apache.sling.testing.clients.ClientException
org.apache.sling.testing.clients.ClientExceptionpublic org.apache.sling.testing.clients.SlingHttpResponse movePage(String[] srcPaths, String destName, String destParentPath, String before, boolean shallow, boolean integrity, String[] adjusts, int... expectedStatus) throws org.apache.sling.testing.clients.ClientException
org.apache.sling.testing.clients.ClientExceptionpublic org.apache.sling.testing.clients.SlingHttpResponse movePage(String[] srcPaths, String destName, String destParentPath, String before, boolean shallow, boolean integrity, String[] adjusts, String[] publishes, int... expectedStatus) throws org.apache.sling.testing.clients.ClientException
org.apache.sling.testing.clients.ClientExceptionpublic org.apache.sling.testing.clients.SlingHttpResponse copyLanguages(String sitePath, List<org.apache.http.message.BasicNameValuePair> relPaths, int... expectedStatus) throws org.apache.sling.testing.clients.ClientException
org.apache.sling.testing.clients.ClientExceptionpublic org.apache.sling.testing.clients.SlingHttpResponse createVersion(String pagePath, String comment, String label, int... expectedStatus) throws org.apache.sling.testing.clients.ClientException
org.apache.sling.testing.clients.ClientExceptionpublic org.apache.sling.testing.clients.SlingHttpResponse restoreVersion(String[] versionIds, String pagePath, int... expectedStatus) throws org.apache.sling.testing.clients.ClientException
org.apache.sling.testing.clients.ClientExceptionpublic org.apache.sling.testing.clients.SlingHttpResponse restoreTree(String path, Date date, boolean preserveNVP, int... expectedStatus) throws org.apache.sling.testing.clients.ClientException
org.apache.sling.testing.clients.ClientExceptionpublic org.apache.sling.testing.clients.SlingHttpResponse lockPage(String path, int... expectedStatus) throws org.apache.sling.testing.clients.ClientException
path - Path of the page to lockexpectedStatus - list of expected http status codesorg.apache.sling.testing.clients.ClientException - if the request failspublic org.apache.sling.testing.clients.SlingHttpResponse unlockPage(String path, int... expectedStatus) throws org.apache.sling.testing.clients.ClientException
path - Path of the page to unlockexpectedStatus - list of expected http status codesorg.apache.sling.testing.clients.ClientException - if the request failspublic org.apache.sling.testing.clients.SlingHttpResponse createLiveCopy(String label, String title, String destPath, String srcPath, boolean shallow, String[] rolloutConfigs, String[] missingPages, boolean excludeSubPages, int... expectedStatus) throws org.apache.sling.testing.clients.ClientException
label - label of the liveCopytitle - title of the liveCopydestPath - destination path for the liveCopysrcPath - source path of the liveCopyshallow - if set to true subpages are excludedrolloutConfigs - rollout configurationmissingPages - pages which are not rolled out yetexcludeSubPages - if set to true subpages of missing pages are excludedexpectedStatus - list of expected http status codesorg.apache.sling.testing.clients.ClientException - if livecopy cannot be createdpublic org.apache.sling.testing.clients.SlingHttpResponse createSite(String label, String title, String destPath, boolean isLiveCopy, String[] languages, String[] chapterPages, String bluePrintPath, String[] rolloutConfigs, String siteOwner, int... expectedStatus) throws org.apache.sling.testing.clients.ClientException
label - Label of the new sitetitle - Title of the new sitedestPath - Location where the new site gets createdisLiveCopy - If the new site works as a liveCopylanguages - What languages to copychapterPages - What chapters to copybluePrintPath - Whats the blueprint usedrolloutConfigs - Whats the rollout configuration for the liveCopysiteOwner - Who is the site ownerexpectedStatus - list of expected http status codesorg.apache.sling.testing.clients.ClientException - if site cannot be createdpublic org.apache.sling.testing.clients.SlingHttpResponse moderateComment(String commentPath, boolean approve, int... expectedStatus) throws org.apache.sling.testing.clients.ClientException
org.apache.sling.testing.clients.ClientExceptionpublic org.apache.sling.testing.clients.SlingHttpResponse markCommentAsSpam(String commentPath, boolean spam, int... expectedStatus) throws org.apache.sling.testing.clients.ClientException
org.apache.sling.testing.clients.ClientExceptionpublic org.apache.sling.testing.clients.SlingHttpResponse deleteComment(String commentPath, int... expectedStatus) throws org.apache.sling.testing.clients.ClientException
org.apache.sling.testing.clients.ClientExceptionpublic org.apache.sling.testing.clients.SlingHttpResponse rollout(String[] sourcePaths, String[] targetPaths, String[] paragraphPaths, String type, boolean reset, boolean useBackgroundJob, int... expectedStatus) throws org.apache.sling.testing.clients.ClientException
sourcePaths - the blue print pathstargetPaths - the live copy pathsparagraphPaths - the paragraph pathstype - the type of rollout - deep / shallowreset - whether to reset or not the jobuseBackgroundJob - if true use a background job, otherwise do not use a
background jobexpectedStatus - list of expected http status codesorg.apache.sling.testing.clients.ClientException - if the request failspublic org.apache.sling.testing.clients.SlingHttpResponse createLaunch(String title, String srcPath, Calendar liveDate, boolean ignoreSubPages, boolean isLiveCopy, String template, String[] sourceRolloutConfigs, String[] promoteRolloutConfigs, int... expectedStatus) throws org.apache.sling.testing.clients.ClientException
title - Title of the new launch sectionsrcPath - the root page to be copied fromliveDate - the date the launch section should go liveignoreSubPages - if sub pages should be copied withisLiveCopy - if the launch section is connected to the source via live copytemplate - a template if the launch should be created with a different template, null otherwisesourceRolloutConfigs - Rollout configs used for the launch live copypromoteRolloutConfigs - Rollout configs used on launch promotionexpectedStatus - list of expected http status codesorg.apache.sling.testing.clients.ClientException - if anything goes wrongpublic org.apache.sling.testing.clients.SlingHttpResponse createLaunch(String title, ArrayList<String> srcPathList, Calendar liveDate, ArrayList<Boolean> ignoreSubPagesList, boolean isLiveCopy, String template, String[] sourceRolloutConfigs, String[] promoteRolloutConfigs) throws org.apache.sling.testing.clients.ClientException
title - Title of the new launch sectionsrcPathList - list of the root page to be copied fromliveDate - the date the launch section should go liveignoreSubPagesList - list specifying if sub pages should be copied withisLiveCopy - if the launch section is connected to the source via live copytemplate - a template if the launch should be created with a different template, null otherwisesourceRolloutConfigs - Rollout configs used for the launch live copypromoteRolloutConfigs - Rollout configs used on launch promotionorg.apache.sling.testing.clients.ClientException - if anything goes wrongpublic org.apache.sling.testing.clients.SlingHttpResponse editLaunch(String launchPath, ArrayList<String> srcPathList, ArrayList<Boolean> ignoreSubPagesList) throws org.apache.sling.testing.clients.ClientException
org.apache.sling.testing.clients.ClientExceptionpublic org.apache.sling.testing.clients.SlingHttpResponse deleteLaunch(String path, int... expectedStatus) throws org.apache.sling.testing.clients.ClientException
path - complete path to the launch sections root page handleexpectedStatus - list of expected http status codesorg.apache.sling.testing.clients.ClientException - If anything goes wrongpublic org.apache.sling.testing.clients.SlingHttpResponse cloneLaunch(String orgPath, int... expectedStatus) throws org.apache.sling.testing.clients.ClientException
orgPath - path to the root page of launch section to copyexpectedStatus - list of expected http status codesorg.apache.sling.testing.clients.ClientException - if anything goes wrongpublic org.apache.sling.testing.clients.SlingHttpResponse promoteLaunch(String path, boolean promoteSubPages, String target, String workflowPackage, int... expectedStatus) throws org.apache.sling.testing.clients.ClientException
path - path to the root page of the launch section to promotepromoteSubPages - true if sub pages should be promoted as welltarget - the path to a target launch or null to promote to productionworkflowPackage - path to the workflow package or nullexpectedStatus - list of expected http status codesorg.apache.sling.testing.clients.ClientException - If anything goes wrongpublic org.apache.sling.testing.clients.SlingHttpResponse createCatalog(String source, String dest, String label, String title, int... expectedStatus) throws org.apache.sling.testing.clients.ClientException
source - path to the blueprintdest - destination path to the cataloglabel - label of the catalogtitle - title of the catalogexpectedStatus - expected HTTP response status codesorg.apache.sling.testing.clients.ClientException - if the request could not be executedpublic org.apache.sling.testing.clients.SlingHttpResponse rolloutSection(String source, String dest, boolean force, int... expectedStatus) throws org.apache.sling.testing.clients.ClientException
source - path to blueprintdest - destination path to the catalogforce - whether the rollout should be forcedexpectedStatus - expected HTTP response status codeorg.apache.sling.testing.clients.ClientException - if the request could not be executedCopyright © 2018. All rights reserved.