Christopher Oliver wrote:
I think you're right that "continuation local" variables are needed to make implementing pagination easy. I just prototyped something as follows:
I created a page-local scope associated with the current continuation of sendPageAndWait accessible as "cocoon.page".
Anything assigned to cocoon.page will be stored in the continuation and retain the same values when the continuation is resumed (after sendPageAndWait()).
Very nice! Clever use of Rhino scopes can do wonders.
I found one problem... Patch uses lastContinuation, but it is not set by:
public FOM_WebContinuation makeWebContinuation(Continuation k,
FOM_WebContinuation parent,
int timeToLive)
Any objections to change it to populate lastContinuation?
Vadim
