dataProvider, supply new data per page

Normally you submit an array/model to dataProvider, and you can browse trough it with cGridview/cListview. In my case, the data comes from an external search index, I have to request each page separately from the server, so I can’t supply all the data at once.

What I want is to load a new set of data in dataProvider when you use pagination/sorting, is this possible?

I fixed it by copying CArrayDataProvider.php to my components directory, changed file/class name to my custom one, included it in the main config under components and removing the paging/sorting logic, works great.