Interface CmsCockpitService
-
- All Known Implementing Classes:
CmsCockpitServiceImpl
public interface CmsCockpitServiceThe Interface CmsCockpitService is responsible for managing approval status, cloning pages and retrieving components, sites and pages information.
-
-
Field Summary
Fields Modifier and Type Field Description static java.lang.StringABSTRACTPAGE_UID_PREFIXstatic java.lang.StringCMSITEM_UID
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description TypedObjectclonePageFirstLevel(TypedObject page, java.lang.String name)Creates a new page on base of an already existing page.java.lang.StringcreateRestrictionTooltip(TypedObject restriction)Retrieve the restriction description to be displayed in a tooltipjava.util.List<java.lang.String>getAllApprovalStatusCodes()Return all approval status codesjava.lang.StringgetApprovalStatusCode(TypedObject item)Find the approval status code for a given itemjava.lang.StringgetApprovalStatusName(java.lang.String code)Find an approval status name from a given codeTypedObjectgetDefaultPage(TypedObject page)Find the default page for a given pagejava.util.List<TypedObject>getPersonalizedPages(TypedObject page)Find all personalized pages for a given pagejava.util.List<TypedObject>getPersonalizedPages(TypedObject page, TypedObject excludePage)Find all personalized pages for a given page without a given excluded pagejava.util.List<AbstractPageModel>getRecentlyEditedPages(int count)Find all pages recently editedjava.util.Collection<CMSSiteModel>getSites()Find all sitesjava.util.Collection<CMSSiteModel>getWebsites()Find all sitesbooleanisPartOfTemplate(TypedObject cmsComponent)Determine whether a component is part of a templatebooleanisRestricted(TypedObject cmsComponent)Determine whether a component has any associated restrictions or notvoidsetApprovalStatus(TypedObject item, java.lang.String code)Update an approval status for a given code
-
-
-
Field Detail
-
CMSITEM_UID
static final java.lang.String CMSITEM_UID
- See Also:
- Constant Field Values
-
ABSTRACTPAGE_UID_PREFIX
static final java.lang.String ABSTRACTPAGE_UID_PREFIX
- See Also:
- Constant Field Values
-
-
Method Detail
-
getAllApprovalStatusCodes
java.util.List<java.lang.String> getAllApprovalStatusCodes()
Return all approval status codes- Returns:
- all approval status codes
-
getApprovalStatusName
java.lang.String getApprovalStatusName(java.lang.String code)
Find an approval status name from a given code- Parameters:
code- of approval status- Returns:
- the approval status name
-
setApprovalStatus
void setApprovalStatus(TypedObject item, java.lang.String code)
Update an approval status for a given code- Parameters:
item- requiring an approvalcode- of approval status to be updated
-
getApprovalStatusCode
java.lang.String getApprovalStatusCode(TypedObject item)
Find the approval status code for a given item- Parameters:
item- having an approval status- Returns:
- approval status code
-
isPartOfTemplate
boolean isPartOfTemplate(TypedObject cmsComponent)
Determine whether a component is part of a template- Parameters:
cmsComponent- to be determined if it is contained in a template- Returns:
trueif a component is part of a template;falseotherwise
-
isRestricted
boolean isRestricted(TypedObject cmsComponent)
Determine whether a component has any associated restrictions or not- Parameters:
cmsComponent- to be determined if it has any restrictions- Returns:
trueif a component has at least one restriction;falseotherwise
-
clonePageFirstLevel
TypedObject clonePageFirstLevel(TypedObject page, java.lang.String name)
Creates a new page on base of an already existing page. Also creates new content slots for this page, but components are the same as in the original page.- Parameters:
page- the page to use as templatename- the name for the new page, if null the name of the original page is used- Returns:
- the new page
-
createRestrictionTooltip
java.lang.String createRestrictionTooltip(TypedObject restriction)
Retrieve the restriction description to be displayed in a tooltip- Parameters:
restriction- containing the description to be displayed- Returns:
- the description of a given restriction
-
getWebsites
java.util.Collection<CMSSiteModel> getWebsites()
Find all sites- Returns:
- collection of sites, user type permission is checked before returning
-
getRecentlyEditedPages
java.util.List<AbstractPageModel> getRecentlyEditedPages(int count)
Find all pages recently edited- Parameters:
count- max number of pages to be returned- Returns:
- all pages recently edited
-
getPersonalizedPages
java.util.List<TypedObject> getPersonalizedPages(TypedObject page)
Find all personalized pages for a given page- Parameters:
page- which is personalized- Returns:
- all personalized pages for a given page
-
getPersonalizedPages
java.util.List<TypedObject> getPersonalizedPages(TypedObject page, TypedObject excludePage)
Find all personalized pages for a given page without a given excluded page- Parameters:
page- which is personalizedexcludePage- which is excluded- Returns:
- all personalized pages for a given page
-
getDefaultPage
TypedObject getDefaultPage(TypedObject page)
Find the default page for a given page- Parameters:
page- having a default page- Returns:
- a default page for a given page
-
getSites
java.util.Collection<CMSSiteModel> getSites()
Find all sites- Returns:
- collection of sites, user type permission is checked before returning
-
-