[portal-commits] JBoss Portal SVN: r8990 - docs/branches/JBoss_Portal_Branch_2_6/referenceGuide/en/modules.

portal-commits at lists.jboss.org portal-commits at lists.jboss.org
Sat Nov 17 10:37:56 EST 2007


Author: wesleyhales
Date: 2007-11-17 10:37:56 -0500 (Sat, 17 Nov 2007)
New Revision: 8990

Modified:
   docs/branches/JBoss_Portal_Branch_2_6/referenceGuide/en/modules/tutorials.xml
Log:
Initial Richfaces documentation

Modified: docs/branches/JBoss_Portal_Branch_2_6/referenceGuide/en/modules/tutorials.xml
===================================================================
--- docs/branches/JBoss_Portal_Branch_2_6/referenceGuide/en/modules/tutorials.xml	2007-11-17 14:02:15 UTC (rev 8989)
+++ docs/branches/JBoss_Portal_Branch_2_6/referenceGuide/en/modules/tutorials.xml	2007-11-17 15:37:56 UTC (rev 8990)
@@ -82,6 +82,39 @@
          using our <ulink url="http://jboss.org/index.html?module=bb&amp;op=viewforum&amp;f=215">JBoss Portal User
          Forums</ulink> for user-to-user help, when needed.
       </para>
+      <!--<sect2 id="build_instructions">
+         <title>
+            Building and deploying the tutorials
+         </title>
+         <sect3>
+            <title id="ant_build">Ant based tutorials</title>
+              <para>
+                 For projects that are Ant based you can execute the build.xml with ant or inside your IDE.
+                  Executing <literal>ant</literal> will compile all source files and produce a
+                  artifact file auch as a .war.
+                 <sbr/>
+                 Before you run your first tutorial build, you must download <ulink url="http://ant.apache.org/bindownload.cgi">Apache Ant</ulink>
+                 and add it to your classpath.
+            </para>
+            <para>
+               The <literal>explode</literal> target will produce the following:
+
+            </para>
+            <para>
+               Deploying the portlet is as easy as copying/moving the <literal>helloworldjspportlet.war</literal> file
+               to the server <literal>deploy</literal> directory. We can then see our portlet on the Portal default
+               page (<ulink url="http://localhost:8080/portal/">http://localhost:8080/portal/</ulink>):
+
+            </para>
+         </sect3>
+         <sect3>
+            <title id="maven_build">Maven based tutorials</title>
+            <para>
+
+            </para>
+         </sect3>
+      </sect2>-->
+
       <sect2>
          <title>Deploying your first portlet</title>
          <sect3>
@@ -890,6 +923,51 @@
             </para>
          </sect3>
       </sect2>
+      <!--<sect2 id="sunri_42x_301">
+         <title>Portal and JSF RI: A basic demonstration using common components</title>
+         <sect3>
+            <para>JSF portlets are now possible using the MyFaces 301 implementation of the JSR-301 specification.
+               This does NOT mean that you are using the MyFaces implementation of JSF, it only means that you are
+               using the 301 bridge implementation (which was initially donated by Oracle). The 301 spec or bridge is
+               a subsystem that allows a JavaServer Faces resource to execute and satisfy a portlet request. You can
+               read more about the specification details <ulink url="http://jcp.org/en/jsr/detail?id=301">here</ulink>.
+            </para>
+         </sect3>
+         <sect3>
+            <title>Downloading The Project Source</title>
+            <para>
+               You have 2 options for getting started.
+               <sbr/>
+               1) Download the binary distribution in a zip file. This will
+               include all the source files along with a deployable war file.
+               <sbr/>
+               2) Use subversion to checkout the source
+               code. If you plan on making changes to the source or possibly using it as a template for future development,
+               it is recommended that you checkout the project and use maven to build the war.
+               <para>
+                  For instructions on setting up Subversion and/or Maven 2 see <xref linkend="first_portlet_descriptors"/>
+               </para>
+               <itemizedlist>
+                  <listitem>
+                     <para>
+                        You can download all the project files in one zip file here:
+                        <sbr/>
+                        <ulink url="http://anonsvn.jboss.org/repos/portletswap/portlets/2_6/bundles/JSFRIPortlet.zip">http://anonsvn.jboss.org/repos/portletswap/portlets/2_6/bundles/JSFRIPortlet.zip</ulink>.
+                        <sbr/>
+                        Once you extract the zip archive, the deployable war file is located in the target/ directory.
+                     </para>
+                  </listitem>
+                  <listitem>
+                     <para>
+                      The source code:
+                        <sbr/>
+                        <ulink url="http://anonsvn.jboss.org/repos/portletswap/portlets/src/framework/JSFRIPortlet/">http://anonsvn.jboss.org/repos/portletswap/portlets/src/framework/JSFRIPortlet/</ulink>.
+                     </para>
+                  </listitem>
+               </itemizedlist>
+            </para>
+         </sect3>
+      </sect2>-->
       <sect2 id="myfaces_40x">
          <title>A simple MyFaces JSF Portlet on JBoss AS 4.0.5+</title>
          <sect3>
@@ -1071,5 +1149,140 @@
             </mediaobject>
          </para>
       </sect2>
