Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Icefaces ace:dataTable lazy loading

Is there anybody who have a little example of a lazy loading with ace:dataTable?.. I can't understand how to implement the load method of the class LazyDataModel.. and how to fetch data from a Database through this method..

thanks!

like image 668
afterbit Avatar asked Jul 03 '26 02:07

afterbit


1 Answers

ace:dataTable has already a "built in" lazy loading mechanism in ICEFaces (at least for release 3.x and up).

No need to extend an AbstractList for this anymore.

All you need to do is add the lazy="true" to your tag, and make sure the "value" attribute points to a class that extends LazyDataModel... you just need to implement the abstract method there that accepts start page, page size, sorting & filtering arguments.

Also don't forget to use pagination and determine the size of the page ("rows" attribute).

Check: ICEFaces docs Ver. 3 ace:dataTable

like image 109
Nir M. Avatar answered Jul 05 '26 16:07

Nir M.



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!