Java Doc for TableRowGroupBase.java in  » IDE-Netbeans » visualweb.api.designer » com » sun » rave » web » ui » component » Java Source Code / Java DocumentationJava Source Code and Java Documentation

Java Source Code / Java Documentation
1. 6.0 JDK Core
2. 6.0 JDK Modules
3. 6.0 JDK Modules com.sun
4. 6.0 JDK Modules com.sun.java
5. 6.0 JDK Modules sun
6. 6.0 JDK Platform
7. Ajax
8. Apache Harmony Java SE
9. Aspect oriented
10. Authentication Authorization
11. Blogger System
12. Build
13. Byte Code
14. Cache
15. Chart
16. Chat
17. Code Analyzer
18. Collaboration
19. Content Management System
20. Database Client
21. Database DBMS
22. Database JDBC Connection Pool
23. Database ORM
24. Development
25. EJB Server geronimo
26. EJB Server GlassFish
27. EJB Server JBoss 4.2.1
28. EJB Server resin 3.1.5
29. ERP CRM Financial
30. ESB
31. Forum
32. GIS
33. Graphic Library
34. Groupware
35. HTML Parser
36. IDE
37. IDE Eclipse
38. IDE Netbeans
39. Installer
40. Internationalization Localization
41. Inversion of Control
42. Issue Tracking
43. J2EE
44. JBoss
45. JMS
46. JMX
47. Library
48. Mail Clients
49. Net
50. Parser
51. PDF
52. Portal
53. Profiler
54. Project Management
55. Report
56. RSS RDF
57. Rule Engine
58. Science
59. Scripting
60. Search Engine
61. Security
62. Sevlet Container
63. Source Control
64. Swing Library
65. Template Engine
66. Test Coverage
67. Testing
68. UML
69. Web Crawler
70. Web Framework
71. Web Mail
72. Web Server
73. Web Services
74. Web Services apache cxf 2.0.1
75. Web Services AXIS2
76. Wiki Engine
77. Workflow Engines
78. XML
79. XML UI
Java
Java Tutorial
Java Open Source
Jar File Download
Java Articles
Java Products
Java by API
Photoshop Tutorials
Maya Tutorials
Flash Tutorials
3ds-Max Tutorials
Illustrator Tutorials
GIMP Tutorials
C# / C Sharp
C# / CSharp Tutorial
C# / CSharp Open Source
ASP.Net
ASP.NET Tutorial
JavaScript DHTML
JavaScript Tutorial
JavaScript Reference
HTML / CSS
HTML CSS Reference
C / ANSI-C
C Tutorial
C++
C++ Tutorial
Ruby
PHP
Python
Python Tutorial
Python Open Source
SQL Server / T-SQL
SQL Server / T-SQL Tutorial
Oracle PL / SQL
Oracle PL/SQL Tutorial
PostgreSQL
SQL / MySQL
MySQL Tutorial
VB.Net
VB.Net Tutorial
Flash / Flex / ActionScript
VBA / Excel / Access / Word
XML
XML Tutorial
Microsoft Office PowerPoint 2007 Tutorial
Microsoft Office Excel 2007 Tutorial
Microsoft Office Word 2007 Tutorial
Java Source Code / Java Documentation » IDE Netbeans » visualweb.api.designer » com.sun.rave.web.ui.component 
Source Cross Reference  Class Diagram Java Document (Java Doc) 


com.sun.rave.web.ui.component.TableRowGroupBase

All known Subclasses:   com.sun.rave.web.ui.component.TableRowGroup,
TableRowGroupBase
abstract public class TableRowGroupBase extends javax.faces.component.UIComponentBase (Code)
Use the ui:tableRowGroup tag to define the rows of a table, inside a ui:table tag.  A table must include at least one tableRowGroup component to contain the table row content.

The ui:table tag is used to define the structure and actions of the table, and is a container for ui:tableRowGroup tags.  The ui:tableRowGroup tag is a container for ui:tableColumn tags, which are used to define the columns of the table.  The documentation for the ui:table tag contains detailed information about the table component.  This page provides details about how to create table rows only.

When you use one ui:tableRowGroup tag in the ui:table tag, you create a basic table.  Examples of basic tables are shown in the ui:table tag documentation. When you use multiple ui:tableRowGroup tags, you create a group table, which is discussed in detail in this document.

HTML Elements and Layout

The tableRowGroup component is used to define attributes for XHTML <tr>   elements, which are used to display rows of data. You can specify multiple ui:tableRowGroup tags to create groups of rows. Each group is visually separate from the other groups, but all rows of the table can be sorted and filtered at once, within their respective groups.

UI guidelines recommend that column headers and table column footers are only rendered once for each table. Column headers typically appear at the top of the table, below the Action Bar and above all row groups. Table column footers appear only at the bottom of the table, below all row groups. The column headers and table column footers are defined in the headerText and tableFooterText attributes of the ui:tableColumn tags. To ensure that these headers and footers are rendered only once, you should define the  headerText and tableFooterText attributes only in the ui:tableColumn tags inside the first ui:tableRowGroup tag in the table.  See the
ui:tableColumn documentation for more information.

The following diagram shows the placement of the areas of a table, and highlights the areas that are defined with ui:tableRowGroup tags. This diagram depicts two row groups.



Title Bar 
Action Bar (top)  
Column Header
Column Header
Group Header Bar (specified with headerText attribute and header facet in first ui:tableRowGroup tag)
Table data specified in ui:tableRowGroup



Table data specified in ui:tableRowGroup
Column Footer Column Footer
Group Footer Bar 
Group Header Bar
Table data specified in ui:tableRowGroup




Table data specified in ui:tableRowGroup
Column Footer
Column Footer
Group Footer Bar
Table Column Footer Table Column Footer
Action Bar (bottom) 
Footer

Group Header Bar

The Group Header Bar displays a header by default at the top of each group of rows.  The text of the group header is specified with the headerText attribute. You can specify a separate component to provide header content by using the header facet, which overrides the headerText attribute.  You can use the following ui:tableRowGroup attributes to change the appearance of the group header:
  • aboveColumnHeader set to true makes the group header display above the column header.

  • selectMultipleToggleButton set to true adds a checkbox that allows users to select and deselect all rows in the group

  • collapsed set to true causes the group to be rendered with the rows hidden, and only the group header is visible. 

  • groupToggleButton set to true adds a button image that allows users to expand and collapse the group of rows. When the group collapses, all the rows are hidden and only the header is visible.

  • extraHeaderHtml can be used to append HTML code to the <tr> element that is rendered for the group header

Note: Detailed descriptions of the attributes are in the attributes table at the end of this document.

Group Footer Bar

The Group Footer Bar displays an optional footer below each group of rows. The text of the group footer is specified with the footerText attribute. You can specify a separate component to provide the footer content by using the footer facet, which overrides the footerText attribute.  You can use the following ui:tableRowGroup attributes to change the appearance of the group footer:

  • aboveColumnFooter set to true makes the group footer display above the column footer.
  •  extraFooterHtml can be used to append HTML code to the <tr> element that is rendered for the group footer

Table Data

The table data is specified with the sourceData and sourceVar attributes. The sourceData attribute specifies the source of the data that populates the table. The sourceVar attribute specifies the name of the request-scope variable to use for exposing the model data when iterating over table rows. Each table in a JSP page must use a unique sourceVar value. See the Life Cycle section for more information about these attributes.   

Facets

The ui:tableRowGroup tag supports the following facets, which allow you to customize the layout  of the component.

Facet Name
Table Item Implemented by the Facet
footer         
Footer that applies to the group of rows defined by the ui:tableRowGroup tag.  This facet can be used to  replace the default footer.
header Header that applies to the group of rows defined by the ui:tableRowGroup tag. This facet can be used to replace the default header.

Client Side JavaScript Functions

See the ui:table tag's JavaScript documentation.  The same functions are used for the ui:tableRowGroup tag.

Notes for the ui:tableRowGroup tag

All examples assume that the ui:table tag is contained within a HTML <form> element so actions can submit form data. For basic table and sort examples, see the ui:table tag documentation and ui:tableColumn documentation.

Life Cycle

The sourceData property of tableRowGroup is invoked at least twice during the JavaServer Faces life cycle. The sourceData is invoked once during one of the Apply Request Values, Process Validations, or Update Model Values phases, and once during the Render Response phase. In order to process the previously displayed children during the Apply Request Values, Process Validations, or Update Model Values phases, the table must use the same DataProvider that was used to render the previous page. For example, suppose that sorting, filtering, and pagination were applied on the previous page, and rows 10-20 of 1000 were currently displayed. You want to update only the currently displayed components, rows 10-20. To do this, you must not update the DataProvider until the Invoke Application phase or Render Response phases, when it is safe to render new data.

Note that if the underlying DataProvider has changed in any way, processing of the previously displayed children might not be possible during the Apply Request Values, Process Validations, or Update Model Values phases. In addition, if the DataProvider is null or empty, no children will be processed and their processDecodes(), processValidators(), and processUpdates() methods will not be invoked. If a component has not been decoded (in the Apply Request Values phase), action events might not be received and component properties such as hyperlink query parameters cannot be retrieved.  Also, if a component has not been updated (in the Update Model Values phase), submitted values cannot be retrieved for checkboxes, radio buttons, etc.

When obtaining data is expensive, consider caching the DataProvider. A cached DataProvider persists across requests if the backing bean uses session scope, or if the application uses server-side state saving and the TableRowGroup.setSourceData method is set. Note that a phase listener may be used to initialize the DataProvider during the Invoke Application Phase. However, when the underlying DataProvider has changed in any way, UI guidelines recommend that pagination is reset to the first page. You can use the tableRowGroup component's setFirst() method to set the first row to be displayed.

Examples

The following examples use a backing bean called TableBean, which is shown in the ui:table tag documentation. Utility classes used in the examples are included in this ui:tableRowGroup page, after the examples.  Additional examples are shown in the ui:table and ui:tableColumn documents.

Examples in this file:

Supporting files:

Example 1: Group Table

This example shows how to create a group table. A group table contains rows of data that are arranged in discrete sections or groups within the table.  In a basic table, each column typically has a header and perhaps a footer. However, in a group table, each group of rows can have its own header and footer. In addition, a group table can display table column footers and an overall table footer below all data groups.  The table column footers are specified in ui:tableColumn tags and the overall footer is specified in the ui:table tag. See the diagram of the table areas.

Additional attributes should be used in the ui:tableColumn tags within each ui:tableRowGroup tag to specify functionality. For example, the selectId and sort  attributes allow column headers to sort on all row groups at once. 

The example uses the backing bean called TableBean for the table data. See the
TableBean backing bean in ui:table documentation.

Note: UI guidelines recommend that items should not remain selected when they cannot be seen by the user. Using the com.sun.rave.web.ui.event.TableSelectPhaseListener object ensures that rows that are hidden from view are deselected because the phase listener clears the table state after the rendering phase. Although pagination is not used for a group table, the TableSelectPhaseListener object is used in this example in the Select util, which is shown in Select.java in the ui:table documentation.  Also refer to the JavaDoc for TableSelectPhaseListener for more information. 

<!-- Group Table -->
<ui:table id="table1"
    clearSortButton="true"
    deselectMultipleButton="true"
    selectMultipleButton="true"
    sortPanelToggleButton="true"
    footerText="Table Footer">

  <!-- Title -->
  <f:facet name="title">
    <ui:staticText text="Group Table"/>
  </f:facet>

  <ui:tableRowGroup id="rowGroup1"
      binding="#{TableBean.groupB.tableRowGroup}"
      footerText="Group Footer"
      headerText="Group Header"
      selected="#{TableBean.groupB.select.selectedState}"
      selectMultipleToggleButton="true"
      sourceData="#{TableBean.groupB.names}"
      sourceVar="name"
      groupToggleButton="true">

    <ui:tableColumn id="col0"
        extraHeaderHtml="nowrap='nowrap'"
        extraFooterHtml="nowrap='nowrap'"
        extraTableFooterHtml="nowrap='nowrap'"
        footerText="ColFtr"
        selectId="select"
        sort="#{TableBean.groupB.select.selectedState}">
      <ui:checkbox id="select"
          onClick="setTimeout('initAllRows()', 0)"
          selected="#{TableBean.groupB.select.selected}"
          selectedValue="#{TableBean.groupB.select.selectedValue}"/>
    </ui:tableColumn>
    <ui:tableColumn id="col1"
        extraHeaderHtml="nowrap='nowrap'"
        alignKey="last"
        footerText="Column Footer"
        headerText="Last Name"
        rowHeader="true"
        sort="last">
      <ui:staticText text="#{name.value.last}"/>
    </ui:tableColumn>
    <ui:tableColumn id="col2"
        alignKey="first"
        footerText="Column Footer"
        headerText="First Name"
        sort="first">
      <ui:staticText text="#{name.value.first}"/>
    </ui:tableColumn>
  </ui:tableRowGroup>

  <ui:tableRowGroup id="rowGroup2"
      binding="#{TableBean.groupC.tableRowGroup}"
      collapsed="true"
      selected="#{TableBean.groupC.select.selectedState}"
      selectMultipleToggleButton="true"
      sourceData="#{TableBean.groupC.names}"
      sourceVar="name"
      groupToggleButton="true">

    <!-- Row group header -->
    <f:facet name="header">
      <ui:panelGroup id="groupHeader">
        <ui:markup tag="span" extraAttributes="class='TblGrpLft'">
          <ui:staticText styleClass="TblGrpTxt" text="Group Header"/>
        </ui:markup>
        <ui:markup tag="span" extraAttributes="class='TblGrpRt'">
          <ui:staticText styleClass="TblGrpMsgTxt" text="Right-Aligned Text"/>
        </ui:markup>
      </ui:panelGroup>
    </f:facet>

    <!-- Row group footer -->
    <f:facet name="footer">
      <ui:staticText styleClass="TblGrpFtrRowTxt" text="Group Footer"/>
    </f:facet>

    <ui:tableColumn id="col0"
        extraHeaderHtml="nowrap='nowrap'"
        extraFooterHtml="nowrap='nowrap'"
        extraTableFooterHtml="nowrap='nowrap'"
        footerText="ColFtr"
        selectId="select"
        sort="#{TableBean.groupC.select.selectedState}"
        tableFooterText="TblColFtr">
      <ui:checkbox id="select"
          onClick="setTimeout('initAllRows()', 0)"
          selected="#{TableBean.groupC.select.selected}"
          selectedValue="#{TableBean.groupC.select.selectedValue}"/>
    </ui:tableColumn>
    <ui:tableColumn id="col1"
        alignKey="last"
        footerText="Column Footer"
        rowHeader="true"
        sort="last"
        tableFooterText="Table Column Footer">
      <ui:staticText text="#{name.value.last}"/>
    </ui:tableColumn>
    <ui:tableColumn id="col2"
        alignKey="first"
        footerText="Column Footer"
        sort="first"
        tableFooterText="Table Column Footer">
      <ui:staticText text="#{name.value.first}"/>
    </ui:tableColumn>
  </ui:tableRowGroup>
</ui:table>


select.js

This example shows the contents of the select.js file used in the example above.

// Use this function to initialize all rows displayed in the table when the
// state of selected components change (i.e., checkboxes or radiobuttons used to
// de/select rows of the table). This functionality requires the selectId
// property of the tableColumn component to be set.
//
// Note: Use setTimeout when invoking this function. This will ensure that
// checkboxes and radiobutton are selected immediately, instead of waiting for
// the onClick event to complete. For example:
//
// onClick="setTimeout('initAllRows(); disableActions()', 0)"
function initAllRows() {
    // Disable table actions by default.
    var table = document.getElementById("form1:table1");
    table.initAllRows();
}

Example 2: Dynamic Table

This example shows how to use the ui:table tag to create a binding to a backing bean to dynamically create a table layout. The dynamic table is created as needed and can be changed each time the page is rendered.  

<ui:table id="table1" binding="#{DynamicTableBean.table}"/>


The backing bean, DynamicTableBean, is shown in the following DynamicTableBean.java class. This bean is used only to create the table layout, and shows how to use the tableRowGroup component directly through Java code instead of through the JSP tag  ui:tableRowGroup. The Dynamic.java utility class provides the functionality for adding properties to the table.  The table also uses methods that are defined in the TableBean shown in the ui:table documentation.

DynamicTableBean.java Backing Bean

package table;

import com.sun.rave.web.ui.component.Table;
import com.sun.rave.web.ui.component.TableRowGroup;

import table.util.Dynamic;

// Backing bean for dynamic table examples.
//
// Note: To simplify the example, this bean is used only to create the table
// layout. The resulting table will use methods already defined in TableBean.
public class DynamicTableBean {
    private Dynamic dynamic = null; // Dynamic util.
    private Table table = null; // Table component.

    // Default constructor.
    public DynamicTableBean() {
        dynamic = new Dynamic();
    }

    // Get Table component.
    public Table getTable() {
        if (table == null) {
            // Get table row group.
            TableRowGroup rowGroup1 = dynamic.getTableRowGroup("rowGroup1",
                "#{TableBean.groupB.names}",
                "#{TableBean.groupB.select.selectedState}", null);

            // Set table row group properties.
            dynamic.setTableRowGroupChildren(rowGroup1,
                "#{TableBean.groupB.select.selectedState}",
                "#{TableBean.groupB.select.selected}",
                "#{TableBean.groupB.select.selectedValue}",
                "#{TableBean.groupB.actions.action}", true);

            // Get table.
            table = dynamic.getTable("table1", "Dynamic Table");
            table.getChildren().add(rowGroup1);
        }
        return table;
    }

    // Set Table component.
    //
    // @param table The Table component.
    public void setTable(Table table) {
        this.table = table;
    }
}

Example 3: Dynamic Group Table

This example shows how to use the ui:table tag to create a binding to a backing bean to dynamically create a group table layout. The dynamic group table is created as needed and can be changed each time the page is rendered.

<ui:table id="table1" binding="#{DynamicGroupTableBean.table}"/>

The backing bean, DynamicGroupTableBean, is shown in the following DynamicGroupTableBean.java class. This bean is used only to create the table layout, and shows how to use the tableRowGroup component directly through Java code instead of through the JSP tag  ui:tableRowGroup. The Dynamic.java utility class provides the functionality for adding properties to the table.  The table also uses methods that are defined in the TableBean shown in the ui:table documentation.

DynamicGroupTableBean.java Backing Bean

package table;

import table.util.Dynamic;

import com.sun.rave.web.ui.component.StaticText;
import com.sun.rave.web.ui.component.Table;
import com.sun.rave.web.ui.component.TableRowGroup;

// Backing bean for dynamic group table examples.
//
// Note: To simplify the example, this bean is used only to create the table
// layout. The resulting table will use methods already defined in TableBean.
public class DynamicGroupTableBean {
    private Dynamic dynamic = null; // Dynamic util.
    private Table table = null; // Table component.

    // Default constructor.
    public DynamicGroupTableBean() {
        dynamic = new Dynamic();
    }

    // Get Table component.
    public Table getTable() {
        if (table == null) {
            // Get table row group.
            TableRowGroup rowGroup1 = dynamic.getTableRowGroup("rowGroup1",
                "#{TableBean.groupB.names}",
                "#{TableBean.groupB.select.selectedState}",
                "Group Header");
            TableRowGroup rowGroup2 = dynamic.getTableRowGroup("rowGroup2",
                "#{TableBean.groupC.names}",
                "#{TableBean.groupC.select.selectedState}",
                "Group Header");

            // Set table row group properties.
            dynamic.setTableRowGroupChildren(rowGroup1,
                "#{TableBean.groupB.select.selectedState}",
                "#{TableBean.groupB.select.selected}",
                "#{TableBean.groupB.select.selectedValue}", null, true);
            dynamic.setTableRowGroupChildren(rowGroup2,
                "#{TableBean.groupC.select.selectedState}",
                "#{TableBean.groupC.select.selected}",
                "#{TableBean.groupC.select.selectedValue}", null, false);

            // Set select and row group toggle buttons.
            rowGroup1.setSelectMultipleToggleButton(true);
            rowGroup2.setSelectMultipleToggleButton(true);
            rowGroup1.setGroupToggleButton(true);
            rowGroup2.setGroupToggleButton(true);

            // Get table.
            table = dynamic.getTable("table1", null);
            table.getChildren().add(rowGroup1);
            table.getChildren().add(rowGroup2);

            // Add title facet.
            StaticText title = new StaticText();
            title.setText("Dynamic Group Table");
            table.getFacets().put(Table.TITLE_FACET, title);
        }
        return table;
    }

