|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
public interface ContinuationConfigInstrument
This interface needs to be implemented to configure the bytecode instrumentation that enables the continuations functionalities.
| Method Summary | |
|---|---|
String |
getAnswerMethodName()
The name of the method that will trigger the answer to a call continuation, for instance "answer". |
Class[] |
getCallMethodArgumentTypes()
The array argument types that the call method takes, for instance new Class[] {String.class}. |
String |
getCallMethodName()
The name of the method that will trigger a call continuation, for instance "call". |
Class |
getCallMethodReturnType()
The return type of the call method, for instance Object.class. |
String |
getContinuableMarkerInterfaceName()
The name of the interface that will indicate that a class should be instrumented for continuations functionalities, for instance ContinuableObject.class.getName(). |
String |
getContinuableSupportClassName()
The class name of the support class that contains dummy implementations of the continuation methods that are configured below, for instance ContinuableSupport.class.getName(). |
Class[] |
getEntryMethodArgumentTypes()
The array argument types that the entry method takes, for instance null if it takes none. |
String |
getEntryMethodName()
The name of the entry method that will be invoked when a new instance of a continuable class is created and its execution is started, for instance "execute". |
Class |
getEntryMethodReturnType()
The return type of the entry method, for instance void.class. |
String |
getPauseMethodName()
The name of the method that will trigger a pause continuation, for instance "pause". |
String |
getStepbackMethodName()
The name of the method that will trigger a step-back continuation, for instance "stepback". |
| Method Detail |
|---|
String getContinuableMarkerInterfaceName()
ContinuableObject.class.getName().
String getContinuableSupportClassName()
ContinuableSupport.class.getName().
If you implement these methods in your continuable classes or extend
these classes from a common base class with those methods that are then
called locally, this configuration can return null since it
will not be used. A class name only needs to be provided if your
continuable classes only implement the marker interface, and you call
the continuation methods on an instance of this support inside your
continuations logic.
null if such a support class isn't used
String getEntryMethodName()
"execute".
Class getEntryMethodReturnType()
void.class.
This will solely be used to detect and lookup the method before instrumenting or calling it.
Class[] getEntryMethodArgumentTypes()
null if it takes none.
This will solely be used to detect and lookup the method before instrumenting or calling it.
null if there are noneString getPauseMethodName()
"pause".
This method should have a void return type and take no
arguments.
String getStepbackMethodName()
"stepback".
This method should have a void return type and take no
arguments.
String getCallMethodName()
"call".
Class getCallMethodReturnType()
Object.class.
This needs to be an object, not a primitive and you have to be
certain that it's compatible with the values that are sent through the
answer to the call continuation. It's just recommended to keep this as
generic as possible (hence Object.class).
Class[] getCallMethodArgumentTypes()
new Class[] {String.class}.
This needs to be a single object argument, not more or less than one,
and not a primitive. You will use this yourself in the implementation
of the runner that executes the continuations. If the
BasicContinuableRunner is
used, CallTargetRetriever will
be used to resolve the target of the call continuation by using the
what's provided as the argument of the method call.
String getAnswerMethodName()
"answer".
This method should have a void return type and take one
argument with the type java.lang.Object.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||