public class ConversationAwareViewHandler
extends javax.faces.application.ViewHandlerWrapper
A forwarding JSF ViewHandler implementation that produces URLs containing the conversation id query string parameter. All methods except those which produce a URL that need to be enhanced are forwarded to the ViewHandler delegate.
A request parameter was chosen to propagate the conversation because it's the most technology agnostic approach for passing data between requests and allows for the ensuing request to use whatever means necessary (a servlet filter, phase listener, etc) to capture the conversation id and restore the long-running conversation.
Constructor and Description |
---|
ConversationAwareViewHandler(javax.faces.application.ViewHandler delegate) |
Modifier and Type | Method and Description |
---|---|
String |
getActionURL(javax.faces.context.FacesContext facesContext,
String viewId)
Allow the delegate to produce the action URL.
|
String |
getBookmarkableURL(javax.faces.context.FacesContext context,
String viewId,
Map<String,List<String>> parameters,
boolean includeViewParams) |
String |
getRedirectURL(javax.faces.context.FacesContext context,
String viewId,
Map<String,List<String>> parameters,
boolean includeViewParams) |
String |
getResourceURL(javax.faces.context.FacesContext context,
String path) |
javax.faces.application.ViewHandler |
getWrapped() |
public ConversationAwareViewHandler(javax.faces.application.ViewHandler delegate)
public String getActionURL(javax.faces.context.FacesContext facesContext, String viewId)
getActionURL
in class javax.faces.application.ViewHandlerWrapper
ViewHandler#getActionURL(FacesContext, String)}
public String getBookmarkableURL(javax.faces.context.FacesContext context, String viewId, Map<String,List<String>> parameters, boolean includeViewParams)
getBookmarkableURL
in class javax.faces.application.ViewHandlerWrapper
public String getRedirectURL(javax.faces.context.FacesContext context, String viewId, Map<String,List<String>> parameters, boolean includeViewParams)
getRedirectURL
in class javax.faces.application.ViewHandlerWrapper
public String getResourceURL(javax.faces.context.FacesContext context, String path)
getResourceURL
in class javax.faces.application.ViewHandlerWrapper
public javax.faces.application.ViewHandler getWrapped()
getWrapped
in interface javax.faces.FacesWrapper<javax.faces.application.ViewHandler>
getWrapped
in class javax.faces.application.ViewHandlerWrapper
Copyright © 2016. All rights reserved.