You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@myfaces.apache.org by sk...@apache.org on 2008/02/07 11:43:00 UTC
svn commit: r619353 -
/myfaces/orchestra/trunk/core/src/main/java/org/apache/myfaces/orchestra/lib/jsf/OrchestraFacesContextFactory.java
Author: skitching
Date: Thu Feb 7 02:43:00 2008
New Revision: 619353
URL: http://svn.apache.org/viewvc?rev=619353&view=rev
Log:
Add a few docs
Modified:
myfaces/orchestra/trunk/core/src/main/java/org/apache/myfaces/orchestra/lib/jsf/OrchestraFacesContextFactory.java
Modified: myfaces/orchestra/trunk/core/src/main/java/org/apache/myfaces/orchestra/lib/jsf/OrchestraFacesContextFactory.java
URL: http://svn.apache.org/viewvc/myfaces/orchestra/trunk/core/src/main/java/org/apache/myfaces/orchestra/lib/jsf/OrchestraFacesContextFactory.java?rev=619353&r1=619352&r2=619353&view=diff
==============================================================================
--- myfaces/orchestra/trunk/core/src/main/java/org/apache/myfaces/orchestra/lib/jsf/OrchestraFacesContextFactory.java (original)
+++ myfaces/orchestra/trunk/core/src/main/java/org/apache/myfaces/orchestra/lib/jsf/OrchestraFacesContextFactory.java Thu Feb 7 02:43:00 2008
@@ -27,7 +27,20 @@
import javax.faces.lifecycle.Lifecycle;
/**
- * setup some aspects of the Orchestra framework
+ * Setup some aspects of the Orchestra framework whenever a JSF request is being processed.
+ * <p>
+ * The Orchestra jarfile contains a faces-config.xml file that is automatically loaded by
+ * the FacesServlet. It defines this class as the factory that servlet uses to create a
+ * FacesContext object for each request.
+ * <p>
+ * That factory method is used here as a convenient point to initialise any per-request
+ * Orchestra data-structures.
+ * <p>
+ * This factory fetches the actual FacesContext object from the previous factory in the
+ * chain, then decorates the returned FacesContext object; this means that this class
+ * integrates fine with other libraries that also configure a custom FacesContextFactory.
+ *
+ * @since 1.1
*/
public class OrchestraFacesContextFactory extends FacesContextFactory
{
@@ -49,7 +62,7 @@
String conversationMessager = facesContext.getExternalContext().getInitParameter(INIT_CONVERSATION_MESSAGER);
FrameworkAdapter.setCurrentInstance(new JsfFrameworkAdapter(conversationMessager));
- FacesContext wrappedFaccesContext = new FacesContextWrapper(facesContext)
+ FacesContext wrappedFacesContext = new FacesContextWrapper(facesContext)
{
public void release()
{
@@ -59,7 +72,7 @@
}
};
- facesContext = wrappedFaccesContext;
+ facesContext = wrappedFacesContext;
}
return facesContext;