Interface IPageManager
-
- All Superinterfaces:
IConfigDeleter
,IConfigKeyChecker
- All Known Implementing Classes:
PageManager
@StableMinor(version="17.0", sinceVersion="4.0") public interface IPageManager extends IConfigDeleter, IConfigKeyChecker
- Since:
- 5.0.0
- Version:
- $Revision$ $Date$
-
-
Method Summary
All Methods Instance Methods Abstract Methods Deprecated Methods Modifier and Type Method Description java.lang.String
add(SessionConfig sessionConfig, PageConfig pageConfig, ITransaction transaction)
Add a page.void
addCssLink(SessionConfig sessionConfig, java.lang.String pageId, java.lang.String cssId, int position, ITransaction transaction)
Add the hyperlink to the page's CSS file.void
addOrUpdate(SessionConfig sessionConfig, PageConfig pageConfig, ITransaction transaction)
Add or Update a Page, depending on its previous existence.void
clearCache(SessionConfig sessionConfig, java.lang.String pageId, ITransaction transaction)
Clear the page cache.void
clearCache(SessionConfig sessionConfig, java.util.Collection<java.lang.String> pageIds, ITransaction transaction)
Clears the cache for a group of pages.void
copy(SessionConfig sessionConfig, java.lang.String sourcePageId, java.lang.String destinationPageId, ITransaction transaction)
Copy the layout and properties from the original page to the destination page.void
delete(SessionConfig sessionConfig, java.lang.String pageId, ITransaction transaction)
Delete a page.void
deleteCssLink(SessionConfig sessionConfig, java.lang.String pageId, java.lang.String cssId, ITransaction transaction)
Delete the hyperlink to the page's CSS file.void
deleteOrphanInterfaces(SessionConfig sessionConfig, java.lang.String pageId, ITransaction daoTransaction)
Remove any interface instance associated to the page that is not being referenced in it's layout.java.lang.String
deserialize(SessionConfig sessionConfig, DeserializationConfig deserializationConfig, org.w3c.dom.Node pageNode, boolean firstDeserialization, ITransaction transaction)
java.lang.String
deserialize(SessionConfig sessionConfig, DeserializationConfig deserializationConfig, org.w3c.dom.Node pageNode, ITransaction transaction)
void
deserializeCss(SessionConfig sessionConfig, DeserializationConfig deserializationConfig, org.w3c.dom.Node cssLinksNodes, ITransaction transaction)
void
disconnectFromTemplate(SessionConfig sessionConfig, java.lang.String pageId, ITransaction transaction)
Disconnect the page from its template if one existsPageConfig
get(SessionConfig sessionConfig, java.lang.String pageId, ITransaction transaction)
Get the configuration of the page.int
getCachePage(SessionConfig sessionConfig, PageConfig pageConfig, ITransaction transaction)
boolean
getCenterPage(SessionConfig sessionConfig, PageConfig pageConfig, ITransaction transaction)
java.util.List<java.lang.String>
getCssIds(SessionConfig sessionConfig, java.lang.String pageId, ITransaction transaction)
Get a list of Css Ids of the page.java.util.List<java.lang.String>
getCssIdsRecursively(SessionConfig sessionConfig, java.lang.String pageId, ITransaction transaction)
Get a list of Css Ids of the page including inherited Css.java.lang.String
getFirstIdByChannelId(SessionConfig sessionConfig, java.lang.String channelId, ITransaction transaction)
PageConfig
getFirstPageByChannelIdRecursively(SessionConfig sessionConfig, java.lang.String channelId, ITransaction transaction)
Returns the first page for a channel, including pages in sub-channels.java.util.List<java.lang.String>
getIdsByParentChannelId(SessionConfig sessionConfig, java.lang.String channelId, ITransaction transaction)
Returns all the pages that have the given channel as their parent channel.java.util.List<java.lang.String>
getIdsByParentChannelIdRecursively(SessionConfig sessionConfig, java.lang.String channelId, ITransaction transaction)
java.util.Collection<java.lang.String>
getIdsByParentTemplateId(SessionConfig sessionConfig, java.lang.String parentTemplateId, ITransaction transaction)
java.util.Collection<java.lang.String>
getIdsByServiceInstanceId(SessionConfig sessionConfig, java.lang.String serviceInstanceId, ITransaction transaction)
int
getLayoutType(SessionConfig sessionConfig, PageConfig pageConfig, ITransaction transaction)
Returns the layout type used for rendering the page to the end user.java.util.List<java.lang.String>
getMetaTagIdsRecursively(SessionConfig sessionConfig, PageConfig pageConfig, ITransaction transaction)
Get a list of Meta-Tags Ids of the page including inherited Meta-Tags.java.lang.String
getPageWebResourceDataProviderClassName(SessionConfig sessionConfig, PageConfig pageConfig, ITransaction transaction)
Returns theIPageWebResourceDataProvider
class name for the given page.java.util.List<java.lang.String>
getParentPathIds(SessionConfig sessionConfig, java.lang.String pageId, ITransaction transaction)
Returns the Ids of parent channels recursively.java.lang.String
getPath(SessionConfig sessionConfig, java.lang.String pageId, boolean localizable, ITransaction transaction)
Returns the complete path beginning from the root channel to the page.java.lang.String
getPath(SessionConfig sessionConfig, java.lang.String pageId, ITransaction transaction)
Returns the complete path beginning from the root channel to the page.java.lang.String
getProtocolScheme(SessionConfig sessionConfig, int protocolType, ITransaction transaction)
Return the protocol Scheme of the page given a protocol type.int
getProtocolType(SessionConfig sessionConfig, PageConfig pageConfig, ITransaction transaction)
Returns the protocolType of the given page.java.lang.String
getRuntimeDataProviderClassName(SessionConfig sessionConfig, PageConfig pageConfig, ITransaction transaction)
Deprecated.Since 5.0.0 replaced bygetPageWebResourceDataProviderClassName(SessionConfig, PageConfig, ITransaction)
.void
serialize(SessionConfig sessionConfig, java.lang.String pageId, java.io.OutputStream outputStream, ITransaction transaction)
void
serializeCss(SessionConfig sessionConfig, java.lang.String pageId, java.io.OutputStream outputStream, ITransaction transaction)
void
update(SessionConfig sessionConfig, PageConfig pageConfig, ITransaction transaction)
Update a page.void
updateDeserializedPageLayout(SessionConfig sessionConfig, DeserializationConfig deserializationConfig, java.lang.String pageId, ITransaction transaction)
void
updateLayout(SessionConfig sessionConfig, java.lang.String pageId, java.lang.String layout, ITransaction transaction)
Update the page layout.void
updateSsiProperty(SessionConfig sessionConfig, ServiceInterfaceInstanceConfig serviceInterfaceInstanceConfig, ITransaction transaction)
Updates the server side include property of the interface's page.-
Methods inherited from interface lumis.portal.serialization.operation.IConfigDeleter
deleteConfig
-
Methods inherited from interface lumis.portal.serialization.operation.IConfigKeyChecker
keyExists
-
-
-
-
Method Detail
-
addOrUpdate
void addOrUpdate(SessionConfig sessionConfig, PageConfig pageConfig, ITransaction transaction) throws ManagerException, PortalException
Add or Update a Page, depending on its previous existence.- Parameters:
sessionConfig
-pageConfig
-transaction
-- Throws:
ManagerException
PortalException
-
add
java.lang.String add(SessionConfig sessionConfig, PageConfig pageConfig, ITransaction transaction) throws ManagerException, PortalException
Add a page. If the page is a page template, and its layout is null, a default layout containing an interface holder is set in the page template.- Parameters:
sessionConfig
-pageConfig
-transaction
-- Returns:
- a String.
- Throws:
ManagerException
PortalException
-
copy
void copy(SessionConfig sessionConfig, java.lang.String sourcePageId, java.lang.String destinationPageId, ITransaction transaction) throws ManagerException, PortalException
Copy the layout and properties from the original page to the destination page. Also replace all the destination page's interface instances with new instances of interfaces that exists in the source page.- Parameters:
sessionConfig
-sourcePageId
-destinationPageId
-transaction
-- Throws:
ManagerException
PortalException
-
get
PageConfig get(SessionConfig sessionConfig, java.lang.String pageId, ITransaction transaction) throws ManagerException, PortalException
Get the configuration of the page.- Parameters:
sessionConfig
-pageId
-transaction
-- Returns:
- a PageConfig.
- Throws:
ManagerException
PortalException
-
delete
void delete(SessionConfig sessionConfig, java.lang.String pageId, ITransaction transaction) throws ManagerException, PortalException
Delete a page.- Parameters:
sessionConfig
-pageId
-transaction
-- Throws:
ManagerException
PortalException
-
update
void update(SessionConfig sessionConfig, PageConfig pageConfig, ITransaction transaction) throws ManagerException, PortalException
Update a page.- Parameters:
sessionConfig
-pageConfig
-transaction
-- Throws:
ManagerException
PortalException
-
updateLayout
void updateLayout(SessionConfig sessionConfig, java.lang.String pageId, java.lang.String layout, ITransaction transaction) throws ManagerException, PortalException
Update the page layout.- Parameters:
sessionConfig
-pageConfig
-transaction
-- Throws:
ManagerException
PortalException
-
updateSsiProperty
void updateSsiProperty(SessionConfig sessionConfig, ServiceInterfaceInstanceConfig serviceInterfaceInstanceConfig, ITransaction transaction) throws PortalException
Updates the server side include property of the interface's page.If the server side include is to be calculated automatically, this method checks if any of the interface instances within the page have the ssi property set to true. If so the ssi property of the page is set to true.
- Parameters:
sessionConfig
-serviceInterfaceInstanceConfig
-transaction
-- Throws:
PortalException
- Since:
- 4.1.0
-
getPath
java.lang.String getPath(SessionConfig sessionConfig, java.lang.String pageId, ITransaction transaction) throws ManagerException, PortalException
Returns the complete path beginning from the root channel to the page.- Parameters:
sessionConfig
-pageId
-transaction
-- Returns:
- a String.
- Throws:
ManagerException
PortalException
-
getPath
java.lang.String getPath(SessionConfig sessionConfig, java.lang.String pageId, boolean localizable, ITransaction transaction) throws ManagerException, PortalException
Returns the complete path beginning from the root channel to the page.- Parameters:
sessionConfig
-pageId
-transaction
-localizable
-- Returns:
- the path.
- Throws:
ManagerException
PortalException
-
getParentPathIds
java.util.List<java.lang.String> getParentPathIds(SessionConfig sessionConfig, java.lang.String pageId, ITransaction transaction) throws ManagerException, PortalException
Returns the Ids of parent channels recursively.- Parameters:
sessionConfig
-pageId
-transaction
-- Returns:
- an array of Strings.
- Throws:
ManagerException
PortalException
-
getIdsByParentChannelId
java.util.List<java.lang.String> getIdsByParentChannelId(SessionConfig sessionConfig, java.lang.String channelId, ITransaction transaction) throws ManagerException, PortalException
Returns all the pages that have the given channel as their parent channel.- Parameters:
sessionConfig
- The user session id must have rights to read the page listchannelId
- Id of the channeltransaction
- A transaction that should be used for acessing information from the database- Returns:
- an arrays of Strings.
- Throws:
ManagerException
PortalException
-
getFirstIdByChannelId
java.lang.String getFirstIdByChannelId(SessionConfig sessionConfig, java.lang.String channelId, ITransaction transaction) throws ManagerException, PortalException
- Parameters:
sessionConfig
-channelId
-transaction
-- Returns:
- Throws:
ManagerException
PortalException
-
getIdsByParentChannelIdRecursively
java.util.List<java.lang.String> getIdsByParentChannelIdRecursively(SessionConfig sessionConfig, java.lang.String channelId, ITransaction transaction) throws ManagerException, PortalException
- Parameters:
sessionConfig
-channelId
-transaction
-- Returns:
- a array of strings.
- Throws:
ManagerException
PortalException
-
addCssLink
void addCssLink(SessionConfig sessionConfig, java.lang.String pageId, java.lang.String cssId, int position, ITransaction transaction) throws ManagerException, PortalException
Add the hyperlink to the page's CSS file. To access this method, the user needs the PERMISSION_TYPE_PAGES_LAYOUT permission.- Parameters:
sessionConfig
-pageId
-cssId
-position
-transaction
-- Throws:
ManagerException
PortalException
-
deleteCssLink
void deleteCssLink(SessionConfig sessionConfig, java.lang.String pageId, java.lang.String cssId, ITransaction transaction) throws ManagerException, PortalException
Delete the hyperlink to the page's CSS file. To access this method, the user needs the PERMISSION_TYPE_PAGES_LAYOUT permission.- Parameters:
sessionConfig
-pageId
-cssId
-transaction
-- Throws:
ManagerException
PortalException
-
getCssIds
java.util.List<java.lang.String> getCssIds(SessionConfig sessionConfig, java.lang.String pageId, ITransaction transaction) throws ManagerException, PortalException
Get a list of Css Ids of the page.- Parameters:
sessionConfig
-pageId
-transaction
-- Returns:
- an arrays of Strings.
- Throws:
ManagerException
PortalException
-
getCssIdsRecursively
java.util.List<java.lang.String> getCssIdsRecursively(SessionConfig sessionConfig, java.lang.String pageId, ITransaction transaction) throws ManagerException, PortalException
Get a list of Css Ids of the page including inherited Css.- Parameters:
sessionConfig
-pageId
-transaction
-- Returns:
- an arrays of Strings.
- Throws:
ManagerException
PortalException
-
getMetaTagIdsRecursively
java.util.List<java.lang.String> getMetaTagIdsRecursively(SessionConfig sessionConfig, PageConfig pageConfig, ITransaction transaction) throws ManagerException, PortalException
Get a list of Meta-Tags Ids of the page including inherited Meta-Tags.- Parameters:
sessionConfig
-pageConfig
-transaction
-- Returns:
- Throws:
ManagerException
PortalException
-
disconnectFromTemplate
void disconnectFromTemplate(SessionConfig sessionConfig, java.lang.String pageId, ITransaction transaction) throws ManagerException, PortalException
Disconnect the page from its template if one exists- Parameters:
sessionConfig
-pageId
-transaction
-- Throws:
ManagerException
PortalException
-
getCenterPage
boolean getCenterPage(SessionConfig sessionConfig, PageConfig pageConfig, ITransaction transaction) throws ManagerException, PortalException
- Parameters:
sessionConfig
-pageConfig
-transaction
-- Returns:
- true if the pages is centered and false otherwise.
- Throws:
ManagerException
PortalException
-
getLayoutType
int getLayoutType(SessionConfig sessionConfig, PageConfig pageConfig, ITransaction transaction) throws ManagerException, PortalException
Returns the layout type used for rendering the page to the end user.The return would be one of
PageConfig.PAGE_LAYOUT_TYPE_INHERIT
,PageConfig.PAGE_LAYOUT_TYPE_WITH_TABLES
orPageConfig.PAGE_LAYOUT_TYPE_TABLELESS
- Parameters:
sessionConfig
-pageConfig
-transaction
-- Returns:
- the layout format.
- Throws:
ManagerException
PortalException
-
getCachePage
int getCachePage(SessionConfig sessionConfig, PageConfig pageConfig, ITransaction transaction) throws ManagerException, PortalException
- Parameters:
sessionConfig
-pageConfig
-transaction
-- Returns:
- an integer.
- Throws:
ManagerException
PortalException
-
serialize
void serialize(SessionConfig sessionConfig, java.lang.String pageId, java.io.OutputStream outputStream, ITransaction transaction) throws ManagerException, PortalException
- Parameters:
sessionConfig
-pageId
-outputStream
-transaction
-- Throws:
ManagerException
PortalException
-
deserialize
java.lang.String deserialize(SessionConfig sessionConfig, DeserializationConfig deserializationConfig, org.w3c.dom.Node pageNode, ITransaction transaction) throws ManagerException, PortalException
- Parameters:
sessionConfig
-deserializationConfig
-pageNode
-transaction
-- Returns:
- a String.
- Throws:
ManagerException
PortalException
-
deserialize
java.lang.String deserialize(SessionConfig sessionConfig, DeserializationConfig deserializationConfig, org.w3c.dom.Node pageNode, boolean firstDeserialization, ITransaction transaction) throws ManagerException, PortalException
- Throws:
ManagerException
PortalException
-
updateDeserializedPageLayout
void updateDeserializedPageLayout(SessionConfig sessionConfig, DeserializationConfig deserializationConfig, java.lang.String pageId, ITransaction transaction) throws ManagerException, PortalException
- Parameters:
sessionConfig
-deserializationConfig
-pageId
-transaction
-- Throws:
ManagerException
PortalException
-
getIdsByServiceInstanceId
java.util.Collection<java.lang.String> getIdsByServiceInstanceId(SessionConfig sessionConfig, java.lang.String serviceInstanceId, ITransaction transaction) throws PortalException
- Parameters:
sessionConfig
- identifier for the session.serviceInstanceId
- the id of the service instance.transaction
- the transaction for persistence access.- Returns:
- the ids of the pages that contain an interface of the given service instance id.
- Throws:
PortalException
-
serializeCss
void serializeCss(SessionConfig sessionConfig, java.lang.String pageId, java.io.OutputStream outputStream, ITransaction transaction) throws ManagerException, PortalException
- Parameters:
sessionConfig
-pageId
-outputStream
-transaction
-- Throws:
ManagerException
PortalException
-
deserializeCss
void deserializeCss(SessionConfig sessionConfig, DeserializationConfig deserializationConfig, org.w3c.dom.Node cssLinksNodes, ITransaction transaction) throws ManagerException, PortalException
- Parameters:
sessionConfig
-deserializationConfig
-cssLinksNodes
-transaction
-- Throws:
ManagerException
PortalException
-
getIdsByParentTemplateId
java.util.Collection<java.lang.String> getIdsByParentTemplateId(SessionConfig sessionConfig, java.lang.String parentTemplateId, ITransaction transaction) throws ManagerException, PortalException
- Parameters:
sessionConfig
-parentTemplateId
-transaction
-- Returns:
- Throws:
ManagerException
PortalException
-
clearCache
void clearCache(SessionConfig sessionConfig, java.lang.String pageId, ITransaction transaction) throws ManagerException, PortalException
Clear the page cache.This method clears the following caches
- Page Config
- Page Cache HTML
- Page ACL
- ServiceInterfaceInstanceConfig caches calling the service interface instance manager
- ServiceInterfaceInstanceHtmlCache
- Parameters:
sessionConfig
-pageId
-transaction
-- Throws:
ManagerException
PortalException
- Since:
- 4.0.4
- See Also:
clearCache(SessionConfig, Collection, ITransaction)
-
clearCache
void clearCache(SessionConfig sessionConfig, java.util.Collection<java.lang.String> pageIds, ITransaction transaction) throws PortalException
Clears the cache for a group of pages. The following caches are cleared:PageConfig
instances cache- Page cache HTML (may be done asynchronously)
- Caches cleaned by calling
IServiceInterfaceInstanceManager.clearCache(SessionConfig, String, ITransaction)
for each interface instance in the pages.
clearCache(SessionConfig, String, ITransaction)
.- Parameters:
sessionConfig
- the user session information.pageIds
- the page identifiers.transaction
- the transaction for persistence access.- Throws:
PortalException
- Since:
- 4.1.0
- See Also:
clearCache(SessionConfig, String, ITransaction)
-
deleteOrphanInterfaces
void deleteOrphanInterfaces(SessionConfig sessionConfig, java.lang.String pageId, ITransaction daoTransaction) throws ManagerException, PortalException
Remove any interface instance associated to the page that is not being referenced in it's layout.- Parameters:
sessionConfig
-pageId
-daoTransaction
-- Throws:
ManagerException
PortalException
- Since:
- 4.0.6
-
getProtocolType
int getProtocolType(SessionConfig sessionConfig, PageConfig pageConfig, ITransaction transaction) throws ManagerException, PortalException
Returns the protocolType of the given page.This method checks recursively up the page´s ancestors until it finds a protocolType that is not
PageConfig.PAGE_PROTOCOL_INHERIT
.Possible protocol types are:
PageConfig.PAGE_PROTOCOL_HTTP
PageConfig.PAGE_PROTOCOL_HTTPS
PageConfig.PAGE_PROTOCOL_ALL
- Parameters:
sessionConfig
-pageConfig
-transaction
-- Returns:
- Throws:
ManagerException
PortalException
-
getProtocolScheme
java.lang.String getProtocolScheme(SessionConfig sessionConfig, int protocolType, ITransaction transaction) throws ManagerException, PortalException
Return the protocol Scheme of the page given a protocol type.This method returns a string representation of the protocol type.
- Parameters:
sessionConfig
-protocolType
-transaction
-- Returns:
- If the protocol type is
PageConfig.PAGE_PROTOCOL_HTTP
,PageConfig.PAGE_PROTOCOL_HTTP_NAME
is returned.
If the protocol type isPageConfig.PAGE_PROTOCOL_HTTPS
,PageConfig.PAGE_PROTOCOL_HTTPS_NAME
is returned.
In all other cases null is returned. - Throws:
ManagerException
PortalException
-
getRuntimeDataProviderClassName
@Deprecated java.lang.String getRuntimeDataProviderClassName(SessionConfig sessionConfig, PageConfig pageConfig, ITransaction transaction) throws PortalException
Deprecated.Since 5.0.0 replaced bygetPageWebResourceDataProviderClassName(SessionConfig, PageConfig, ITransaction)
.Returns the runtime data provider class name for the given page. This method recursively traverses up a channel tree starting from the given page until the first page/channel that does not inherit the runtime data provider property. Based on the runtime data provider type, either a standard or customized page runtime data provider class name is returned.- Parameters:
sessionConfig
- current user sessionpageConfig
- page configurationtransaction
- current transaction- Returns:
- class name of the data provider class
- Throws:
PortalException
- Since:
- 4.2.0
-
getPageWebResourceDataProviderClassName
java.lang.String getPageWebResourceDataProviderClassName(SessionConfig sessionConfig, PageConfig pageConfig, ITransaction transaction) throws PortalException
Returns theIPageWebResourceDataProvider
class name for the given page.This method recursively traverses up a channel tree starting from the given page until the first channel that does not inherit the web resource data provider property. Based on the page web resource data provider type, either a standard or customized page web resource data provider class name is returned.
- Parameters:
sessionConfig
- user session information.pageConfig
- the page.transaction
- the transaction for persistence access.- Returns:
- full qualified name of the data provider class.
- Throws:
PortalException
- Since:
- 5.0.0
-
getFirstPageByChannelIdRecursively
PageConfig getFirstPageByChannelIdRecursively(SessionConfig sessionConfig, java.lang.String channelId, ITransaction transaction) throws PortalException
Returns the first page for a channel, including pages in sub-channels.- Parameters:
sessionConfig
- the user session information.channelId
- the channel identifier.transaction
- the transaction for persistence access.- Returns:
- the page.
- Throws:
PortalObjectNotFoundException
- if no such page was found.PortalException
- Since:
- 5.0.0
-
-