|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface TaskService
A TaskService provides functionality to execute and manage background tasks. All background tasks belong to a scope which defines the task's context and allows tasks belonging to a common scope to be managed together.
Method Summary | ||
---|---|---|
void |
addTaskListener(TaskListener l)
Add a listener to receive notifications about the activities of this task service. |
|
TaskExecutor<? extends Object> |
getExecutor()
Create a TaskExecutor with a default scope. |
|
|
getExecutor(TaskScope<R> scope)
Create a TaskExecutor for the given TaskScope . |
|
|
getExecutor(TaskScope<R> scope,
int priority)
Create a TaskExecutor for the given TaskScope . |
|
void |
removeTaskListener(TaskListener l)
Remove a listener previously installed to receive notifications about the activities of this task service. |
Method Detail |
---|
TaskExecutor<? extends Object> getExecutor()
TaskExecutor
with a default scope.
<R> TaskExecutor<R> getExecutor(TaskScope<R> scope)
TaskExecutor
for the given TaskScope
. Tasks will be executed with the
default priority.
scope
-
<R> TaskExecutor<R> getExecutor(TaskScope<R> scope, int priority)
TaskExecutor
for the given TaskScope
. Tasks will be executed with the
given priority.
scope
-
void removeTaskListener(TaskListener l)
l
- the listenervoid addTaskListener(TaskListener l)
l
- the listener
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |