| |||||||
FRAMES NO FRAMES |
webuijsf:tableColumn
tag to define the column cells of a table, inside a webuijsf:table
tag. A webuijsf:tableRowGroup
must include at least one webuijsf:tableColumn
tag.The webuijsf:table
tag is
used to define the structure and actions of the table, and is a
container for webuijsf:tableRowGroup
which define the rows of a table. The webuijsf:tableRowGroup
tag is a container for webuijsf:tableColumn
tags, which are used
to define the
columns of the table.
The documentation
for the
webuijsf:table
tag
contains detailed information
about the table component. This page provides details about how
to define table columns only.
<td>
elements, which are used
to display table data cells. However, the rendering of
column headers and footers is handled by the tableRowGroup component.
The diagram shows the table layout, and
highlights the areas that are defined with the webuijsf:tableColumn
tag. Title Bar | ||||||||||||
Action Bar (top) | ||||||||||||
|
||||||||||||
Action Bar (bottom) | ||||||||||||
Footer
|
headerText
attribute in the webuijsf:tableColumn
tag, the default implementation of the header is rendered. You can
specify a separate component to provide column header content by using
the header
facet, which overrides the headerText
attribute.
You can add extra HTML code to the
header's rendered <td>
element with the extraHeaderHtml
attribute.webuijsf:tableColumn
attributes can be used to
change
the appearance and behavior for sorting of the Column Header:sort
specifies a sort key and makes a column sortable.
sortIcon
specifies a theme identifier to select a different image to use as the
sort icon that is displayed in the header of a sortable column.
sortImageURL
specifies the path to an image to use as the sort icon that is
displayed in the header of a
sortable column.
descending
when set to true causes the column
to be sorted in descending order.
severity
specifies the severity of an alarm
in each cell, and causes the column to sort on the severity value
if used with the sort
attribute.
footerText
attribute in the webuijsf:tableColumn
tag, the default
implementation of the footer is rendered. You can specify a separate
component to provide footer content by using the footer
facet, which overrides the footerText
attribute.
You can add extra HTML code to the
footer's rendered <td>
element with the extraFooterHtml
attribute.tableFooterText
attribute, the default implementation of the footer is rendered.
You can specify a separate component to provide the content for a table
column footer by
using the tableFooter
facet, which overrides the tableFooterText
attribute. You
can add extra HTML code to the table footer's rendered <td>
element with the extraTableFooterHtml
attribute.webuijsf:tableColumn
tag can be used to set other aspects of the
table's
appearance and behavior. align
specifies the horizontal alignment
for
the cell data in the
columnalignKey
specifies a particular data element on
which to align the
cell data valign
specifies the vertical alignment
for
the content of each cellscope
set
to a keyword to specify the portion of the table that this header
applies to. rowHeader
set to true to specify that the content of the column's cells applies
to the row in which the
cell is located. abbr
specifies an abbreviated form of the cell's content, to
be used when the browser has little space to render the content.embeddedActions
when set to true causes separators to be rendered
between multiple action hyperlinks.emptyCell
when
set to
true causes an unexpectedly empty cell to be
rendered with an appropriate image.spacerColumn
when
set to true causes the column to be rendered as a blank column to
enhance table spacing.
height
specifies
the height of a column's cells.
width
specifies
the width of a column's cells.
nowrap
prevents
the content of the cell from wrapping to a new line.selectId
attribute in the webuijsf:tableColumn
tag and include a webuijsf:checkbox
or webuijsf:radioButton
tag as a child of the webuijsf:tableColumn
tag, the first column is rendered
appropriately. See the Select Single
Row example for more
information. webuijsf:tableColumn
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 is displayed at the bottom of the column within
the group of rows. The footer applies to the column of cells that are
defined
by the webuijsf:tableColumn
tag. This facet can be used to replace the default footer for the
column. |
header |
Header that applies to the column of cells that are defined
by the webuijsf:tableColumn
tag. This facet can be used to replace the default header for the
column. |
tableFooter |
Footer that is displayed at the bottom of the table, below the last group of rows, above the Action Bar and overall table footer. The table footer content should apply to the column for all the groups of rows in the table. This facet can be used to replace the default table footer for the column. |
webuijsf:table
tag's
JavaScript documentation.
The same functions are used for the
webuijsf:tableColumn
tag.webuijsf:table
tag documentation. Utility
classes used in the examples are
included
in this page, after the examples.
Additional examples are shown in the webuijsf:table
and webuijsf:tableRowGroup
documents.webuijsf:table
tag is contained
within an HTML <form>
element so that actions can
submit form data. Example
3: Select
Multiple Rows
Example 4: Hidden Selected Rows
webuijsf:table
documentation. Notice that the
webuijsf:table
tag includes the clearSortButton
attribute to enable
users to clear any sorts applied to the table.sort
attribute in webuijsf:tableColumn
must be the proper data type
for sorting to work as expected. For example, you should not use String
objects for numeric data because the digits will be sorted according to
their ASCII values. Sorting the numbers as strings causes the number 2
to be displayed before the number 11, for example. Be sure to
sort using objects such as Number, Character, Date, Boolean, etc.addSort(SortCriteria)
method of TableRowGroup. When the table is rendered, the data is sorted
and the primary sort column is highlighted. <!-- Sortable
Table -->
<webuijsf:table id="table1"
clearSortButton="true"
sortPanelToggleButton="true"
title="Sortable Table">
<webuijsf:tableRowGroup id="rowGroup1"
sourceData="#{TableBean.groupB.names}"
sourceVar="name">
<webuijsf:tableColumn id="col1"
alignKey="last"
headerText="Last Name"
rowHeader="true"
sort="last">
<webuijsf:staticText
text="#{name.value.last}"/>
</webuijsf:tableColumn>
<webuijsf:tableColumn id="col2"
alignKey="first"
headerText="First Name"
sort="first">
<webuijsf:staticText
text="#{name.value.first}"/>
</webuijsf:tableColumn>
</webuijsf:tableRowGroup>
</webuijsf:table>
initAllRows()
JavaScript function whenever the state of
the radio button
changes. The initAllRows()
function is defined in select.js
shown below. The
radio button state is maintained through the selected
attribute of the
webuijsf:tableRowGroup
tag. This example does not maintain state
across paginated
pages.com.sun.webui.jsf.event.TableSelectPhaseListener
object
ensures that rows that are hidden from view are
deselected because the phase listener clears the selected state after
the
rendering phase. The TableSelectPhaseListener
object is used in this example in Select.java
in the webuijsf:table
documentation. Also refer to the JavaDoc
for TableSelectPhaseListener
for more information. <!-- Single Select Row -->
<webuijsf:table id="table1"
deselectSingleButton="true"
paginateButton="true"
paginationControls="true"
title="Select Single Row">
<webuijsf:tableRowGroup id="rowGroup1"
selected="#{TableBean.groupA.select.selectedState}"
sourceData="#{TableBean.groupA.names}"
sourceVar="name" rows="5">
<webuijsf:tableColumn id="col0"
onClick="setTimeout('initAllRows()', 0)"
selectId="select"
sort="#{TableBean.groupA.select.selectedState}">
<webuijsf:radioButton id="select"
name="select"
selected="#{TableBean.groupA.select.selected}"
selectedValue="#{TableBean.groupA.select.selectedValue}"/>
</webuijsf:tableColumn>
<webuijsf:tableColumn id="col1"
alignKey="last"
headerText="Last Name" rowHeader="true">
<webuijsf:staticText
text="#{name.value.last}"/>
</webuijsf:tableColumn>
<webuijsf:tableColumn id="col2" alignKey="first"
headerText="First Name">
<webuijsf:staticText
text="#{name.value.first}"/>
</webuijsf:tableColumn>
</webuijsf:tableRowGroup>
</webuijsf:table>
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();
}
initAllRows()
JavaScript function whenever the state of
the checkbox
changes. The initAllRows()
function is defined in select.js
in
the previous example. The checkbox state is maintained
through the selected
attribute of the
webuijsf:tableRowGroup
tag. This example does not maintain state
across paginated
pages.com.sun.webui.jsf.event.TableSelectPhaseListener
object
ensures that rows that are hidden from view are
deselected because the phase listener clears the selected state after
the
rendering phase. The TableSelectPhaseListener
object is used in this example in Select.java,
shown in the webuijsf:table
documentation. Also refer to the
JavaDoc
for TableSelectPhaseListener
for more information. <!-- Select Multiple Rows -->
<webuijsf:table id="table1"
deselectMultipleButton="true"
selectMultipleButton="true"
paginateButton="true"
paginationControls="true"
title="Select Multiple Rows">
<webuijsf:tableRowGroup id="rowGroup1"
selected="#{TableBean.groupA.select.selectedState}"
sourceData="#{TableBean.groupA.names}"
sourceVar="name" rows="5">
<webuijsf:tableColumn id="col0"
selectId="select"
sort="#{TableBean.groupA.select.selectedState}">
<webuijsf:checkbox id="select"
onClick="setTimeout('initAllRows()', 0)"
selected="#{TableBean.groupA.select.selected}"
selectedValue="#{TableBean.groupA.select.selectedValue}"/>
</webuijsf:tableColumn>
<webuijsf:tableColumn id="col1"
alignKey="last"
headerText="Last Name" rowHeader="true">
<webuijsf:staticText
text="#{name.value.last}"/>
</webuijsf:tableColumn>
<webuijsf:tableColumn id="col2" alignKey="first"
headerText="First Name">
<webuijsf:staticText
text="#{name.value.first}"/>
</webuijsf:tableColumn>
</webuijsf:tableRowGroup>
</webuijsf:table>
selected
attribute of
the
webuijsf:tableRowGroup
tag. Dynamic row highlighting is
set by
invoking an
initAllRows()
JavaScript function whenever the state of
the checkbox
changes. The initAllRows()
function is defined in select.js
in the previous example. hiddenSelectedRows
attribute to true in
the webuijsf:table
tag as shown in this example. The attribute
causes text to be
displayed in the table title and footer to indicate the number of
selected rows that are currently hidden from view. See the Select.java
utility class in the webuijsf:table
documentation.
<!--
Hidden Selected Rows -->
<webuijsf:table id="table1"
deselectMultipleButton="true"
deselectMultipleButtonOnClick="setTimeout('disableActions()', 0)"
hiddenSelectedRows="true"
paginateButton="true"
paginationControls="true"
selectMultipleButton="true"
selectMultipleButtonOnClick="setTimeout('disableActions()', 0)"
title="Hidden Selected Rows">
<webuijsf:tableRowGroup id="rowGroup1"
binding="#{TableBean.groupA.tableRowGroup}"
selected="#{TableBean.groupA.select.selectedState}"
sourceData="#{TableBean.groupA.names}"
sourceVar="name" rows="5">
<webuijsf:tableColumn id="col0"
selectId="select"
sort="#{TableBean.groupA.select.selectedState}">
<webuijsf:checkbox id="select"
binding="#{TableBean.groupA.checkbox}"
onClick="setTimeout('initAllRows(); disableActions()', 0)"
selected="#{TableBean.groupA.select.selected}"
selectedValue="#{TableBean.groupA.select.selectedValue}"/>
</webuijsf:tableColumn>
<webuijsf:tableColumn id="col1"
alignKey="last"
headerText="Last Name" rowHeader="true">
<webuijsf:staticText
text="#{name.value.last}"/>
</webuijsf:tableColumn>
<webuijsf:tableColumn id="col2" alignKey="first"
headerText="First Name">
<webuijsf:staticText
text="#{name.value.first}"/>
</webuijsf:tableColumn>
</webuijsf:tableRowGroup>
<!-- Actions (Top) -->
<f:facet name="actionsTop">
<f:subview id="actionsTop">
<jsp:include
page="actionsTop.jsp"/>
</f:subview>
</f:facet>
<!-- Actions (Bottom) -->
<f:facet name="actionsBottom">
<f:subview id="actionsBottom">
<jsp:include
page="actionsBottom.jsp"/>
</f:subview>
</f:facet>
</webuijsf:table>
webuijsf:table
tag expand to the width of the
browser window, the two data columns might become so wide that the
properties and their values are not close together, and readability is
reduced. To solve this problem, you can add a spacer column to one side
of the table.spacerColumn
attribute set to true, and the width
attribute set to
70%. The column has no header or footer text, and no data. This column
acts to always keep
the data
of the first two columns in close proximity. If a column header
and footer are required, provide an empty string for the headerText
and
footerText
attributes. Set the width attribute to a value
that achieves the desired spacing. <!-- Spacer Column -->
<webuijsf:table id="table1" title="Spacer Column">
<webuijsf:tableRowGroup id="rowGroup1"
sourceData="#{TableBean.groupB.names}"
sourceVar="name">
<webuijsf:tableColumn id="col1"
alignKey="last"
footerText="Column Footer"
headerText="Last Name"
rowHeader="true">
<webuijsf:staticText
text="#{name.value.last}"/>
</webuijsf:tableColumn>
<webuijsf:tableColumn id="col2"
alignKey="first"
footerText="Column Footer"
headerText="First Name">
<webuijsf:staticText
text="#{name.value.first}"/>
</webuijsf:tableColumn>
<webuijsf:tableColumn id="col3" spacerColumn="true"
width="70%"/>
</webuijsf:tableRowGroup>
</webuijsf:table>
emptyCell
attribute is set to
an expression that evaluates to true in every fifth row. In your
application, it is up to you to decide how to
test if the cell is truly empty. For example, you could use this
syntax: emptyCell="#{name.value.last == null}"
<!-- Empty Cells -->
<webuijsf:table id="table1" title="Empty Cells">
<webuijsf:tableRowGroup id="rowGroup1"
selected="#{TableBean.groupB.select.selectedState}"
sourceData="#{TableBean.groupB.names}"
sourceVar="name" rows="5">
<webuijsf:tableColumn id="col0"
emptyCell="#{name.tableRow.rowId % 5 == 0}"
selectId="select">
<webuijsf:checkbox id="select"
onClick="setTimeout('initAllRows()', 0)"
selected="#{TableBean.groupB.select.selected}"
selectedValue="#{TableBean.groupB.select.selectedValue}"/>
</webuijsf:tableColumn>
<webuijsf:tableColumn id="col1"
emptyCell="#{name.tableRow.rowId % 5 == 0}"
alignKey="last"
headerText="Last Name"
rowHeader="true">
<webuijsf:staticText
text="#{name.value.last}"/>
</webuijsf:tableColumn>
<webuijsf:tableColumn id="col2"
emptyCell="#{name.tableRow.rowId % 5 == 0}"
alignKey="first"
headerText="First Name">
<webuijsf:staticText
text="#{name.value.first}"/>
</webuijsf:tableColumn>
</webuijsf:tableRowGroup>
</webuijsf:table>
webuijsf:tableColumn
tag contains more than one tag
such as
webuijsf:hyperlink
that a
re
used as embedded actions, you
should set the webuijsf:tableColumn
tag's embeddedActions
attribute to
true. This attribute causes an action separator image to be displayed
between each of the rendered hyperlinks, as recommended in UI
guidelines.<!-- Embedded Actions -->
<webuijsf:table id="table1" title="Embedded Actions">
<webuijsf:tableRowGroup id="rowGroup1"
sourceData="#{TableBean.groupB.names}"
sourceVar="name">
<webuijsf:tableColumn id="col0" embeddedActions="true"
headerText="Actions">
<webuijsf:hyperlink id="action1"
action="#{TableBean.groupB.actions.action}"
text="Action
1">
<f:param name="param"
value="#{name.value.last}"/>
</webuijsf:hyperlink>
<webuijsf:hyperlink id="action2"
action="#{TableBean.groupB.actions.action}"
text="Action
2">
<f:param name="param"
value="#{name.tableRow.rowId}"/>
</webuijsf:hyperlink>
</webuijsf:tableColumn>
<webuijsf:tableColumn id="col1"
alignKey="last"
headerText="Last Name" rowHeader="true">
<webuijsf:staticText
text="#{name.value.last}"/>
</webuijsf:tableColumn>
<webuijsf:tableColumn id="col2" alignKey="first"
headerText="First Name">
<webuijsf:staticText
text="#{name.value.first}"/>
</webuijsf:tableColumn>
</webuijsf:tableRowGroup>
</webuijsf:table>
webuijsf:tableColumn
tag includes a webuijsf:alarm
tag to render the alarm icon. The webuijsf:tableColumn
tag's severity
attribute is set to true, which
causes the
table data cell to appear highlighted according to level of
severity.
Note also that the column
is set to sort on the severity of the alarms. See
the TableBean
backing bean
and Name.java utlity class example in the webuijsf:table
documentation for the model data. <!-- Alarms -->
<webuijsf:table id="table1" title="Alarms">
<webuijsf:tableRowGroup id="rowGroup1"
sourceData="#{TableBean.groupB.names}"
sourceVar="name">
<webuijsf:tableColumn id="col1"
alignKey="last"
headerText="Last Name"
rowHeader="true"
sort="last">
<webuijsf:staticText
text="#{name.value.last}"/>
</webuijsf:tableColumn>
<webuijsf:tableColumn id="col2"
alignKey="first"
headerText="First Name"
severity="#{name.value.severity}"
sort="alarm">
<webuijsf:alarm id="alarm"
severity="#{name.value.severity}" text="#{name.value.first}"/>
</webuijsf:tableColumn>
</webuijsf:tableRowGroup>
</webuijsf:table>
webuijsf:tableColumn
tags to create
multiple headers and footers. The third webuijsf:tableColumn
(col3) contains four nested columns col3a, col3b, col3c, and col3d. The
column header specified in col3 spans the four nested columns.
However, not
all webuijsf:tableColumn
attributes are supported when the
tags are nested. Typically, only the
header, footer, tableFooter, and sort would apply to a header and
spaning multiple columns. Sorting in the parent tableColumn is
supported, but for usability, sorting is recommended only for
tableColumn children. In addition, nesting of more than one level of
tableColumn components will render, but the CSS styles only support one
level of nesting.
<!-- Multiple Headers & Footers -->
<webuijsf:table id="table1"
clearSortButton="true"
deselectMultipleButton="true"
deselectMultipleButtonOnClick="setTimeout('disableActions()', 0)"
footerText="Table Footer"
paginateButton="true"
paginationControls="true"
selectMultipleButton="true"
selectMultipleButtonOnClick="setTimeout('disableActions()', 0)"
sortPanelToggleButton="true"
title="Multiple Headers & Footers">
<webuijsf:tableRowGroup id="rowGroup1"
binding="#{TableBean.groupA.tableRowGroup}"
rows="#{TableBean.groupA.preferences.rows}"
selected="#{TableBean.groupA.select.selectedState}"
sourceData="#{TableBean.groupA.names}"
sourceVar="name">
<webuijsf:tableColumn id="col0"
selectId="select"
sort="#{TableBean.groupA.select.selectedState}">
<webuijsf:checkbox id="select"
onClick="setTimeout('initAllRows(); disableActions()', 0)"
selected="#{TableBean.groupA.select.selected}"
selectedValue="#{TableBean.groupA.select.selectedValue}"/>
</webuijsf:tableColumn>
<webuijsf:tableColumn id="col1"
alignKey="last"
headerText="Last Name"
rowHeader="true">
<webuijsf:staticText
text="#{name.value.last}"/>
</webuijsf:tableColumn>
<webuijsf:tableColumn id="col2"
alignKey="first"
headerText="First Name">
<webuijsf:staticText
text="#{name.value.first}"/>
</webuijsf:tableColumn>
<webuijsf:tableColumn id="col3" headerText="Task
Status">
<!-- Nested Columns -->
<webuijsf:tableColumn id="col3a"
headerText="A"
footerText="ColFtrA"
sort="last"
sortIcon="ALARM_CRITICAL_MEDIUM"
tableFooterText="TblFtrA">
<webuijsf:staticText
text="a"/>
</webuijsf:tableColumn>
<webuijsf:tableColumn id="col3b"
headerText="B"
footerText="ColFtrB"
sort="first"
sortIcon="ALARM_MAJOR_MEDIUM"
tableFooterText="TblFtrB">
<webuijsf:staticText
text="b"/>
</webuijsf:tableColumn>
<webuijsf:tableColumn id="col3c"
headerText="C"
footerText="ColFtrC"
sortIcon="ALARM_MINOR_MEDIUM"
tableFooterText="TblFtrC">
<webuijsf:staticText
text="c"/>
</webuijsf:tableColumn>
<webuijsf:tableColumn id="col3d"
headerText="D"
footerText="ColFtrD"
sortIcon="ALARM_DOWN_MEDIUM"
tableFooterText="TblFtrD">
<webuijsf:staticText
text="d"/>
</webuijsf:tableColumn>
</webuijsf:tableColumn>
</webuijsf:tableRowGroup>
</webuijsf:table>
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>The
backing bean for the 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>
</faces-config>
Tag Information | |
Tag Class | com.sun.webui.jsf.component.TableColumnTag |
TagExtraInfo Class | None |
Body Content | JSP |
Display Name | None |
Attributes | ||||
Name | Required | Request-time | Type | Description |
binding | false | false | java.lang.String | A ValueExpression that resolves to the UIComponent that corresponds to this tag. This binding allows the Java bean that contains the UIComponent to manipulate the UIComponent, its properties, and its children. |
extraFooterHtml | false | false | java.lang.String | Extra HTML code to be appended to the <td> HTML element that
is rendered for the column 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'" .
|
extraHeaderHtml | false | false | java.lang.String | Extra HTML code to be appended to the <th> HTML element that
is rendered for the column 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'" .
|
tableFooterText | false | false | java.lang.String | The text to be displayed in the table column footer. The table column footer is displayed once per table, and is especially useful in tables with multiple groups of rows. |
extraTableFooterHtml | false | false | java.lang.String | Extra HTML code to be appended to the <td> HTML element that
is rendered for the table column 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'" .
|
spacerColumn | false | false | java.lang.String | Use the spacerColumn attribute to use the column as a blank column
to enhance spacing in two or three column tables. When the
spacerColumn attribute is true, the CSS styles applied to the
column make it appear as if the columns are justified. If a column header and
footer are required, provide an empty string for the headerText
and footerText attributes. Set the width attribute to
justify columns accordingly.
|
onDblClick | false | false | java.lang.String | Scripting code executed when a mouse double click occurs over this component. |
width | false | false | java.lang.String | Use the width attribute to specify the width of the cells of the
column. The width can be specified as the number of pixels or the percentage of
the table width, and is especially useful for spacer columns. This attribute is
deprecated in HTML 4.0 in favor of style sheets.
|
selectId | false | false | java.lang.String | Use the selectId attribute in select columns, which contain
checkboxes or radio buttons for selecting table rows. The value of
selectId must match the id attribute of the checkbox
or radioButton component that is a child of the tableColumn component. A fully
qualified ID based on the tableColumn component ID and the
selectId for the current row will be dynamically created for the
<input> element that is rendered for the checkbox or radio
button. The selectId is required for functionality that supports
the toggle buttons for selecting rows. The selectId also
identifies the column as a select column, for which the table component
uses different CSS styles.
|
sort | false | false | java.lang.String | Use the sort attribute to specify a FieldKey id or SortCriteria
that defines the criteria to use for sorting the contents of a
TableDataProvider. If SortCriteria is provided, the object is used for sorting
as is. If an id is provided, a FieldIdSortCriteria is created for sorting. In
addition, a value binding can also be used to sort on an object that is
external to TableDataProvider, such as the selected state of a checkbox or
radiobutton. When a value binding is used, a ValueBindingSortCriteria object
is created for sorting. All sorting is based on the object type associated with
the data element (for example, Boolean, Character, Comparator, Date, Number,
and String). If the object type cannot be determined, the object is compared as
a String. The sort attribute is required for a column to be shown
as sortable.
|
onKeyPress | false | false | java.lang.String | Scripting code executed when the user presses and releases a key while the component has focus. |
severity | false | false | java.lang.String | Use the severity attribute when including the webuijsf:alarm
component in a column, to match the severity of the alarm. Valid values are
described in the webuijsf:alarm documentation. When the
severity attribute is set in the tableColumn, the table
component renders sort tool tips to indicate that the column will be sorted
least/most severe first, and the table cell appears hightlighted according to
the level of severity. This functionality is overridden by the
emptyCell attribute.
|
rendered | false | false | java.lang.String | Use the rendered attribute to indicate whether the HTML code for the component should be included in the rendered HTML page. If set to false, the rendered HTML page does not include the HTML for the component. If the component is not rendered, it is also not processed on any subsequent form submission. |
rowHeader | false | false | java.lang.String | Use the
By default, most column cells are rendered by the table component with HTML
When you set the |
id | false | true | java.lang.String | No Description |
onKeyUp | false | false | java.lang.String | Scripting code executed when the user releases a key while the component has focus. |
onMouseUp | false | false | java.lang.String | Scripting code executed when the user releases a mouse button while the mouse pointer is on the component. |
styleClass | false | false | java.lang.String | CSS style class(es) to be applied to the outermost HTML element when this component is rendered. |
descending | false | false | java.lang.String | Use the descending attribute to specify that the first
user-applied sort is descending. By default, the first time a user clicks a
column's sort button or column header, the sort is ascending. Note that this
not an initial sort. The data is initially displayed unsorted.
|
embeddedActions | false | false | java.lang.String | Set the embeddedActions attribute to true when the column includes
more than one embedded action. This attribute causes a separator image to be
displayed between the action links. This attribute is overridden by the
emptyCell attribute.
|
height | false | false | java.lang.String | The number of pixels for the cell's height. Styles should be used to specify cell height when possible because the height attribute is deprecated in HTML 4.0. |
footerText | false | false | java.lang.String | The text to be displayed in the column footer. |
align | false | false | java.lang.String | Use the align attribute to specify the horizontal alignment for
the content of each cell in the column. Valid values are left ,
center , right , justify , and
char . The default alignment is left . Setting the
align attribute to char causes the cell's contents
to be aligned on the character that you specify with the char
attribute. For example, to align cell contents on colons, set
align="char" and char=":" Some browsers do not
support aligning on the character.
|
scope | false | false | java.lang.String | Use the scope attribute to specify that the data cells of the
column are also acting as headers for rows or other columns of the table.
This attribute supports assistive technologies by enabling them to determine
the order in which to read the cells. Valid values include:
|
style | false | false | java.lang.String | CSS style(s) to be applied to the outermost HTML element when this component is rendered. |
sortImageURL | false | false | java.lang.String | Absolute or relative URL to the image used for the sort button that is displayed in the column header. |
onClick | false | false | java.lang.String | Scripting code executed when a mouse click occurs over this component. |
sortIcon | false | false | java.lang.String | The theme identifier to use for the sort button that is displayed in the column header. Use this attribute to override the default image. |
onMouseDown | false | false | java.lang.String | Scripting code executed when the user presses a mouse button while the mouse pointer is on the component. |
toolTip | false | false | java.lang.String | Sets the value of the title attribute for the HTML element. The specified text will display as a tooltip if the mouse cursor hovers over the HTML element. |
alignKey | false | false | java.lang.String | Use the alignKey attribute to specify the FieldKey id or FieldKey
to be used as an identifier for a specific data element on which to align the
table cell data in the column. If alignKey specifies a
FieldKey, the FieldKey is used as is; otherwise, a FieldKey is created using
the alignKey value that you specify. Alignment is based on
the object type of the data element. For example, Date and Number objects are
aligned "right", Character and String objects are aligned "left", and Boolean
objects are aligned "center". All columns, including select columns, are
aligned "left" by default. Note that the align property overrides this value.
|
valign | false | false | java.lang.String | Use the valign attribute to specify the vertical alignment for the
content of each cell in the column. Valid values are top ,
middle , bottom , and baseline . The
default vertical alignment is middle . Setting the
valign attribute to baseline causes the first line of
each cell's content to be aligned on the text baseline, the invisible line on
which text characters rest.
|
noWrap | false | false | java.lang.String | Use the noWrap attribute to disable word wrapping of this column's
cells in visual browsers. Word wrap can cause unnecessary horizontal scrolling
when the browser window is small in relation to the font size. Styles
should be used to disable word wrap when possible because the nowrap attribute
is deprecated in HTML 4.0.
|
onMouseOut | false | false | java.lang.String | Scripting code executed when a mouse out movement occurs over this component. |
onMouseOver | false | false | java.lang.String | Scripting code executed when the user moves the mouse pointer into the boundary of this component. |
onMouseMove | false | false | java.lang.String | Scripting code executed when the user moves the mouse pointer while over the component. |
emptyCell | false | false | java.lang.String | Use the emptyCell attribute to cause a theme-specific image to be
displayed when the content of a table cell is not applicable or is unexpectedly
empty. You should not use this attribute for a value that is truly null, such
as an empty alarm cell or a comment field that is blank. In addition, the image
should not be used for cells that contain user interface elements such as
checkboxes or drop-down lists when these elements are not applicable. Instead,
the elements should simply not be displayed so the cell is left empty.
|
visible | false | false | java.lang.String | 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. |
onKeyDown | false | false | java.lang.String | Scripting code executed when the user presses down on a key while the component has focus. |
headerText | false | false | java.lang.String | The text to be displayed in the column header. |
Variables | No Variables Defined. |
| |||||||
FRAMES NO FRAMES |