    // Set Table component.
    //
    // @param table The Table component.
    public void setTable(Table table) {
        this.table = table;
    }
}

faces_config.xml Entry for Managed Beans

The examples are based on managed beans, such as the example below, added to the faces_config.xml file.

<!DOCTYPE faces-config PUBLIC
    '-//Sun Microsystems, Inc.//DTD JavaServer Faces Config 1.0//EN'
    'http://java.sun.com/dtd/web-facesconfig_1_1.dtd'>

<faces-config>
    <managed-bean>
        <description>Backing bean for the group table example</description>
        <managed-bean-name>TableBean</managed-bean-name>
        <managed-bean-class>table.TableBean</managed-bean-class>
        <managed-bean-scope>session</managed-bean-scope>
    </managed-bean>

    <managed-bean>
        <description>Backing bean for the dynamic table example</description>
        <managed-bean-name>DynamicTableBean</managed-bean-name>
        <managed-bean-class>table.DynamicTableBean</managed-bean-class>
        <managed-bean-scope>session</managed-bean-scope>
    </managed-bean>

    <managed-bean>
        <description>Backing bean for the dynamic group table example</description>
        <managed-bean-name>DynamicGroupTableBean</managed-bean-name>
        <managed-bean-class>table.DynamicGroupTableBean</managed-bean-class>
        <managed-bean-scope>session</managed-bean-scope>
    </managed-bean>
</faces-config>

Utility Classes used in the examples

The  following utility class is used in the group table examples shown in this page.

Dynamic.java

The following utility classes are shown in the ui:table documentation, and used in the examples for the table tags ui:table, ui:tableRowGroup, and ui:tableColumn.

Group.java
Name.java
Select.java

Dynamic.java Utility Class

package table.util;

import com.sun.rave.web.ui.component.Checkbox;
import com.sun.rave.web.ui.component.Hyperlink;
import com.sun.rave.web.ui.component.StaticText;
import com.sun.rave.web.ui.component.Table;
import com.sun.rave.web.ui.component.TableColumn;
import com.sun.rave.web.ui.component.TableRowGroup;

import javax.faces.context.FacesContext;
import javax.faces.component.UIComponent;
import javax.faces.component.UIParameter;
import javax.faces.el.ValueBinding;

// This class provides functionality for dynamic tables.
public class Dynamic {
    public static final String CHECKBOX_ID = "select";
    public static final String HYPERLINK_ID = "link";

    // Default constructor.
    public Dynamic() {
    }

    // Note: When using tags in a JSP page, UIComponentTag automatically creates
    // a unique id for the component. However, when dynamically creating
    // components, via a backing bean, the id has not been set. In this
    // scenario, allowing JSF to create unique Ids may cause problems with
    // Javascript and components may not be able to maintain state properly.
    // For example, if a component was assigned "_id6" as an id, that means
    // there were 5 other components that also have auto-generated ids. Let us
    // assume one of those components was a complex component that, as part of
    // its processing, adds an additional non-id'd child before redisplaying the
    // view. Now, the id of this component will be "_id7" instead of "_id6".
    // Assigning your own id ensures that conflicts do not occur.

    // Get Table component.
    //
    // @param id The component id.
    // @param title The table title text.
    public Table getTable(String id, String title) {
        // Get table.
        Table table = new Table();
        table.setDeselectMultipleButton(true); // Show deselect multiple button.
        table.setSelectMultipleButton(true); // Show select multiple button.
        table.setTitle(title); // Set title text.

        return table;
    }

    // Get TableRowGroup component with header.
    //
    // @param id The component id.
    // @param sourceData Value binding expression for model data.
    // @param selected Value binding expression for selected property.
    // @param header Value binding expression for row group header text.
    public TableRowGroup getTableRowGroup(String id, String sourceData,
            String selected, String header) {
        // Get table row group.
        TableRowGroup rowGroup = new TableRowGroup();
        rowGroup.setId(id); // Set id.
        rowGroup.setSourceVar("name"); // Set source var.
        rowGroup.setHeaderText(header); // Set header text.
        setValueBinding(rowGroup, "selected", selected); // Set row highlight.
        setValueBinding(rowGroup, "sourceData", sourceData); // Set source data.

        return rowGroup;
    }

    // Get TableColumn component.
    //
    // @param id The component id.
    // @param sort Value binding expression for column sort.
    // @param align The field key for column alignment.
    // @param header The column header text.
    // @param selectId The component id used to select table rows.
    public TableColumn getTableColumn(String id, String sort, String align,
            String header, String selectId) {
        // Get table column.
        TableColumn col = new TableColumn();
        col.setId(id); // Set id.
        col.setSelectId(selectId); // Set id used to select table rows.
        col.setHeaderText(header); // Set header text.
        col.setAlignKey(align); // Set align key.
        setValueBinding(col, "sort", sort); // Set sort.

        return col;
    }

    // Get Checkbox component used for select column.
    //
    // @param id The component id.
    // @param selected Value binding expression for selected property.
    // @param selectedValue Value binding expression for selectedValue property.
    public Checkbox getCheckbox(String id, String selected,
            String selectedValue) {
        // Get checkbox.
        Checkbox cb = new Checkbox();
        cb.setId(id); // Set id here and set row highlighting below.
        cb.setOnClick("setTimeout('initAllRows()', 0)");
        setValueBinding(cb, "selected", selected); // Set selected.
        setValueBinding(cb, "selectedValue", selectedValue); // Set selected value.

        return cb;
    }

    // Get Hyperlink component.
    //
    // @param id The component id.
    // @param text Value binding expression for text.
    // @param action Method binding expression for action.
    // @param parameter Value binding expression for parameter.
    public Hyperlink getHyperlink(String id, String text, String action,
            String parameter) {
        // Get hyperlink.
        Hyperlink hyperlink = new Hyperlink();
        hyperlink.setId(id); // Set id.
        setValueBinding(hyperlink, "text", text); // Set text.
        setMethodBinding(hyperlink, "action", action); // Set action.

        // Create paramerter.
        UIParameter param = new UIParameter();
        param.setId(id + "_param");
        param.setName("param");
        setValueBinding(param, "value", parameter); // Set parameter.
        hyperlink.getChildren().add(param);

        return hyperlink;
    }

    // Get StaticText component.
    //
    // @param text Value binding expression for text.
    public StaticText getText(String text) {
        // Get static text.
        StaticText staticText = new StaticText();
        setValueBinding(staticText, "text", text); // Set text.

        return staticText;
    }

