Grid Control - Javabean Example

The <dotj:grid> tag also can use a Collection of Javabeans as its source of data. In the example below, we populate an ArrayList with FileBean objects. From there, the ArrayList can be passed directly to the grid via the datasrc attribute.

The grid below lists all the files in the /taglib directory, a rudimentary File Explorer!
Files
 
Filename Size (bytes) Last Modified
 
index.jsp 5,169 05/09/2005 02:18:23
  footer.inc 3,184 02/10/2004 02:35:32
  getSource.jsp 464 02/10/2004 02:37:51
  viewSource.jsp 827 02/10/2004 02:38:00
  upload.jsp 99 02/23/2004 09:19:13
  grid.jsp 99 02/23/2004 09:20:45
  form.jsp 99 03/20/2004 08:08:15
[ 1  ] Page 1 of 1
The above grid contains 7 records.

  Download Formatted Data

 FileBean.java   



          Back to Samples page


home : products : pricing : company : contact us : samples : download : forums : customers

Copyright © 2000-2004 dotJ Software Inc. All rights reserved.