Package lumis.portal.presentation
Class PageRendererUtil
- java.lang.Object
-
- lumis.portal.presentation.PageRendererUtil
-
public class PageRendererUtil extends java.lang.Object
Contains utility methods to help the page render.- Since:
- 5.6.0
- Version:
- $Revision: 25405 $ $Date: 2023-01-05 15:35:12 -0300 (Thu, 05 Jan 2023) $
-
-
Constructor Summary
Constructors Constructor Description PageRendererUtil()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static java.util.List<java.lang.String>
getHolderServiceInterfaceInstanceIds(java.lang.String holderId, org.w3c.dom.Document layoutDocument)
Returns the identifiers of the service interface instances in a holder.static java.net.URL
getLayoutFilePath(PageWebResource pageWebResource)
Returns the path to the layout file.static org.w3c.dom.Document
getPageLayout(SessionConfig sessionConfig, PageWebResource pageWebResource, ITransaction transaction, int mode)
Returns current page's layoutdocument
.static java.util.Collection<java.lang.String>
getPageLayoutHolderIds(org.w3c.dom.Document pageLayout, PageWebResource pageWebResource)
Returns a collection of holder ids for the given page layoutDocument
if thePageWebResource
has a layout file path, else returns null.static java.lang.String
getServiceInterfaceInstanceSafeModeHTML(java.lang.String serviceInterfaceInstanceId)
Returns the HTML used for a service interface instance rendering in safe mode.static java.lang.CharSequence
renderServiceInterfaceInstance(java.lang.String baseServiceInterfaceInstanceId, LayoutFilePage page)
Returns the HTML source code for the service interface instance instantiated on a page.
-
-
-
Method Detail
-
getServiceInterfaceInstanceSafeModeHTML
public static java.lang.String getServiceInterfaceInstanceSafeModeHTML(java.lang.String serviceInterfaceInstanceId) throws PortalException
Returns the HTML used for a service interface instance rendering in safe mode.- Returns:
- the HTML code.
- Throws:
PortalException
- Since:
- 5.6.0
-
renderServiceInterfaceInstance
public static java.lang.CharSequence renderServiceInterfaceInstance(java.lang.String baseServiceInterfaceInstanceId, LayoutFilePage page)
Returns the HTML source code for the service interface instance instantiated on a page.- Parameters:
baseServiceInterfaceInstanceId
- the service interface instance identifier (before replacements).page
- the page that contains the service instance to be rendered.- Returns:
- the HTML source code for the service interface instance instantiated on a page.
- Since:
- 6.0.0
-
getPageLayout
public static org.w3c.dom.Document getPageLayout(SessionConfig sessionConfig, PageWebResource pageWebResource, ITransaction transaction, int mode)
Returns current page's layoutdocument
. Result is cached during the request's live time.- Returns:
- current page's layout.
- Since:
- 6.0.0
-
getHolderServiceInterfaceInstanceIds
public static java.util.List<java.lang.String> getHolderServiceInterfaceInstanceIds(java.lang.String holderId, org.w3c.dom.Document layoutDocument)
Returns the identifiers of the service interface instances in a holder.- Parameters:
holderId
- the holder identifier.- Returns:
- the service interface instance identifiers, ordered according to their place in the holder.
- Since:
- 6.0.0
-
getLayoutFilePath
public static java.net.URL getLayoutFilePath(PageWebResource pageWebResource)
Returns the path to the layout file.- Returns:
- the path to the layout file, or
null
if no layout file is set. - Since:
- 6.0.0
-
getPageLayoutHolderIds
public static java.util.Collection<java.lang.String> getPageLayoutHolderIds(org.w3c.dom.Document pageLayout, PageWebResource pageWebResource)
Returns a collection of holder ids for the given page layoutDocument
if thePageWebResource
has a layout file path, else returns null.- Parameters:
pageLayout
- the page layout document.pageWebResource
- the page web resource.- Returns:
- A collection of holder ids for the given page layout
Document
if thePageWebResource
has a layout file path, else returns null. - Since:
- 6.0.0
-
-