|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectplay.Invoker
public class Invoker
Run some code in a Play! context
| Nested Class Summary | |
|---|---|
static class |
Invoker.DirectInvocation
A direct invocation (in the same thread than caller) |
static class |
Invoker.Invocation
An Invocation in something to run in a Play! context |
static class |
Invoker.InvocationContext
The class/method that will be invoked by the current operation |
static class |
Invoker.Suspend
Throwable to indicate that the request must be suspended |
| Field Summary | |
|---|---|
static java.util.concurrent.ScheduledThreadPoolExecutor |
executor
Main executor for requests invocations. |
| Constructor Summary | |
|---|---|
Invoker()
|
|
| Method Summary | |
|---|---|
static java.util.concurrent.Future<?> |
invoke(Invoker.Invocation invocation)
Run the code in a new thread took from a thread pool. |
static java.util.concurrent.Future<?> |
invoke(Invoker.Invocation invocation,
long millis)
Run the code in a new thread after a delay |
static void |
invokeInThread(Invoker.DirectInvocation invocation)
Run the code in the same thread than caller. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static java.util.concurrent.ScheduledThreadPoolExecutor executor
| Constructor Detail |
|---|
public Invoker()
| Method Detail |
|---|
public static java.util.concurrent.Future<?> invoke(Invoker.Invocation invocation)
invocation - The code to run
public static java.util.concurrent.Future<?> invoke(Invoker.Invocation invocation,
long millis)
invocation - The code to runmillis - The time to wait before, in milliseconds
public static void invokeInThread(Invoker.DirectInvocation invocation)
invocation - The code to run
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||