+      <sect2 id="richfaces">
+         <title>Portal and RichFaces: A basic demonstration using Ajax4JSF and RichFaces components</title>
+         <sect3>
+            <para>
+               RichFaces is currently in technology preview mode and not fully supported in Jboss Portal.
+            </para>
+         </sect3>
+         <sect3>
+            <title>Downloading The Binaries or Project Source</title>
+            <para>
+               You have 2 options for getting started.
+               <!--<para>
+                  For instructions on setting up Subversion and/or Maven 2 see <xref linkend="build_instructions"/>
+               </para>-->
+               <itemizedlist>
+                  <listitem>
+                     <para>
+                        1) Download the binary distribution in a zip file. This will
+                        include all the source files along with a deployable war file.
+                        <sbr/>
+                        <ulink url="http://anonsvn.jboss.org/repos/portletswap/portlets/2_6/bundles/RichFacesPortlet.zip">http://anonsvn.jboss.org/repos/portletswap/portlets/2_6/bundles/RichFacesPortlet.zip</ulink>.
+                        <sbr/>
+                        Once you extract the zip archive, the deployable war file is located in the target/ directory.
+                     </para>
+                  </listitem>
+                  <listitem>
+                     <para>
+                        2) Use subversion to checkout the source code.
+                        If you plan on making changes to the source or possibly using it as a template for future development,
+                        it is recommended that you checkout the project and use maven to build the war.
+                        <sbr/>
+                        <ulink url="http://anonsvn.jboss.org/repos/portletswap/portlets/src/framework/RichFacesPortlet/">http://anonsvn.jboss.org/repos/portletswap/portlets/src/framework/RichFacesPortlet/</ulink>.
+                     </para>
+                  </listitem>
+               </itemizedlist>
+            </para>
+         </sect3>
+         <sect3>
+            <title>Project Configuration</title>
+            <para>
+               The following configurations must be made to use RichFaces in your portlet.
+            </para>
+             <para>
+                Here we use javax.portlet.faces.GenericFacesPortlet which is part of the JSR-301 specification. We also
+                must declare the view, edit, and help modes as shown below.
+                <itemizedlist>
+                  <listitem>
+                      <literal>portlet.xml</literal>
+<programlisting>
+   <![CDATA[<portlet-app version="1.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+           xsi:schemaLocation="http://java.sun.com/xml/ns/portlet"
+           xmlns="http://java.sun.com/xml/ns/portlet">
+           <portlet>
+             <portlet-name>ajaxPortlet</portlet-name>
+             <portlet-class>
+               javax.portlet.faces.GenericFacesPortlet
+             </portlet-class>
+
+              <init-param>
+                 <name>javax.portlet.faces.defaultViewId.view</name>
+                 <value>/jsf/start.xhtml</value>
+               </init-param>
+
+                 <init-param>
+                  <name>javax.portlet.faces.defaultViewId.edit</name>
+                 <value>/jsf/edit.xhtml</value>
+                </init-param>
+
+                <init-param>
+                  <name>javax.portlet.faces.defaultViewId.help</name>
+                  <value>/jsf/help.xhtml</value>
+                </init-param>
+
+             <expiration-cache>-0</expiration-cache>
+             <portlet-info>
+                <title>Ajax Portlet</title>
+             </portlet-info>
+             <supports>
+               <mime-type>text/html</mime-type>
+               <portlet-mode>VIEW</portlet-mode>
+               <portlet-mode>EDIT</portlet-mode>
+               <portlet-mode>HELP</portlet-mode>
+             </supports>
+           </portlet>
+         </portlet-app>]]>
+</programlisting>
+                     </listitem>
+                     <listitem>
+                      <literal>faces-config.xml</literal>
+<programlisting>
+   <![CDATA[...
+         <application>
+            <view-handler>
+               org.ajax4jsf.portlet.application.PortletViewHandler
+            </view-handler>
+            <state-manager>
+               org.ajax4jsf.portlet.application.PortalStateManager
+            </state-manager>
+         </application>
+         <factory>
+            <faces-context-factory>
+               org.ajax4jsf.portlet.context.FacesContextFactoryImpl
+            </faces-context-factory>
+         </factory>
+         ...]]>
+</programlisting>
+                     </listitem>
+                     <listitem>
+                      <literal>web.xml</literal>
+<programlisting>
+   <![CDATA[...
+         <context-param>
+            <param-name>org.ajax4jsf.VIEW_HANDLERS</param-name>
+            <param-value>org.ajax4jsf.portlet.application.FaceletPortletViewHandler</param-value>
+         </context-param>
+         <filter>
+            <display-name>Ajax4jsf Filter</display-name>
+            <filter-name>ajax4jsf</filter-name>
+            <filter-class>org.ajax4jsf.Filter</filter-class>
+         </filter>
+
+         <filter-mapping>
+            <filter-name>ajax4jsf</filter-name>
+            <servlet-name>FacesServlet</servlet-name>
+            <dispatcher>FORWARD</dispatcher>
+            <dispatcher>REQUEST</dispatcher>
+            <dispatcher>INCLUDE</dispatcher>
+         </filter-mapping>
+         ...]]>
+</programlisting>
+                     </listitem>
+                  </itemizedlist>
+            </para>
+         </sect3>
+      </sect2>
    </sect1>
 </chapter>
\ No newline at end of file




More information about the portal-commits mailing list