    // Set TableRowGroup children.
    //
    // @param rowGroup The TableRowGroup component.
    // @param cbSort Value binding expression for cb sort.
    // @param cbSelected Value binding expression for cb selected property.
    // @param cbSelectedValue Value binding expression for cb selectedValue property.
    // @param action The Method binding expression for hyperlink action.
    // @param showHeader Flag indicating to display column header text.
    public void setTableRowGroupChildren(TableRowGroup rowGroup, String cbSort,
        String cbSelected, String cbSelectedValue, String action,
            boolean showHeader) {
        // UI guidelines recomend no headers for second row group.
        String header1 = showHeader ? "Last Name" : null;
        String header2 = showHeader ? "First Name" : null;

        // Get columns.
        TableColumn col1 = getTableColumn(
            "col0", cbSort, null, null, CHECKBOX_ID);
        TableColumn col2 = getTableColumn(
            "col1", "#{name.value.last}", "last", header1, null);           
        TableColumn col3 = getTableColumn(
            "col2", "#{name.value.first}", "first", header2, null);

        // Get column components.
        Checkbox cb = getCheckbox(CHECKBOX_ID, cbSelected, cbSelectedValue);
        StaticText firstName = getText("#{name.value.first}");
      
        // If action was provided, add a hyperlink; otherwise, use static text.
        if (action != null) {
            Hyperlink lastName = getHyperlink(HYPERLINK_ID,
                "#{name.value.last}", action,
                "#{name.value.last}");
            col2.getChildren().add(lastName);
        } else {
            StaticText lastName = getText("#{name.value.last}");
            col2.getChildren().add(lastName);
        }

        // Add Children.
        col1.getChildren().add(cb);
        col3.getChildren().add(firstName);
        rowGroup.getChildren().add(col1);
        rowGroup.getChildren().add(col2);
        rowGroup.getChildren().add(col3);
    }

    // Helper method to set value bindings.
    //
    // @param component The UIComponent to set a value binding for.
    // @param name The name of the value binding.
    // @param value The value of the value binding.
    protected void setValueBinding(UIComponent component, String name,
            String value) {
        if (value == null) {
            return;
        }
        FacesContext context = FacesContext.getCurrentInstance();
        component.setValueBinding(name, context.getApplication().
            createValueBinding(value));
    }

    // Helper method to set method bindings.
    //
    // @param component The UIComponent to set a value binding for.
    // @param name The name of the method binding.
    // @param action The action of the method binding.
    protected void setMethodBinding(UIComponent component, String name,
            String action) {
        if (action == null) {
            return;
        }
        FacesContext context = FacesContext.getCurrentInstance();
        component.getAttributes().put(name, context.getApplication().
            createMethodBinding(action, new Class[0]));
    }
}


Auto-generated component class. Do NOT modify; all changes will be lost!




Constructor Summary
public  TableRowGroupBase()
    

Method Summary
public  StringgetAlign()
    
public  StringgetBgColor()
    
public  StringgetChar()
    
public  StringgetCharOff()
    
public  StringgetEmptyDataMsg()
    

The text to be displayed when the table does not contain data.

public  StringgetExtraFooterHtml()
    

Extra HTML code to be appended to the <tr> HTML element that is rendered for the group footer.

public  StringgetExtraHeaderHtml()
    

Extra HTML code to be appended to the <tr> HTML element that is rendered for the group header.

public  StringgetFamily()
    

Return the identifier of the component family to which this component belongs.

public  intgetFirst()
    

Use the first attribute to specify which row should be the first to be displayed.

public  StringgetFooterText()
    
public  StringgetHeaderText()
    
public  StringgetOnClick()
    
public  StringgetOnDblClick()
    
public  StringgetOnKeyDown()
    
public  StringgetOnKeyPress()
    
public  StringgetOnKeyUp()
    
public  StringgetOnMouseDown()
    
public  StringgetOnMouseMove()
    
public  StringgetOnMouseOut()
    
public  StringgetOnMouseOver()
    
public  StringgetOnMouseUp()
    
public  intgetRows()
    

The number of rows per page to be displayed for a paginated table.

public  ObjectgetSourceData()
    

The sourceData attribute is used to specify the data source to populate the table.

public  StringgetSourceVar()
    

Use the sourceVar attribute to specify the name of the request-scope attribute under which model data for the current row will be exposed when iterating.

public  StringgetStyleClasses()
    

Use the styleClasses attribute to specify a list of CSS style classes to apply to the rows of the group.

public  com.sun.data.provider.TableDataFiltergetTableDataFilter()
    

The tableDataFilter attribute is used to define filter critera and mechanism for filtering the contents of a TableDataProvider.

public  com.sun.data.provider.TableDataSortergetTableDataSorter()
    

The tableDataSorter attribute is used to define sort critera and the mechanism for sorting the contents of a TableDataProvider.

public  StringgetToolTip()
    
public  StringgetValign()
    
public  booleanisAboveColumnFooter()
    

Set the aboveColumnFooter attribute to true to display the group footer bar above the column footers bar.

public  booleanisAboveColumnHeader()
    

Set the aboveColumnHeader attribute to true to display the group header bar above the column headers bar.

public  booleanisCollapsed()
    

Use the collapsed attribute to initially render the group as collapsed, so that the data rows are hidden and only the header row is visible.

public  booleanisGroupToggleButton()
    
public  booleanisMultipleColumnFooters()
    

Use the multipleColumnFooters attribute when the ui:tableRowGroup contains nested ui:tableColumn tags, and you want the footers of all the ui:tableColumn tags to be shown.

public  booleanisMultipleTableColumnFooters()
    

Use the multipleTableColumnFooters attribute when the ui:tableRowGroup contains nested ui:tableColumn tags, and you want the table footers of all the ui:tableColumn tags to be shown.

public  booleanisSelectMultipleToggleButton()
    

Use the selectMultipleToggleButton attribute to display a button in the group header to allow users to select all rows of the group at once.

public  booleanisSelected()
    

Flag indicating that the current row is selected.

public  booleanisVisible()
    

Use the visible attribute to indicate whether the component should be viewable by the user in the rendered HTML page.

public  voidrestoreState(FacesContext _context, Object _state)
    
public  ObjectsaveState(FacesContext _context)
    
public  voidsetAboveColumnFooter(boolean aboveColumnFooter)
    

Set the aboveColumnFooter attribute to true to display the group footer bar above the column footers bar.

public  voidsetAboveColumnHeader(boolean aboveColumnHeader)
    

Set the aboveColumnHeader attribute to true to display the group header bar above the column headers bar.

public  voidsetAlign(String align)
    
public  voidsetBgColor(String bgColor)
    
public  voidsetChar(String _char)
    
public  voidsetCharOff(String charOff)
    
public  voidsetCollapsed(boolean collapsed)
    

Use the collapsed attribute to initially render the group as collapsed, so that the data rows are hidden and only the header row is visible.

public  voidsetEmptyDataMsg(String emptyDataMsg)
    

The text to be displayed when the table does not contain data.

public  voidsetExtraFooterHtml(String extraFooterHtml)
    

Extra HTML code to be appended to the <tr> HTML element that is rendered for the group footer.

public  voidsetExtraHeaderHtml(String extraHeaderHtml)
    

Extra HTML code to be appended to the <tr> HTML element that is rendered for the group header.

public  voidsetFirst(int first)
    

Use the first attribute to specify which row should be the first to be displayed.

public  voidsetFooterText(String footerText)
    
