|
Novell exteNd Director 5.2 API |
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
interface to define the contract of a Portal Controller (responsible for rendering a response to a portal request)
Field Summary | |
static String |
AGGREGATION_CONTROLLER
well known key to access the implementation class of this interface in the Portal Service's service.xml |
static String |
DEFAULT_REQUEST_TIMEOUT
well known key to access the default request timeout (this timeout can be overwritten by portlet definitions) in the Portal Service's config.xml |
static String |
FORCE_RENDER_TIMEOUT
well known key to access the config file to find out if aggregation controller should enforce return from a portlet render call. |
static String |
FORCE_SERIAL_SYNCH_RENDER
well known key to access the config file to find out if agregation controller should enforce serial rendering synchronous portlets. |
static String |
MAX_REQUEST_TIMEOUT
well known key to access the max request timeout (no request is allowed to take longer) in the Portal Service's config.xml |
static String |
PARALLEL_RENDERING_ENABLED
well known key to access the config file to find out if parallel rendering of asynchronous portlets should be enabled. |
static String |
REDIRECT_AFTER_REQUEST
well known key to access the config file to find out if the request should be redirected after a render and/or action request; the redirect will remove the query string from the URL and force a GET for the next browser request (no accidental double posting) in the Portal Service's config.xml |
Method Summary | |
void |
assimilatePortletResponse(EbiPortalContext portalContext,
com.novell.afw.portal.api.EbiPortletInfoBean portletInfo,
Object portletDataReceiver,
HashMap styleMap,
EbiMarkupResponse markupResponse)
Assimilate the portal markup fragment into the response. |
long |
getDefaultRequestTimeout()
get the default timeout for a request (independent of any portlet that will be rendered) |
boolean |
getForceRenderTimeout()
Returns true if aggregation controller should enforce return from a portlet render call. |
boolean |
getForceSerialSynchRender()
Returns true if synchronous portlets should be rendered serially(sequentially) before asynchronous portlet rendering can be started. |
long |
getMaxRequestTimeout()
get the max timeout for a request (independent of any portlet that will be rendered) |
boolean |
getParallelRenderEnabled()
Returns true if aparallel rendering of asynchronous portlets is enabled. |
String |
getTimeoutResponse(com.novell.afw.portal.api.EbiPortletInfoBean portlet,
Locale locale)
get the default content (markup fragment) for a portlet in case the request is timing out and we need to provide some default content |
void |
init(Map params)
initialization hook |
void |
renderPortalPIDResponse(EbiPortalContext portalContext,
EbiPortalPID portalPID)
Render a particular portal PID page object |
void |
renderPortalPIDResponse(EbiPortalContext portalContext,
String pid)
Render a particular portal PID page (from the resource set) |
void |
renderPortalResponse(EbiPortalContext portalContext)
render a portal response based on a request to the current portal state (the current container and shared/user page) This is the main entry point (for each portal request) to render a response defined by the current container page, user or shared page and the portlets defined on those pages |
void |
renderPortalResponse(EbiPortalContext portalContext,
String portletName)
Render a particular portlet (only that portlet) in a dynamically created default page Note that whenever there is a default page used to embed portlets, only default preferences can be applied since there is no page specific instance id of the portlet |
void |
renderPortalResponse(EbiPortalContext portalContext,
String[] portlets)
Render a given list of portlets (they don't have to be defined in a page) on a default page Note that whenever there is a default page used to embed portlets, only default preferences can be applied |
void |
renderPortalResponse(EbiPortalContext portalContext,
String pageName,
boolean wrapContainer)
Render only the specified page (user or shared) in side the current (or default) container if wrapContainer is true
otherwise render the page without the container wrapping it |
void |
renderPortalResponse(EbiPortalContext portalContext,
String containerName,
String pageName)
Render the portal response with a specified container page, and optionally a specified user or shared page |
void |
setDefaultRequestTimeout(long timeout)
set the default timeout for a request (independent of any portlet that will be rendered) |
void |
setForceRenderTimeout(boolean force)
Sets flag which defines render call timeout configuration. |
void |
setForceSerialSynchRender(boolean flag)
Sets flag to render synchronous portlets serially before asynchronous portlet rendering can be started. |
void |
setMaxRequestTimeout(long timeout)
set the maximum timeout for a request (independent of any portlet that will be rendered) |
void |
setParallelRenderEnabled(boolean enable)
if asynchronous portlets should be called in a separate thread always (so that the calling thread won't have a chance to block indefinitely) set this to false As a result, all asynchronous portlets will be called in a pooled thread |
void |
shutdown()
shutdown hook time for clean up if need be |
void |
stylePortalResponse(EbiPortalContext portalContext,
com.novell.afw.portal.api.Node responseRoot,
Map styleMap)
a render request has finished and the response is available in form of an xml document; now go and style the response by applying the xsl style sheet for the container page, the user or shared page, and the individual styles for the portlets (if not yet applied after each portlets render individually) Note: by default, all portlets will be styled individually after each of the render methods returs; only if the request attribute EboPortalAggregationConstants.PARAM_STYLE_ONCE is present will the content of each portlet be present as XML in the document and the style sheet URL in the #styleMap the styleMap contains the portlet's style sheet URLs, keyed by com.novell.afw.portal.api.EboPortletInfoBean; it also contains the style sheet URLs for the container and user (or shared) page if the page has an associated style; these two map entries are keyed by a String EboPortalAggregationConstants.ATTR_CONTAINER_STYLE_ID and EboPortalAggregationConstants.ATTR_PAGE_STYLE_ID This method is expected to handle writing the response to the browser |
Field Detail |
public static final String AGGREGATION_CONTROLLER
public static final String DEFAULT_REQUEST_TIMEOUT
public static final String MAX_REQUEST_TIMEOUT
public static final String PARALLEL_RENDERING_ENABLED
public static final String FORCE_SERIAL_SYNCH_RENDER
public static final String FORCE_RENDER_TIMEOUT
public static final String REDIRECT_AFTER_REQUEST
Method Detail |
public long getDefaultRequestTimeout()
public void setDefaultRequestTimeout(long timeout)
timeout
- the timeout value in mspublic long getMaxRequestTimeout()
public void setMaxRequestTimeout(long timeout)
timeout
- the timeout value in mspublic String getTimeoutResponse(com.novell.afw.portal.api.EbiPortletInfoBean portlet, Locale locale)
portlet
- a EboPortletInfoBean
(or null) to decide what response to return (this bean is created during the render
process and allows access to portlet name , instance id, etc. (); if this bean is provided, a timeout message specific to this portlet
can be returned.locale
- the locale based on the current request to allow for localized timeout messagesEbiPortletInfoBean
public boolean getForceRenderTimeout()
public void setForceRenderTimeout(boolean force)
public boolean getForceSerialSynchRender()
public void setForceSerialSynchRender(boolean flag)
public boolean getParallelRenderEnabled()
public void setParallelRenderEnabled(boolean enable)
enable
- true if asynchronous portlets should be rendered in parallelpublic void renderPortalResponse(EbiPortalContext portalContext) throws EboPortletActionException
portalContext
- the EbiPortalContext
that contains the information to get access to the portal, the request, the response, ...public void renderPortalResponse(EbiPortalContext portalContext, String portletName) throws EboPortletActionException
portalContext
- the EbiPortalContext
that contains the information to get to the portal, the request, the response, ...portletName
- the name of the single portlet that has to be renderedpublic void renderPortalResponse(EbiPortalContext portalContext, String containerName, String pageName) throws EboPortletActionException
portalContext
- the EbiPortalContext
that contains the information to get access to the portal, the request, the response, ...containerName
- the name of the container pagepageName
- the name of the shared or user page , or nullpublic void renderPortalResponse(EbiPortalContext portalContext, String pageName, boolean wrapContainer) throws EboPortletActionException
wrapContainer
is true
otherwise render the page without the container wrapping itportalContext
- the EbiPortalContext
that contains the information to get access to the portal, the request, the response, ...pageName
- the name of the page to renderwrapContainer
- true if the page should be wrapped with the current (or default) container, false if the page should not be wrappedpublic void renderPortalResponse(EbiPortalContext portalContext, String[] portlets) throws EboPortletActionException
portalContext
- the EbiPortalContext
that contains the information to get access to the portal, the request, the response, ...portlets
- the list of portlet names to render (as a string array)public void renderPortalPIDResponse(EbiPortalContext portalContext, String pid) throws EboPortletActionException
portalContext
- the EbiPortalContext
that contains the information to get to the portal, the request, the response, ...pid
- the name of the portal PID page from the resource set (e.g. DirectorHome.html)public void renderPortalPIDResponse(EbiPortalContext portalContext, EbiPortalPID portalPID) throws EboPortletActionException
portalContext
- the EbiPortalContext that contains the information to get to the portal, the request, the response, ...portalPID
- the parsed portal PID page in the form of a EbiPortalPID object- Since:
- v.5.0
- See Also:
com.sssw.portal.api.EbiPageManager.getPID(EbiPortalContext, String)
public void assimilatePortletResponse(EbiPortalContext portalContext, com.novell.afw.portal.api.EbiPortletInfoBean portletInfo, Object portletDataReceiver, HashMap styleMap, EbiMarkupResponse markupResponse)
portalContext
- the EbiPortalContext that contains the information to get to the portal, the request, the response, ...portletInfo
- the EbiPortletInfoBean that identifies the portlet that has been renderedportletDataReceiver
- the object that serves as a place holder for the resulting content (in the default implementation
this is the node object in the result document that will hold the markup fragment as a CDATA child node)styleMap
- a Map keyed by PortletInfoBeans that allows access to the style sheet URL for that portlet;
this map is being filled during each portlets render processmarkupResponse
- the rendered content created by the portlet- Since:
- v.5.0
public void shutdown()
public void init(Map params)
params
- your params as a Mappublic void stylePortalResponse(EbiPortalContext portalContext, com.novell.afw.portal.api.Node responseRoot, Map styleMap) throws com.novell.afw.portal.api.IOException
portalContext
- the EbiPortalContext to gain access to the request and response etc.responseRoot
- the root node of the response content document that was assembled during the render processstyleMap
- a map containing the URLs for the styles keyed by EboPortletInfoBean's (and optionally String for the page styles)
|
Novell exteNd Director 5.2 API |
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |