javax.faces.lifecycle
Interface ViewHandler


public interface ViewHandler

ViewHandler is an interface defining a mechanism by which the Render Response phase of the request processing lifecycle can use a pluggable mechanism to support different response generation technologies. JSF implementations, or JSF-based applications, can register an instance of this interface by calling the setViewHandler() method of the Lifecycle instance used to process incoming requests, prior to receiving the first request.

A default implementation of ViewHandler must be provided by the JSF implementation, which will be utilized unless setViewHandler() is called to establish a different one. This default instance will treat the treeId property of the response component tree as a context-relative path (after prefixing it with a slash), and will perform a RequestDispatcher.forward() call to that path.


Method Summary
 void renderView(FacesContext context)
          Perform whatever actions are required to render the response component tree to the ServletResponse associated with the specified FacesContext.
 

Method Detail

renderView

public void renderView(FacesContext context)
                throws java.io.IOException,
                       FacesException

Perform whatever actions are required to render the response component tree to the ServletResponse associated with the specified FacesContext.

Parameters:
context - FacesContext for the current request
Throws:
java.io.IOException - if an input/output error occurs
java.lang.NullPointerException - if context is null
FacesException - if a servlet error occurs