|
Rice Pastry API | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface Processor
Provides a mechanism to do time consuming tasks off of FreePastry's selecto thread. Usually acquired by calling environment.getProcessor().
Method Summary | ||
---|---|---|
void |
destroy()
Shuts down the processing thread. |
|
|
process(Executable<R,E> task,
Continuation<R,E> command,
int priority,
SelectorManager selector,
TimeSource ts,
LogManager log)
Schedules a job for processing on the dedicated processing thread. |
|
|
process(Executable<R,E> task,
Continuation<R,E> command,
SelectorManager selector,
TimeSource ts,
LogManager log)
Schedules a job for processing on the dedicated processing thread. |
|
Cancellable |
processBlockingIO(WorkRequest request)
Schedules a different type of task. |
Method Detail |
---|
<R,E extends java.lang.Exception> Cancellable process(Executable<R,E> task, Continuation<R,E> command, SelectorManager selector, TimeSource ts, LogManager log)
task
- The task to run on the processing threadcommand
- The command to return the result to once it's done<R,E extends java.lang.Exception> Cancellable process(Executable<R,E> task, Continuation<R,E> command, int priority, SelectorManager selector, TimeSource ts, LogManager log)
priority
- lower number is higher priority, 0 is default priority, and negative numbers are high prioritytask
- The task to run on the processing threadcommand
- The command to return the result to once it's doneCancellable processBlockingIO(WorkRequest request)
request
- void destroy()
destroy
in interface Destructable
|
Rice Pastry API | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |