<?xml version='1.0' encoding='UTF-8'?>
<section>
<sectioninfo>
<keywordset>
<keyword>rich:dataOrderedList</keyword>
<keyword>HtmlDataOrderedList</keyword>
<keyword>ordered list</keyword>
</keywordset>
</sectioninfo>
  
    <table>
      <title>Component identification parameters </title>
      <tgroup cols="2">
        <thead>
          <row>
            <entry>Name</entry>
            <entry>Value</entry>
          </row>
        </thead>
        <tbody>
          <row>
            <entry>component-type</entry>
            <entry>org.richfaces.DataOrderedList</entry>
          </row>
          <row>
            <entry>component-class</entry>
            <entry>org.richfaces.component.html.HtmlDataOrderedList</entry>
          </row>
          <row>
          <entry>component-family</entry>
          <entry>org.richfaces.DataOrderedList</entry>
          </row>
          <row>
          <entry>renderer-type</entry>
          <entry>org.richfaces.DataOrderedListRenderer</entry>
          </row>          
          <row>
            <entry>tag-class</entry>
            <entry>org.richfaces.taglib.DataOrderedListTag</entry>
          </row>
        </tbody>
      </tgroup>
    </table>
  
  <section>
    <title>Creating the Component with a Page Tag</title>
    <para>To create the simplest variant of <property>dataOrderedList</property> on a page, use the following syntax:</para>

    <para>
      <emphasis role="bold">Example:</emphasis>
    </para>
    <programlisting role="XML"><![CDATA[...
    <rich:dataOrderedList value="#{bean.capitals}" var="caps">
        <h:outputText value="#{caps.name}"/>
    </rich:dataOrderedList>
...
]]></programlisting>
  </section>
  <section>
  <title>Creating the Component Dynamically Using Java</title>

    <para>
      <emphasis role="bold">Example:</emphasis>
    </para>
  <programlisting role="JAVA"><![CDATA[import org.richfaces.component.html.HtmlDataOrderedList; 
...  
HtmlDataOrderedList myList = new HtmlDataOrderedList();
...
]]></programlisting>
</section>
<section>
<title>Details of Usage</title>
<para>The component takes a list from a model and outputs it as an ordered list. The component also has 
similar to ordinary UIData components output ways:</para>
<itemizedlist>
<listitem>Header and footer output</listitem>
<listitem>Limitation of the output elements (the  <emphasis ><property>&quot;elements&quot;</property></emphasis> attribute) and definition of the first
 element</listitem>
 <listitem>Binding to scrolling components of list pages</listitem>
 </itemizedlist>
 <para>The component has the <emphasis ><property>&quot;type&quot;</property></emphasis> attribute corresponding to the <emphasis><property>&quot;ul&quot;</property></emphasis> HTML element.</para>
 <para>The component is created basing on the <emphasis role="bold"><property>&lt;a4j:repeat&gt;</property></emphasis> component and as a result the component could
  be partially updated with AJAX.</para>

    <para>
      <emphasis role="bold">Example:</emphasis>
    </para>
  <programlisting role="XML"><![CDATA[...
    <rich:dataOrderedList value="#{bean.capitals}" var="caps" ajaxKeys="#{listBean.list}" 
                        binding="#{listBean.dataList}" id="list">
        <h:outputText value="#{caps.name}"/>
    </rich:dataOrderedList>
...
    <a4j:commandButton action"#{listBean.action}" reRender="list" value="Submit">
...
]]></programlisting>
<para>Here during the action is processed the ajaxKeys set is composed into a list and then update
 specified for the whole table actually happens only for the chosen set of rows.</para>
 </section>
 <section>
 <title>Look-and-Feel Customization</title>
   <para>For skinnability implementation the components use a <emphasis 
><property>style class redefinition method</property></emphasis>.</para>
    <para>Default style classes are mapped on <emphasis 
><property>skin parameters</property>.</emphasis></para>
	<para>To redefine appearance of all dataOrderedLists at once, there are two ways:</para>
        <itemizedlist>
        <listitem>to redefine corresponding skin parameters</listitem>
        <listitem>to add <emphasis 
          ><property>style classes</property></emphasis> used by the dataOrderedList to your page style sheets</listitem>
         </itemizedlist>
 
    </section>
		 <section>
		   <title>Definition of Custom Style Classes</title>
		   
		   <para>On the screenshot there are classes names that define styles for component elements.</para>
		   
		   <figure>
		     <title>Style classes</title>
		     <mediaobject> 
		       <imageobject>
		         <imagedata fileref="images/dataorderedlist2.png"/>
		       </imageobject>
		     </mediaobject>
		   </figure>
		   
		   <table>
		     <title>Classes names that define a list appearance</title>
		     <tgroup cols="2">
		       <thead>
		         <row>
		           <entry>Class name</entry>
		           <entry>Description</entry>
		         </row>
		       </thead>
		       <tbody>
		         <row>
		           <entry>rich-orderedlist</entry>
		           <entry>Defines styles for an html &lt;ol&gt; element</entry>
		         </row>
		         <row>
		           <entry>rich-list-item</entry>
		           <entry>Defines styles for an html &lt;li&gt; element</entry>
		         </row>
		       </tbody>
		     </tgroup>
		   </table>
    
		   <para>In order to redefine styles for all <emphasis role="bold">
		     <property>&lt;rich:dataOrderedList&gt;</property>
		   </emphasis> components on a page using CSS, it&apos;s enough to create classes with the
		     same names and define necessary properties in them.</para>
		   
		   <para>To change styles of particular <emphasis role="bold">
		     <property>&lt;rich:dataOrderedList&gt;</property>
		   </emphasis> components, define your own style classes in the corresponding <emphasis
		     role="bold">
		     <property>&lt;rich:dataOrderedList&gt;</property>
		   </emphasis>attributes.</para>
           </section>
  <section>
    <title>Relevant Resources Links</title>
    <para><ulink url="http://livedemo.exadel.com/richfaces-demo/richfaces/dataLists.jsf?c=dataOrderedList"
      >Here</ulink> you can see the example of <emphasis role="bold"
        ><property>&lt;rich:dataOrderedList &gt;</property></emphasis> usage and sources for the given example. </para>
  </section>                     
</section>
  