Apache » Cocoon »

  Cocoon FlowScript

Cocoon FlowScript 1.0


A WebContinuation represents a continuation of a Flowscript. Because a user may click on the back button in the browser and restart a saved computation in a continuation, each WebContinuation becomes the parent of a subtree of continuations.

If there is no parent WebContinuation, the created continuation becomes the root of a tree of WebContinuations.

WebContinuation objects support the following functions and properties:


Property [String] id

Returns the unique string identifier of this Web Continuation.


Property [Continuation] continuation

Returns the JavaScript continuation associated with this Web Continuation.


Property [WebContinuation] previousBookmark

Returns a reference to the first bookmark continuation among the pages preceding the one associated with this object, or null if no such bookmark continuation exists. The returned object is the continuation you would invoke to implement a "Back" button.


Function [Boolean] isBookmark()

Returns true if this continuation was not created by sendPageAndWait.


Function [WebContinuation] getParent()

Get the parent continuation of this continuation.


Function [Array [WebContinuation]] getChildren()

Get the child continuations of this continuation.


Function invalidate()

Invalidates a WebContinuation. This effectively means that the continuation object associated with it will no longer be accessible from Web pages. Invalidating a WebContinuation invalidates all the WebContinuations which are children of it.

Errors and Improvements? If you see any errors or potential improvements in this document please help us: View, Edit or comment on the latest development version (registration required).