public final class RenderUtil extends Object
| Constructor and Description |
|---|
RenderUtil() |
| Modifier and Type | Method and Description |
|---|---|
static String |
generateComponentId(String scopeId,
String regionId,
String sourceId)
Generates the deterministic component id from its key properties
|
static Object |
getComponentBindingSourceObject(RequestContext context,
Component component)
Returns the object to which this component is bound
This is the same as calling component.getSourceObject()
|
static RequestContext |
getContext(javax.servlet.http.HttpServletRequest request)
Attempts to retrieve the render context instance bound to the given
http servlet request
|
static String |
getSourceId(RequestContext context,
String scopeId)
Return the "source" ID for the given scope ID for the supplied context.
|
static void |
object(RequestContext context,
javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response,
String objectId,
String formatId)
/**
Renders the fully formed URL string for a link to a given content object
|
static void |
page(RequestContext context,
javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response,
String pageId,
String formatId,
String objectId)
Renders the fully formed URL string for a link to a given page
|
static void |
pageType(RequestContext context,
javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response,
String pageTypeId,
String formatId,
String objectId)
Renders the fully formed URL string for a link to a given page type
|
static String |
renderLinkImport(RequestContext context,
String uri)
Renders an HTML stylesheet tag.
|
static String |
renderLinkImport(RequestContext context,
String uri,
String id)
Renders an HTML stylesheet tag and optionally appends
the incoming query string to the URL.
|
static String |
renderScriptImport(RequestContext context,
String uri)
Renders an HTML tag to the output stream
|
static String |
validHtmlId(String id)
Helper to ensure only valid and acceptable characters are output as HTML element IDs.
|
public static void page(RequestContext context, javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response, String pageId, String formatId, String objectId)
context - RequestContextrequest - HttpServletRequestresponse - HttpServletResponseobjectId - StringformatId - Stringpublic static void object(RequestContext context, javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response, String objectId, String formatId)
context - RequestContextrequest - HttpServletRequestresponse - HttpServletResponseobjectId - StringformatId - Stringpublic static void pageType(RequestContext context, javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response, String pageTypeId, String formatId, String objectId)
context - RequestContextrequest - HttpServletRequestresponse - HttpServletResponsepageTypeId - StringformatId - StringobjectId - Stringpublic static String renderScriptImport(RequestContext context, String uri)
context - RequestContexturi - Stringpublic static String renderLinkImport(RequestContext context, String uri)
context - RequestContexturi - Stringpublic static String renderLinkImport(RequestContext context, String uri, String id)
context - RequestContexturi - Stringid - Stringpublic static String validHtmlId(String id)
id - the idpublic static RequestContext getContext(javax.servlet.http.HttpServletRequest request)
request - HttpServletRequestpublic static String getSourceId(RequestContext context, String scopeId)
context - Current RequestContextscopeId - WebFrameworkConstantspublic static Object getComponentBindingSourceObject(RequestContext context, Component component)
context - RequestContextcomponent - ComponentCopyright © 2005–2016 Alfresco Software. All rights reserved.