public interface PageManagerDecorator extends PageManager
PageManager interface with additional methods for finding pages using queries, tags,
and template paths.| Modifier and Type | Method and Description |
|---|---|
PageDecorator |
copy(Page page,
String destination,
String beforeName,
boolean shallow,
boolean resolveConflict)
Copies the given page to the new destination and automatically saves the modifications
|
PageDecorator |
copy(Page page,
String destination,
String beforeName,
boolean shallow,
boolean resolveConflict,
boolean autoSave)
Copies the given page to the new destination
|
PageDecorator |
create(String parentPath,
String pageName,
String template,
String title)
Creates a new page at the given path using the provided template as content template.
|
PageDecorator |
create(String parentPath,
String pageName,
String template,
String title,
boolean autoSave)
Creates a new page at the given path using the provided template as content template.
|
List<PageDecorator> |
findPages(String rootPath,
Collection<String> tagIds,
boolean matchOne)
Find all descendant pages of the given path containing the specified tags.
|
List<PageDecorator> |
findPages(String rootPath,
Predicate<PageDecorator> predicate)
Find all descendant pages of the given path that match the predicate.
|
List<PageDecorator> |
findPages(String rootPath,
String templatePath)
Find all descendant pages of the given path matching the template path.
|
PageDecorator |
getContainingPage(Resource resource)
Returns the page that contains this resource.
|
PageDecorator |
getContainingPage(String path)
Returns the page that contains the resource at the given path.
|
PageDecorator |
getPage(Page page)
Decorate the given page.
|
PageDecorator |
getPage(String path)
Convenience method that returns the page at the given path.
|
PageDecorator |
move(Page page,
String destination,
String beforeName,
boolean shallow,
boolean resolveConflict,
String[] adjustRefs)
Moves the given page to the new destination.
|
PageDecorator |
restore(String path,
String revisionId)
Restore a revision of some page.
|
PageDecorator |
restoreTree(String path,
Calendar date)
Restore a tree.
|
List<PageDecorator> |
search(Query query)
Search for pages using a query.
|
List<PageDecorator> |
search(Query query,
int limit)
Search for pages using a query with the given result limit.
|
copy, copy, createRevision, createRevision, delete, delete, delete, delete, getBlueprints, getChildRevisions, getChildRevisions, getChildRevisions, getRevisions, getRevisions, getTemplate, getTemplates, move, order, order, order, order, restoreTree, touchPageDecorator copy(Page page, String destination, String beforeName, boolean shallow, boolean resolveConflict) throws WCMException
copy in interface PageManagerpage - the page to copydestination - the destinationbeforeName - the name of the next page. if null the page is ordered at the end.shallow - if true a non-recursive copy is performed.resolveConflict - if true resolves name conflict if destination already exists.WCMException - if an error during this operation occurs.PageDecorator copy(Page page, String destination, String beforeName, boolean shallow, boolean resolveConflict, boolean autoSave) throws WCMException
copy in interface PageManagerpage - the page to copydestination - the destinationbeforeName - the name of the next page. if null the page is ordered at the end.shallow - if true a non-recursive copy is performed.resolveConflict - if true resolves name conflict if destination already exists.autoSave - if true saves the modifications.WCMException - if an error during this operation occurs.PageDecorator create(String parentPath, String pageName, String template, String title) throws WCMException
create in interface PageManagerparentPath - the path of the parent pagepageName - the name of the new pagetemplate - the template for the new pagetitle - the title of the new pageWCMException - if an error during this operation occurs.PageDecorator create(String parentPath, String pageName, String template, String title, boolean autoSave) throws WCMException
create in interface PageManagerparentPath - the path of the parent pagepageName - the name of the new pagetemplate - the template for the new pagetitle - the title of the new pageautoSave - if true saves the modifications.WCMException - if an error during this operation occurs.List<PageDecorator> findPages(String rootPath, Collection<String> tagIds, boolean matchOne)
rootPath - root pathtagIds - set of tag IDsmatchOne - if true, 'OR' the specified tag IDs, 'AND' otherwiseList<PageDecorator> findPages(String rootPath, String templatePath)
rootPath - root pathtemplatePath - template pathList<PageDecorator> findPages(String rootPath, Predicate<PageDecorator> predicate)
rootPath - root pathpredicate - predicate to determine if a page should be included in the result listPageDecorator getContainingPage(Resource resource)
getContainingPage in interface PageManagerresource - resource to find the page fornull if not found.PageDecorator getContainingPage(String path)
getContainingPage in interface PageManagerpath - path to find the page fornull if not found.PageDecorator getPage(Page page)
page - non-null CQ pagePageDecorator getPage(String path)
null is returned.getPage in interface PageManagerpath - path of the pagenullPageDecorator move(Page page, String destination, String beforeName, boolean shallow, boolean resolveConflict, String[] adjustRefs) throws WCMException
move in interface PageManagerpage - the page to movedestination - the path of the new destinationbeforeName - the name of the next page. if null the page is ordered at the end.shallow - if true only the page content is movedresolveConflict - if true resolves name conflict if destination already exists.adjustRefs - list of paths to pages that refer to the moved one. those references will be adjusted.WCMException - if an error during this operation occurs.PageDecorator restore(String path, String revisionId) throws WCMException
restore in interface PageManagerpath - path to the page or to the parent pagerevisionId - revision id to restoreWCMException - if an error during this operation occurs.PageDecorator restoreTree(String path, Calendar date) throws WCMException
restoreTree in interface PageManagerpath - path to pagedate - calendar date to restore toWCMException - if an error during this operation occurs.List<PageDecorator> search(Query query)
query - JCR queryList<PageDecorator> search(Query query, int limit)
query - JCR querylimit - result limitCopyright © 2014 CITYTECH, Inc.. All rights reserved.