public  voidsetGroupToggleButton(boolean groupToggleButton)
    
public  voidsetHeaderText(String headerText)
    
public  voidsetMultipleColumnFooters(boolean multipleColumnFooters)
    

Use the multipleColumnFooters attribute when the ui:tableRowGroup contains nested ui:tableColumn tags, and you want the footers of all the ui:tableColumn tags to be shown.

public  voidsetMultipleTableColumnFooters(boolean multipleTableColumnFooters)
    

Use the multipleTableColumnFooters attribute when the ui:tableRowGroup contains nested ui:tableColumn tags, and you want the table footers of all the ui:tableColumn tags to be shown.

public  voidsetOnClick(String onClick)
    
public  voidsetOnDblClick(String onDblClick)
    
public  voidsetOnKeyDown(String onKeyDown)
    
public  voidsetOnKeyPress(String onKeyPress)
    
public  voidsetOnKeyUp(String onKeyUp)
    
public  voidsetOnMouseDown(String onMouseDown)
    
public  voidsetOnMouseMove(String onMouseMove)
    
public  voidsetOnMouseOut(String onMouseOut)
    
public  voidsetOnMouseOver(String onMouseOver)
    
public  voidsetOnMouseUp(String onMouseUp)
    
public  voidsetRows(int rows)
    

The number of rows per page to be displayed for a paginated table.

public  voidsetSelectMultipleToggleButton(boolean selectMultipleToggleButton)
    

Use the selectMultipleToggleButton attribute to display a button in the group header to allow users to select all rows of the group at once.

public  voidsetSelected(boolean selected)
    

Flag indicating that the current row is selected.

public  voidsetSourceData(Object sourceData)
    

The sourceData attribute is used to specify the data source to populate the table.

public  voidsetSourceVar(String sourceVar)
    

Use the sourceVar attribute to specify the name of the request-scope attribute under which model data for the current row will be exposed when iterating.

public  voidsetStyleClasses(String styleClasses)
    

Use the styleClasses attribute to specify a list of CSS style classes to apply to the rows of the group.

public  voidsetTableDataFilter(com.sun.data.provider.TableDataFilter tableDataFilter)
    

The tableDataFilter attribute is used to define filter critera and mechanism for filtering the contents of a TableDataProvider.

public  voidsetTableDataSorter(com.sun.data.provider.TableDataSorter tableDataSorter)
    

The tableDataSorter attribute is used to define sort critera and the mechanism for sorting the contents of a TableDataProvider.

public  voidsetToolTip(String toolTip)
    
public  voidsetValign(String valign)
    
public  voidsetVisible(boolean visible)
    

Use the visible attribute to indicate whether the component should be viewable by the user in the rendered HTML page.



Constructor Detail
TableRowGroupBase
public TableRowGroupBase()(Code)

Construct a new TableRowGroupBase.





Method Detail
getAlign
public String getAlign()(Code)

Sets the horizontal alignment (left, right, justify, center) for the cell contents




getBgColor
public String getBgColor()(Code)



getChar
public String getChar()(Code)



getCharOff
public String getCharOff()(Code)



getEmptyDataMsg
public String getEmptyDataMsg()(Code)

The text to be displayed when the table does not contain data. The text is displayed left-aligned in a single row that contains one cell that spans all columns. The emptyDataMsg text might be something similar to "No items found." If users can add items to the table, the message might include instructions, such as "This table contains no files. To add a file to monitor, click the New button."




getExtraFooterHtml
public String getExtraFooterHtml()(Code)

Extra HTML code to be appended to the <tr> HTML element that is rendered for the group footer. Use only code that is valid in an HTML <td> element. The code you specify is inserted in the HTML element, and is not checked for validity. For example, you might set this attribute to "nowrap=`nowrap'".




getExtraHeaderHtml
public String getExtraHeaderHtml()(Code)

Extra HTML code to be appended to the <tr> HTML element that is rendered for the group header. Use only code that is valid in an HTML <td> element. The code you specify is inserted in the HTML element, and is not checked for validity. For example, you might set this attribute to "nowrap=`nowrap'".




getFamily
public String getFamily()(Code)

Return the identifier of the component family to which this component belongs. This identifier, in conjunction with the value of the rendererType property, may be used to select the appropriate Renderer for this component instance.




getFirst
public int getFirst()(Code)

Use the first attribute to specify which row should be the first to be displayed. This value is used only when the table is paginated. By default, the first row (0) is displayed first. The value of this property is maintained as part of the table's state, and the value is updated when the user clicks on buttons to page through the table.




getFooterText
public String getFooterText()(Code)

The text to be displayed in the group footer.




getHeaderText
public String getHeaderText()(Code)

The text to be displayed in the group header.




getOnClick
public String getOnClick()(Code)

Scripting code executed when a mouse click occurs over this component.




getOnDblClick
public String getOnDblClick()(Code)

Scripting code executed when a mouse double click occurs over this component.




getOnKeyDown
public String getOnKeyDown()(Code)

Scripting code executed when the user presses down on a key while the component has focus.




getOnKeyPress
public String getOnKeyPress()(Code)

Scripting code executed when the user presses and releases a key while the component has focus.




getOnKeyUp
public String getOnKeyUp()(Code)

Scripting code executed when the user releases a key while the component has focus.




getOnMouseDown
public String getOnMouseDown()(Code)

Scripting code executed when the user presses a mouse button while the mouse pointer is on the component.




getOnMouseMove
public String getOnMouseMove()(Code)

Scripting code executed when the user moves the mouse pointer while over the component.




getOnMouseOut
public String getOnMouseOut()(Code)

Scripting code executed when a mouse out movement occurs over this component.




getOnMouseOver
public String getOnMouseOver()(Code)

Scripting code executed when the user moves the mouse pointer into the boundary of this component.




getOnMouseUp
public String getOnMouseUp()(Code)

Scripting code executed when the user releases a mouse button while the mouse pointer is on the component.




getRows
public int getRows()(Code)

The number of rows per page to be displayed for a paginated table. The default value is 25 per page.




getSourceData
public Object getSourceData()(Code)

The sourceData attribute is used to specify the data source to populate the table. The value of the sourceData attribute must be a JavaServer Faces EL expression that resolves to a backing bean of type com.sun.data.provider.TableDataProvider.

The sourceData property is referenced during multiple phases of the JavaServer Faces life cycle while iterating over the rows. The TableDataProvider object that is bound to this attribute should be cached so that the object is not created more often than needed.




getSourceVar
public String getSourceVar()(Code)

Use the sourceVar attribute to specify the name of the request-scope attribute under which model data for the current row will be exposed when iterating. During iterative processing over the rows of data in the data provider, the TableDataProvider for the current row is exposed as a request attribute under the key specified by this property. Note: This value must be unique for each table in the JSP page.




getStyleClasses
public String getStyleClasses()(Code)

