org.apache.myfaces.orchestra.lib.jsf
Class _PortletFacesContextWrapper

java.lang.Object
  extended by FacesContext
      extended by org.apache.myfaces.orchestra.lib.jsf._PortletFacesContextWrapper

public class _PortletFacesContextWrapper
extends FacesContext

Convenient class to wrap the current FacesContext in portlet environment.

Since:
1.4
Version:
$Revision: 798382 $ $Date: 2009-07-27 22:23:02 -0500 (lun, 27 jul 2009) $
Author:
Leonardo Uribe (latest modification by $Author: lu4242 $)

Constructor Summary
_PortletFacesContextWrapper(FacesContext facesContext, boolean install, boolean finit, java.lang.String fnextToken, java.util.List fhandlers, RequestHandler fcontextLockHandler)
          The install parameter controls whether this object will be configured as the object returned from calls to FacesContext.getCurrentInstance() or not.
 
Method Summary
 void addMessage(java.lang.String clientId, FacesMessage message)
           
 Application getApplication()
           
 java.util.Iterator getClientIdsWithMessages()
           
 ELContext getELContext()
           
 ExternalContext getExternalContext()
           
 FacesMessage.Severity getMaximumSeverity()
           
 java.util.Iterator getMessages()
           
 java.util.Iterator getMessages(java.lang.String clientId)
           
 RenderKit getRenderKit()
           
 boolean getRenderResponse()
           
 boolean getResponseComplete()
           
 ResponseStream getResponseStream()
           
 ResponseWriter getResponseWriter()
           
 UIViewRoot getViewRoot()
           
 void release()
           
 void renderResponse()
           
 void responseComplete()
           
 void setResponseStream(ResponseStream responsestream)
           
 void setResponseWriter(ResponseWriter responsewriter)
           
 void setViewRoot(UIViewRoot viewRoot)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

_PortletFacesContextWrapper

public _PortletFacesContextWrapper(FacesContext facesContext,
                                   boolean install,
                                   boolean finit,
                                   java.lang.String fnextToken,
                                   java.util.List fhandlers,
                                   RequestHandler fcontextLockHandler)
The install parameter controls whether this object will be configured as the object returned from calls to FacesContext.getCurrentInstance() or not.

When only overriding the release() method, then install=false is ok as that is called directly by the FacesServlet on the instance returned by the FacesContextFactory. However all other methods are invoked on the object that is returned from FacesContext.getCurrentInstance, so install=true is needed in order for any other method overrides to have any effect.

IMPORTANT: install=true should not be used until MYFACES-1820 is fixed.

Method Detail

release

public void release()

getApplication

public final Application getApplication()

getClientIdsWithMessages

public final java.util.Iterator getClientIdsWithMessages()

getExternalContext

public ExternalContext getExternalContext()

getMaximumSeverity

public final FacesMessage.Severity getMaximumSeverity()

getMessages

public final java.util.Iterator getMessages()

getMessages

public final java.util.Iterator getMessages(java.lang.String clientId)

getRenderKit

public final RenderKit getRenderKit()

getRenderResponse

public final boolean getRenderResponse()

getResponseComplete

public final boolean getResponseComplete()

setResponseStream

public final void setResponseStream(ResponseStream responsestream)

getResponseStream

public final ResponseStream getResponseStream()

setResponseWriter

public final void setResponseWriter(ResponseWriter responsewriter)

getResponseWriter

public final ResponseWriter getResponseWriter()

setViewRoot

public final void setViewRoot(UIViewRoot viewRoot)

getViewRoot

public final UIViewRoot getViewRoot()

addMessage

public final void addMessage(java.lang.String clientId,
                             FacesMessage message)

renderResponse

public final void renderResponse()

responseComplete

public final void responseComplete()

getELContext

public final ELContext getELContext()


Copyright © 2009 The Apache Software Foundation. All Rights Reserved.