The containers are interchangeable, so you should be able to use Lazy Query Container with either grid or table instead of beanitemcontainer in your snippet above.
I’m doing lazy loading with Grid, although I’m using my own lazy-loading container instead of the add-on conntainers I linked to.
Points to the own container.
Key methods what you need to implement are
size(), getIdByIndex(int) and getItemIds(int, int)
This way you get full control of item loading and can keep container very light weight.
Hi Jenk,
Number of visible rows is usually auto calculated when you use default height mode (
https://vaadin.com/api/com/vaadin/shared/ui/grid/HeightMode.html#CSS ).
Calculation magic only needs number of total rows thats why it is important implementa size method to the container.
Client side Grid does call to server RPC automaticly when user scroll grid in browser up or down and fetch objects that way for object feching only thing what you have to do is just implement container and in it fetch items lazy way.
This vaadin webinar does use Table but Container usage in Table and Grid is quite same(in server side) and there is coding examples how you can implement it by using lazy-containenr
https://www.youtube.com/watch?v=bH2_nWxwXY8