Use the styleClasses attribute to specify a list of CSS style classes to apply to the rows of the group. You can apply all the styles in the list to each row by separating the class names with commas. Each row looks the same when commas are used to delimit the styles. You can apply alternating styles to individual rows by separating the style class names with spaces. You can create a pattern of shading alternate rows, for example, to improve readability of the table. For example, if the list has two elements, the first style class in the list is applied to the first row, the second class to the second row, the first class to the third row, the second class to the fourth row, etc. The tableRowGroup component iterates through the list of styles and repeats from the beginning until a style is applied to each row.




getTableDataFilter
public com.sun.data.provider.TableDataFilter getTableDataFilter()(Code)

The tableDataFilter attribute is used to define filter critera and mechanism for filtering the contents of a TableDataProvider. The value of the tableDataFilter attribute must be a JavaServer Faces EL expression that resolves to a backing bean of type com.sun.data.provider.TableDataFilter.




getTableDataSorter
public com.sun.data.provider.TableDataSorter getTableDataSorter()(Code)

The tableDataSorter attribute is used to define sort critera and the mechanism for sorting the contents of a TableDataProvider. The value of the tableDataSorter attribute must be a JavaServer Faces EL expression that resolves to a backing bean of type com.sun.data.provider.TableDataSorter.




getToolTip
public String getToolTip()(Code)

Display the text as a tooltip for this component




getValign
public String getValign()(Code)

Vertical alignment (top, middle, bottom) for the content of each cell in the column




isAboveColumnFooter
public boolean isAboveColumnFooter()(Code)

Set the aboveColumnFooter attribute to true to display the group footer bar above the column footers bar. The default is to display the group footer below the column footers.




isAboveColumnHeader
public boolean isAboveColumnHeader()(Code)

Set the aboveColumnHeader attribute to true to display the group header bar above the column headers bar. The default is to display the group header below the column headers.




isCollapsed
public boolean isCollapsed()(Code)

Use the collapsed attribute to initially render the group as collapsed, so that the data rows are hidden and only the header row is visible. The default is to show the group expanded.




isGroupToggleButton
public boolean isGroupToggleButton()(Code)

Use the groupToggleButton attribute to display a button in the group header to allow users to collapse and expand the group of rows.




isMultipleColumnFooters
public boolean isMultipleColumnFooters()(Code)

Use the multipleColumnFooters attribute when the ui:tableRowGroup contains nested ui:tableColumn tags, and you want the footers of all the ui:tableColumn tags to be shown. The default is to show the footers of only the innermost level of nested ui:tableColumn tags.




isMultipleTableColumnFooters
public boolean isMultipleTableColumnFooters()(Code)

Use the multipleTableColumnFooters attribute when the ui:tableRowGroup contains nested ui:tableColumn tags, and you want the table footers of all the ui:tableColumn tags to be shown. The default is to show the table footers of only the innermost level of nested ui:tableColumn tags.




isSelectMultipleToggleButton
public boolean isSelectMultipleToggleButton()(Code)

Use the selectMultipleToggleButton attribute to display a button in the group header to allow users to select all rows of the group at once. The button toggles a column of checkboxes using the id that is given to the selectId attribute of the ui:tableColumn tag.




isSelected
public boolean isSelected()(Code)

Flag indicating that the current row is selected. If the value is set to true, the row will appear highlighted.




isVisible
public boolean isVisible()(Code)

Use the visible attribute to indicate whether the component should be viewable by the user in the rendered HTML page. If set to false, the HTML code for the component is present in the page, but the component is hidden with style attributes. By default, visible is set to true, so HTML for the component HTML is included and visible to the user. If the component is not visible, it can still be processed on subsequent form submissions because the HTML is present.




restoreState
public void restoreState(FacesContext _context, Object _state)(Code)

Restore the state of this component.




saveState
public Object saveState(FacesContext _context)(Code)

Save the state of this component.




setAboveColumnFooter
public void setAboveColumnFooter(boolean aboveColumnFooter)(Code)

Set the aboveColumnFooter attribute to true to display the group footer bar above the column footers bar. The default is to display the group footer below the column footers.


See Also:   TableRowGroupBase.isAboveColumnFooter()



setAboveColumnHeader
public void setAboveColumnHeader(boolean aboveColumnHeader)(Code)

Set the aboveColumnHeader attribute to true to display the group header bar above the column headers bar. The default is to display the group header below the column headers.


See Also:   TableRowGroupBase.isAboveColumnHeader()



setAlign
public void setAlign(String align)(Code)

Sets the horizontal alignment (left, right, justify, center) for the cell contents


See Also:   TableRowGroupBase.getAlign()



setBgColor
public void setBgColor(String bgColor)(Code)



setChar
public void setChar(String _char)(Code)



setCharOff
public void setCharOff(String charOff)(Code)



setCollapsed
public void setCollapsed(boolean collapsed)(Code)

Use the collapsed attribute to initially render the group as collapsed, so that the data rows are hidden and only the header row is visible. The default is to show the group expanded.


See Also:   TableRowGroupBase.isCollapsed()



setEmptyDataMsg
public void setEmptyDataMsg(String emptyDataMsg)(Code)

The text to be displayed when the table does not contain data. The text is displayed left-aligned in a single row that contains one cell that spans all columns. The emptyDataMsg text might be something similar to "No items found." If users can add items to the table, the message might include instructions, such as "This table contains no files. To add a file to monitor, click the New button."


See Also:   TableRowGroupBase.getEmptyDataMsg()



setExtraFooterHtml
public void setExtraFooterHtml(String extraFooterHtml)(Code)

Extra HTML code to be appended to the <tr> HTML element that is rendered for the group footer. Use only code that is valid in an HTML <td> element. The code you specify is inserted in the HTML element, and is not checked for validity. For example, you might set this attribute to "nowrap=`nowrap'".


See Also:   TableRowGroupBase.getExtraFooterHtml()



setExtraHeaderHtml
public void setExtraHeaderHtml(String extraHeaderHtml)(Code)

Extra HTML code to be appended to the <tr> HTML element that is rendered for the group header. Use only code that is valid in an HTML <td> element. The code you specify is inserted in the HTML element, and is not checked for validity. For example, you might set this attribute to "nowrap=`nowrap'".


See Also:   TableRowGroupBase.getExtraHeaderHtml()



setFirst
public void setFirst(int first)(Code)

Use the first attribute to specify which row should be the first to be displayed. This value is used only when the table is paginated. By default, the first row (0) is displayed first. The value of this property is maintained as part of the table's state, and the value is updated when the user clicks on buttons to page through the table.


See Also:   TableRowGroupBase.getFirst()



setFooterText
public void setFooterText(String footerText)(Code)

The text to be displayed in the group footer.


See Also:   TableRowGroupBase.getFooterText()



setGroupToggleButton
public void setGroupToggleButton(boolean groupToggleButton)(Code)

Use the groupToggleButton attribute to display a button in the group header to allow users to collapse and expand the group of rows.


See Also:   TableRowGroupBase.isGroupToggleButton()



setHeaderText
public void setHeaderText(String headerText)(Code)

The text to be displayed in the group header.


