Interface I_CmsContainerpageService
- All Superinterfaces:
com.google.gwt.user.client.rpc.RemoteService
- All Known Implementing Classes:
CmsContainerpageService
The RPC service interface used by the container-page editor.
- Since:
- 8.0.0
-
Method Summary
Modifier and TypeMethodDescriptionvoid
addToFavoriteList
(CmsContainerPageRpcContext context, String clientId) Adds an element specified by it's id to the favorite list.void
addToRecentList
(CmsContainerPageRpcContext context, String clientId) Adds an element specified by it's id to the recent list.boolean
checkContainerpageOrElementsChanged
(CmsUUID structureId, CmsUUID detailContentId, String contentLocale) Check if a page or its elements have been changed.checkCreateNewElement
(CmsUUID pageStructureId, CmsUUID detailContentId, String clientId, String resourceType, CmsContainer container, String locale) To create a new element of the given type this method will check if a model resource needs to be selected, otherwise creates the new element.boolean
checkNewWidgetsAvailable
(CmsUUID structureId) Checks whether the Acacia widgets are available for all fields of the content.copyElement
(CmsUUID pageId, CmsUUID originalElementId, String locale) Creates a new element with a given model element and returns the copy'S structure id.createNewElement
(CmsUUID pageStructureId, CmsUUID detailContentId, String clientId, String resourceType, CmsUUID modelResourceStructureId, String locale) Creates a new element of the given type and returns the new element data containing structure id and site path.This method is used for serialization purposes only.getDeleteOptions
(String clientId, CmsUUID pageStructureId, String requestParams) Returns the delete options.getEditOptions
(String clientId, CmsUUID pageStructureId, String requestParams, boolean isListElement) Returns the edit options.This method is used for serialization purposes only.getElementsData
(CmsContainerPageRpcContext context, CmsUUID detailContentId, String reqParams, Collection<String> clientIds, Collection<CmsContainer> containers, boolean alwaysCopy, String dndSource, String locale) Returns container element data by client id.getElementSettingsConfig
(CmsContainerPageRpcContext context, String clientId, String containerId, Collection<CmsContainer> containers, String locale) Returns container element settings config data.getElementsLockedForPublishing
(Set<CmsUUID> idsToCheck) Checks which structure ids of a given set belong to resources locked for publishing by the current user, and then returns those.getElementWithSettings
(CmsContainerPageRpcContext context, CmsUUID detailContentId, String reqParams, String clientId, Map<String, String> settings, Collection<CmsContainer> containers, String locale) Gets the element data for an id and a map of settings.getFavoriteList
(CmsUUID pageStructureId, CmsUUID detailContentId, Collection<CmsContainer> containers, String locale) Returns the container element data of the favorite list.getGalleryDataForPage
(List<CmsContainer> containers, CmsUUID elementView, String uri, CmsUUID detailContentId, String locale, CmsTemplateContextInfo contextInfo) Returns the gallery configuration data according to the current page containers and the selected element view.getListElementCreationOptions
(CmsUUID structureId, String jsonListAddData) Loads the data for the list element creation dialog.getNewElementData
(CmsContainerPageRpcContext context, CmsUUID detailContentId, String reqParams, String resourceType, Collection<CmsContainer> containers, String locale) Returns new container element data for the given resource type name.getNewOptions
(String clientId, CmsUUID pageStructureId, String requestParams) Gets the edit handler options for creating a new element.getRecentList
(CmsUUID pageStructureId, CmsUUID detailContentId, Collection<CmsContainer> containers, String locale) Returns the container element data of the recent list.getRemovedElementStatus
(String id, CmsUUID containerpageId) Gets the status of a removed element.getReuseInfo
(CmsUUID pageId, CmsUUID detailId, CmsUUID elementId) Loads the reuse information for a container element.void
handleDelete
(String clientId, String deleteOption, CmsUUID pageStructureId, String requestParams) Handles the element deletion.int
Loads the index of the clipboard tab last selected by the user.prefetch()
Returns the initialization data.prepareForEdit
(String clientId, String editOption, CmsUUID pageStructureId, String requestParams) Prepares an element to be edited.replaceElement
(CmsContainerPageRpcContext context, CmsUUID detailContentId, String reqParams, String clientId, String replaceId, Collection<CmsContainer> containers, String locale) Returns the element data to replace a given content element with another while keeping it's settings.void
saveClipboardTab
(int tabIndex) Saves the index of the clipboard tab selected by the user.long
saveContainerpage
(CmsUUID pageStructureId, List<CmsContainer> containers) Saves the container-page.long
saveDetailContainers
(CmsUUID detailId, String detailContainerResource, List<CmsContainer> containers) Saves the detail containers.saveElementSettings
(CmsContainerPageRpcContext context, CmsUUID detailContentId, String reqParams, String clientId, Map<String, String> settings, List<CmsContainer> containers, String locale) Saves the settings for the given element to the container page and returns the updated element data.void
saveFavoriteList
(List<String> clientIds, String uri) Saves the favorite list.saveGroupContainer
(CmsContainerPageRpcContext context, CmsUUID detailContentId, String reqParams, CmsGroupContainer groupContainer, Collection<CmsContainer> containers, String locale) Saves a group-container element.saveInheritanceContainer
(CmsUUID pageStructureId, CmsUUID detailContentId, CmsInheritanceContainer inheritanceContainer, Collection<CmsContainer> containers, String locale) Saves an inheritance container.void
saveRecentList
(List<String> clientIds, String uri) Saves the recent list.void
setEditSmallElements
(boolean editSmallElements) Enables or disables editing for small elements on page load.void
setElementView
(CmsUUID elementView) Sets the element view.void
setLastPage
(CmsUUID pageId, CmsUUID detailId) Stores information about the container page last edited.
-
Method Details
-
checkContainerpageOrElementsChanged
boolean checkContainerpageOrElementsChanged(CmsUUID structureId, CmsUUID detailContentId, String contentLocale) throws CmsRpcException Check if a page or its elements have been changed.- Parameters:
structureId
- the structure id of the resourcedetailContentId
- the structure id of the detail content (may be null)contentLocale
- the content locale- Returns:
- true if there were changes in the page or its elements
- Throws:
CmsRpcException
- if the RPC call fails
-
checkNewWidgetsAvailable
Checks whether the Acacia widgets are available for all fields of the content.- Parameters:
structureId
- the structure id of the content- Returns:
- true if Acacia widgets are available for all fields
- Throws:
CmsRpcException
- if something goes wrong
-
copyElement
CmsUUID copyElement(CmsUUID pageId, CmsUUID originalElementId, String locale) throws CmsRpcException Creates a new element with a given model element and returns the copy'S structure id.- Parameters:
pageId
- the container page idoriginalElementId
- the model element idlocale
- the content locale- Returns:
- the structure id of the copy
- Throws:
CmsRpcException
- if something goes wrong
-
createNewElement
CmsContainerElement createNewElement(CmsUUID pageStructureId, CmsUUID detailContentId, String clientId, String resourceType, CmsUUID modelResourceStructureId, String locale) throws CmsRpcException Creates a new element of the given type and returns the new element data containing structure id and site path.- Parameters:
pageStructureId
- the container page structure iddetailContentId
- the structure id of the detail contentclientId
- the client id of the new element (this will be the structure id of the configured new resource)resourceType
- the resource tape of the new elementmodelResourceStructureId
- the model resource structure idlocale
- the content locale- Returns:
- the new element data containing structure id and site path
- Throws:
CmsRpcException
- if something goes wrong processing the request
-
getContainerInfo
This method is used for serialization purposes only.- Returns:
- container info
-
getDeleteOptions
CmsDialogOptionsAndInfo getDeleteOptions(String clientId, CmsUUID pageStructureId, String requestParams) throws CmsRpcException Returns the delete options.- Parameters:
clientId
- the client element idpageStructureId
- the current page structure idrequestParams
- optional request parameters- Returns:
- the delete options
- Throws:
CmsRpcException
- in case something goes wrong
-
getEditOptions
CmsDialogOptionsAndInfo getEditOptions(String clientId, CmsUUID pageStructureId, String requestParams, boolean isListElement) throws CmsRpcException Returns the edit options.- Parameters:
clientId
- the client element idpageStructureId
- the current page structure idrequestParams
- optional request parametersisListElement
- in case a list element, not a container element is about to be edited- Returns:
- the edit options
- Throws:
CmsRpcException
- in case something goes wrong
-
getElementInfo
This method is used for serialization purposes only.- Returns:
- element info
-
getElementsLockedForPublishing
Checks which structure ids of a given set belong to resources locked for publishing by the current user, and then returns those.- Parameters:
idsToCheck
- the set of ids to check- Returns:
- the subset of ids which belong to resources locked for publishing by the current user
- Throws:
CmsRpcException
- if something goes wrong
-
getFavoriteList
List<CmsContainerElementData> getFavoriteList(CmsUUID pageStructureId, CmsUUID detailContentId, Collection<CmsContainer> containers, String locale) throws CmsRpcException Returns the container element data of the favorite list.- Parameters:
pageStructureId
- the container page structure iddetailContentId
- the detail content structure idcontainers
- the containers of the current pagelocale
- the content locale- Returns:
- the favorite list element data
- Throws:
CmsRpcException
- if something goes wrong processing the request
-
getListElementCreationOptions
CmsListElementCreationDialogData getListElementCreationOptions(CmsUUID structureId, String jsonListAddData) throws CmsRpcException Loads the data for the list element creation dialog.- Parameters:
structureId
- the structure id of the container element for which we want to load the optionsjsonListAddData
- the list-add metadata read from the DOM- Returns:
- the data for the list element creation dialog
- Throws:
CmsRpcException
- if something goes wrong
-
getNewOptions
CmsDialogOptionsAndInfo getNewOptions(String clientId, CmsUUID pageStructureId, String requestParams) throws CmsRpcException Gets the edit handler options for creating a new element.- Parameters:
clientId
- the client id of the selected elementpageStructureId
- the container page structure idrequestParams
- the request parameter string- Returns:
- the dialog option data from the edit handler
- Throws:
CmsRpcException
- if something goes wrong
-
getRecentList
List<CmsContainerElementData> getRecentList(CmsUUID pageStructureId, CmsUUID detailContentId, Collection<CmsContainer> containers, String locale) throws CmsRpcException Returns the container element data of the recent list.- Parameters:
pageStructureId
- the container page structure iddetailContentId
- the detail content structure idcontainers
- the containers of the current pagelocale
- the content locale- Returns:
- the recent list element data
- Throws:
CmsRpcException
- if something goes wrong processing the request
-
getRemovedElementStatus
CmsRemovedElementStatus getRemovedElementStatus(String id, CmsUUID containerpageId) throws CmsRpcException Gets the status of a removed element.- Parameters:
id
- the client id of the removed elementcontainerpageId
- the id of the page which should be excluded from the relation check, or null if no page should be excluded- Returns:
- the status of the removed element
- Throws:
CmsRpcException
- if something goes wrong
-
getReuseInfo
CmsReuseInfo getReuseInfo(CmsUUID pageId, CmsUUID detailId, CmsUUID elementId) throws CmsRpcException Loads the reuse information for a container element.- Parameters:
pageId
- the current page iddetailId
- the current detail idelementId
- the id of the element to check- Returns:
- the reuse information for the element
- Throws:
CmsRpcException
- if something goes wrong
-
handleDelete
void handleDelete(String clientId, String deleteOption, CmsUUID pageStructureId, String requestParams) throws CmsRpcException Handles the element deletion.- Parameters:
clientId
- the client element iddeleteOption
- the selected delete optionpageStructureId
- the current page structure idrequestParams
- optional request parameters- Throws:
CmsRpcException
- in case something goes wrong
-
loadClipboardTab
int loadClipboardTab()Loads the index of the clipboard tab last selected by the user.- Returns:
- the clipboard tab index
-
prefetch
Returns the initialization data.- Returns:
- the initialization data
- Throws:
CmsRpcException
- if something goes wrong
-
prepareForEdit
CmsUUID prepareForEdit(String clientId, String editOption, CmsUUID pageStructureId, String requestParams) throws CmsRpcException Prepares an element to be edited.- Parameters:
clientId
- the client element ideditOption
- the selected delete optionpageStructureId
- the current page structure idrequestParams
- optional request parameters- Returns:
- the structure ID of the content to edit
- Throws:
CmsRpcException
- in case something goes wrong
-
saveClipboardTab
Saves the index of the clipboard tab selected by the user.- Parameters:
tabIndex
- the index of the selected clipboard tab
-
saveContainerpage
long saveContainerpage(CmsUUID pageStructureId, List<CmsContainer> containers) throws CmsRpcException Saves the container-page.- Parameters:
pageStructureId
- the container page structure idcontainers
- the container-page's containers- Returns:
- the server time stamp of time of saving
- Throws:
CmsRpcException
- if something goes wrong processing the request
-
saveDetailContainers
long saveDetailContainers(CmsUUID detailId, String detailContainerResource, List<CmsContainer> containers) throws CmsRpcException Saves the detail containers.- Parameters:
detailId
- the detail content iddetailContainerResource
- the detail container resource pathcontainers
- the container-page's containers- Returns:
- the server time stamp of time of saving
- Throws:
CmsRpcException
- if something goes wrong processing the request
-
saveFavoriteList
Saves the favorite list.- Parameters:
clientIds
- favorite list element id'suri
- the container page URI- Throws:
CmsRpcException
- if something goes wrong processing the request
-
saveRecentList
Saves the recent list.- Parameters:
clientIds
- recent list element id'suri
- the container page URI- Throws:
CmsRpcException
- if something goes wrong processing the request
-
setEditSmallElements
Enables or disables editing for small elements on page load.- Parameters:
editSmallElements
- the defautl setting for the small element editability- Throws:
CmsRpcException
- if something goes wrong
-
setElementView
Sets the element view.- Parameters:
elementView
- the element view- Throws:
CmsRpcException
- if something goes wrong processing the request
-
setLastPage
Stores information about the container page last edited.- Parameters:
pageId
- the page iddetailId
- the detail content id- Throws:
CmsRpcException
- if something goes wrong