org.apache.cocoon.components.flow
Interface ContinuationsManager


public interface ContinuationsManager

The interface of the Continuations manager. The continuation manager maintains a forrest of WebContinuation trees. Each tree defines the flow of control for a user within the application. A WebContinuation is created for a continuation object from the scripting language used. A continuation object in the implementation of the scripting language is an opaque object here. It is only stored inside the WebContinuation, without being interpreted in any way.

Since:
March 19, 2002
Version:
$Id: ContinuationsManager.html 1304280 2012-03-23 11:18:01Z ilgrosso $
See Also:
WebContinuation

Field Summary
static String ROLE
           
 
Method Summary
 WebContinuation createWebContinuation(Object kont, WebContinuation parentKont, int timeToLive, String interpreterId, ContinuationsDisposer disposer)
          Create a WebContinuation object given a native continuation object and its parent.
 void displayAllContinuations()
          Prints debug information about all web continuations into the log file.
 List getWebContinuationsDataBeanList()
          Get a list of all continuations as WebContinuationDataBean objects.
 void invalidateWebContinuation(WebContinuation k)
          Invalidates a WebContinuation.
 WebContinuation lookupWebContinuation(String id, String interpreterId)
          Given a WebContinuation id, retrieve the associated WebContinuation object.
 

Field Detail

ROLE

public static final String ROLE
Method Detail

createWebContinuation

public WebContinuation createWebContinuation(Object kont,
                                             WebContinuation parentKont,
                                             int timeToLive,
                                             String interpreterId,
                                             ContinuationsDisposer disposer)
Create a WebContinuation object given a native continuation object and its parent. If the parent continuation is null, the WebContinuation returned becomes the root of a tree in the forrest.

Parameters:
kont - an Object value
parentKont - a WebContinuation value
timeToLive - an int value indicating how long in seconds this continuation will live in the server if not accessed
interpreterId - id of interpreter invoking continuation creation
disposer - a ContinuationsDisposer instance to called when the continuation gets cleaned up.
Returns:
a WebContinuation value
See Also:
WebContinuation

invalidateWebContinuation

public void invalidateWebContinuation(WebContinuation k)
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.

Parameters:
k - a WebContinuation value

lookupWebContinuation

public WebContinuation lookupWebContinuation(String id,
                                             String interpreterId)
Given a WebContinuation id, retrieve the associated WebContinuation object.

Parameters:
id - a String value
interpreterId - Id of an interpreter that queries for the continuation
Returns:
a WebContinuation object, null if no such WebContinuation could be found. Also null if WebContinuation was found but interpreter id does not match the one that the continuation was initialy created for.

displayAllContinuations

public void displayAllContinuations()
Prints debug information about all web continuations into the log file.

See Also:
WebContinuation.display()

getWebContinuationsDataBeanList

public List getWebContinuationsDataBeanList()
Get a list of all continuations as WebContinuationDataBean objects.



Copyright 1999-2008 The Apache Software Foundation. All Rights Reserved.