See Also:   TableRowGroupBase.getHeaderText()



setMultipleColumnFooters
public void setMultipleColumnFooters(boolean multipleColumnFooters)(Code)

Use the multipleColumnFooters attribute when the ui:tableRowGroup contains nested ui:tableColumn tags, and you want the footers of all the ui:tableColumn tags to be shown. The default is to show the footers of only the innermost level of nested ui:tableColumn tags.


See Also:   TableRowGroupBase.isMultipleColumnFooters()



setMultipleTableColumnFooters
public void setMultipleTableColumnFooters(boolean multipleTableColumnFooters)(Code)

Use the multipleTableColumnFooters attribute when the ui:tableRowGroup contains nested ui:tableColumn tags, and you want the table footers of all the ui:tableColumn tags to be shown. The default is to show the table footers of only the innermost level of nested ui:tableColumn tags.


See Also:   TableRowGroupBase.isMultipleTableColumnFooters()



setOnClick
public void setOnClick(String onClick)(Code)

Scripting code executed when a mouse click occurs over this component.


See Also:   TableRowGroupBase.getOnClick()



setOnDblClick
public void setOnDblClick(String onDblClick)(Code)

Scripting code executed when a mouse double click occurs over this component.


See Also:   TableRowGroupBase.getOnDblClick()



setOnKeyDown
public void setOnKeyDown(String onKeyDown)(Code)

Scripting code executed when the user presses down on a key while the component has focus.


See Also:   TableRowGroupBase.getOnKeyDown()



setOnKeyPress
public void setOnKeyPress(String onKeyPress)(Code)

Scripting code executed when the user presses and releases a key while the component has focus.


See Also:   TableRowGroupBase.getOnKeyPress()



setOnKeyUp
public void setOnKeyUp(String onKeyUp)(Code)

Scripting code executed when the user releases a key while the component has focus.


See Also:   TableRowGroupBase.getOnKeyUp()



setOnMouseDown
public void setOnMouseDown(String onMouseDown)(Code)

Scripting code executed when the user presses a mouse button while the mouse pointer is on the component.


See Also:   TableRowGroupBase.getOnMouseDown()



setOnMouseMove
public void setOnMouseMove(String onMouseMove)(Code)

Scripting code executed when the user moves the mouse pointer while over the component.


See Also:   TableRowGroupBase.getOnMouseMove()



setOnMouseOut
public void setOnMouseOut(String onMouseOut)(Code)

Scripting code executed when a mouse out movement occurs over this component.


See Also:   TableRowGroupBase.getOnMouseOut()



setOnMouseOver
public void setOnMouseOver(String onMouseOver)(Code)

Scripting code executed when the user moves the mouse pointer into the boundary of this component.


See Also:   TableRowGroupBase.getOnMouseOver()



setOnMouseUp
public void setOnMouseUp(String onMouseUp)(Code)

Scripting code executed when the user releases a mouse button while the mouse pointer is on the component.


See Also:   TableRowGroupBase.getOnMouseUp()



setRows
public void setRows(int rows)(Code)

The number of rows per page to be displayed for a paginated table. The default value is 25 per page.


See Also:   TableRowGroupBase.getRows()



setSelectMultipleToggleButton
public void setSelectMultipleToggleButton(boolean selectMultipleToggleButton)(Code)

Use the selectMultipleToggleButton attribute to display a button in the group header to allow users to select all rows of the group at once. The button toggles a column of checkboxes using the id that is given to the selectId attribute of the ui:tableColumn tag.


See Also:   TableRowGroupBase.isSelectMultipleToggleButton()



setSelected
public void setSelected(boolean selected)(Code)

Flag indicating that the current row is selected. If the value is set to true, the row will appear highlighted.


See Also:   TableRowGroupBase.isSelected()



setSourceData
public void setSourceData(Object sourceData)(Code)

The sourceData attribute is used to specify the data source to populate the table. The value of the sourceData attribute must be a JavaServer Faces EL expression that resolves to a backing bean of type com.sun.data.provider.TableDataProvider.

The sourceData property is referenced during multiple phases of the JavaServer Faces life cycle while iterating over the rows. The TableDataProvider object that is bound to this attribute should be cached so that the object is not created more often than needed.


See Also:   TableRowGroupBase.getSourceData()



setSourceVar
public void setSourceVar(String sourceVar)(Code)

Use the sourceVar attribute to specify the name of the request-scope attribute under which model data for the current row will be exposed when iterating. During iterative processing over the rows of data in the data provider, the TableDataProvider for the current row is exposed as a request attribute under the key specified by this property. Note: This value must be unique for each table in the JSP page.


See Also:   TableRowGroupBase.getSourceVar()



setStyleClasses
public void setStyleClasses(String styleClasses)(Code)

Use the styleClasses attribute to specify a list of CSS style classes to apply to the rows of the group. You can apply all the styles in the list to each row by separating the class names with commas. Each row looks the same when commas are used to delimit the styles. You can apply alternating styles to individual rows by separating the style class names with spaces. You can create a pattern of shading alternate rows, for example, to improve readability of the table. For example, if the list has two elements, the first style class in the list is applied to the first row, the second class to the second row, the first class to the third row, the second class to the fourth row, etc. The tableRowGroup component iterates through the list of styles and repeats from the beginning until a style is applied to each row.


See Also:   TableRowGroupBase.getStyleClasses()



setTableDataFilter
public void setTableDataFilter(com.sun.data.provider.TableDataFilter tableDataFilter)(Code)

The tableDataFilter attribute is used to define filter critera and mechanism for filtering the contents of a TableDataProvider. The value of the tableDataFilter attribute must be a JavaServer Faces EL expression that resolves to a backing bean of type com.sun.data.provider.TableDataFilter.


See Also:   TableRowGroupBase.getTableDataFilter()



setTableDataSorter
public void setTableDataSorter(com.sun.data.provider.TableDataSorter tableDataSorter)(Code)

The tableDataSorter attribute is used to define sort critera and the mechanism for sorting the contents of a TableDataProvider. The value of the tableDataSorter attribute must be a JavaServer Faces EL expression that resolves to a backing bean of type com.sun.data.provider.TableDataSorter.


See Also:   TableRowGroupBase.getTableDataSorter()



setToolTip
public void setToolTip(String toolTip)(Code)

Display the text as a tooltip for this component


See Also:   TableRowGroupBase.getToolTip()



setValign
public void setValign(String valign)(Code)

Vertical alignment (top, middle, bottom) for the content of each cell in the column


See Also:   TableRowGroupBase.getValign()



setVisible
public void setVisible(boolean visible)(Code)

Use the visible attribute to indicate whether the component should be viewable by the user in the rendered HTML page. If set to false, the HTML code for the component is present in the page, but the component is hidden with style attributes. By default, visible is set to true, so HTML for the component HTML is included and visible to the user. If the component is not visible, it can still be processed on subsequent form submissions because the HTML is present.


See Also:   TableRowGroupBase.isVisible()



www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.