PhotoAlbum Application Download Support Developer Guide
Skins:
Resources/Beans Handling
Ajax Miscellaneous
Usage
Extended Data Model
Modifiable Data Model
Edit Table with ModalPanel
Tag Information

Perhaps the most obvious problem of DataTable and javax.faces.model.DataModel is lack of support for more complicated scenarios that use data from the database. To solve this problem Richfaces has two major tools:

  • A set of data-driven components that render data sets in various ways (rich:dataTable , rich:dataGrid, rich:dataList, a4j:repeat etc.). All these components derive their common functionality from the common core that in addition to standard javax.faces.model.DataModel, can understand and use
  • extended data model classes org.ajax4jsf.model.ExtendedDataModel and org.ajax4jsf.model.SerializableDataModel. These two classes work together to provide functions that missing in the standard DataModel.
The most important additional functions are:
  • access for rows by primary keys instead of index position
  • implementation of "visitor" pattern over the "range" of rows to support "table scroller" or "paginator" functions
  • ability to serialize table data, so it can be used on post-back processing without additional database query
To use these extensions you need to implement your own DataModel that extends one of our ExtendedDataModel classes and implement some of important functions. Below there is an example of such implementation.

«««12345»»»
Description
Highest Bid
Your Bid
Amount
100x Ultra Bright Red LEDs, 5mm, Clear$66.00
Place a bid!
NEW 30pcs HEAT SINKS ,50pcs insulation bushing and film$71.00
Place a bid!
100x Ultra Bright Red LEDs, 5mm, Clear$13.00
Place a bid!
100x Ultra Bright Green LEDs, 5mm, Clear$68.00
Place a bid!
100x Ultra Bright Blue LEDs, 5mm, Clear$21.00
Place a bid!
NEW 30pcs HEAT SINKS ,50pcs insulation bushing and film$65.00
Place a bid!
100x Ultra Bright Yellow LEDs, 5mm, Clear$77.00
Place a bid!
100x Ultra Bright White LEDs, 5mm, Clear$54.00
Place a bid!
Lot of 10pcs 8x8 dot-matrix 3mm dia LED display bicolor$35.00
Place a bid!
100x Ultra Bright White LEDs, 5mm, Clear$19.00
Place a bid!


View Source


View AuctionDataModel.java Source
RichFaces Wiki RichFaces Project Site