You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@myfaces.apache.org by mb...@apache.org on 2005/07/28 17:30:56 UTC

svn commit: r225802 - in /myfaces/forrest/trunk/content/xdocs: site.xml tomahawk/columns.xml

Author: mbr
Date: Thu Jul 28 08:30:52 2005
New Revision: 225802

URL: http://svn.apache.org/viewcvs?rev=225802&view=rev
Log:
doc for x:columns added

Added:
    myfaces/forrest/trunk/content/xdocs/tomahawk/columns.xml
Modified:
    myfaces/forrest/trunk/content/xdocs/site.xml

Modified: myfaces/forrest/trunk/content/xdocs/site.xml
URL: http://svn.apache.org/viewcvs/myfaces/forrest/trunk/content/xdocs/site.xml?rev=225802&r1=225801&r2=225802&view=diff
==============================================================================
--- myfaces/forrest/trunk/content/xdocs/site.xml (original)
+++ myfaces/forrest/trunk/content/xdocs/site.xml Thu Jul 28 08:30:52 2005
@@ -124,6 +124,7 @@
         <extDataTable label="Extended Data Table" href="extDataTable.html"/>
         <panelNavigation label="Panel Navigation" href="panelNavigation.html"/>
         <uiSaveState label="UI Save State" href="uiSaveState.html"/>
+        <columns label="Columns" href="columns.html"/>
     </components>
     
     <validators href="tomahawk/" label="Validators" tab="tomahawk">

Added: myfaces/forrest/trunk/content/xdocs/tomahawk/columns.xml
URL: http://svn.apache.org/viewcvs/myfaces/forrest/trunk/content/xdocs/tomahawk/columns.xml?rev=225802&view=auto
==============================================================================
--- myfaces/forrest/trunk/content/xdocs/tomahawk/columns.xml (added)
+++ myfaces/forrest/trunk/content/xdocs/tomahawk/columns.xml Thu Jul 28 08:30:52 2005
@@ -0,0 +1,95 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE document PUBLIC "-//APACHE//DTD Documentation V1.2//EN" "document-v12.dtd">
+
+<!--
+This is a standard template meant to be used for the documentation of all custom
+components.
+-->
+<document>
+    <!-- component name -->
+    <header>
+        <title>Columns</title>
+        <subtitle>&lt;x:columns/&gt;</subtitle>
+    </header>
+    <body>
+        <!-- Description -->
+        <section>
+            <title>Description</title>
+            <p>The tag allows dynamic columns in a datatable.</p>
+            <p>
+            	The UIColumns component is used below a x:datatable to create a dynamic count
+            	of columns. It is used like a UIData component which iterates through a datamodel
+            	to create the columns.
+            </p>
+        </section>
+        <!-- screen shot -->
+        <section>
+            <title>Screen Shot</title>
+            <p>Not Available</p> <!-- replace with either a figure or Not Available -->
+            <!--
+            <figure src="jscookmenu.png" alt="jscookmenu"/>
+            -->
+        </section>
+        <!-- API -->
+        <section>
+            <title>API</title>
+            <table>
+                <tr>
+                    <td>component-family</td>
+                    <td>javax.faces.Data</td>
+                </tr>
+                <tr>
+                    <td>renderer-type</td>
+                    <td>-</td>
+                </tr>
+                <tr>
+                    <td>component-class</td>
+                    <td>org.apache.myfaces.custom.crosstable.UIColumns</td>
+                </tr>
+                <tr>
+                    <td>renderer-class</td>
+                    <td>-</td>
+                </tr>
+                <tr>
+                    <td>tag-class</td>
+                    <td>org.apache.myfaces.custom.crosstable.HtmlColumnsTag</td>
+                </tr>
+            </table>
+        </section>
+        <!-- Usage -->
+        <section>
+            <title>Usage</title>
+            <source>
+&lt;x:datatable value="#{rows}" var="row"&gt;
+    &lt;x:columns value="#{cols}" var="column"&gt;
+        &lt;f:facet name="header" value="#{column.name}"/&gt;
+        &lt;h:outputText value="#{row.columnValue}"/&gt;
+    &lt;/x:columns&gt;
+&lt;/x:datatable&gt;
+            </source>
+        </section>
+        <!-- Syntax -->
+        <section>
+            <title>Syntax</title>
+            <note label="&lt;x:columns/&gt;">
+                <code>value - A DataModel, List, Array or a scalar value. 
+                	Everthing which is accepted for the value attribute of the datatable</code><br/>
+                <code>
+                    var - a variable which can be used to access the current column in the iteration.
+                </code>
+                <br/>
+            </note>
+        </section>
+        <!-- Instructions -->
+        <section>
+            <title>Instructions</title>
+            <p>see examples/openDataTable.jsp for an example!</p>
+        </section>
+    </body>
+    <footer>
+        <legal>Java, J2EE, and JCP are trademarks or registered trademarks of Sun Microsystems, Inc. in the United States and other countries.
+            <br/>
+            &copy; 2004 - 2005, Apache Software Foundation
+        </legal>
+    </footer>
+</document>