static class StatusJob.Task extends Object
Modifier and Type | Field and Description |
---|---|
private ScheduledFuture |
future
Task execution handler.
|
private StatusJob.Listener |
listener
Server status task execution listener for asynchronous
command execution.
|
private TaskStateListener[] |
listeners
All task listeners.
|
private StatusResult |
result
Last command task execution result.
|
private Runnable |
task
Task thread currently being executed.
|
Modifier | Constructor and Description |
---|---|
private |
StatusJob.Task(StatusJob.Listener listener)
Constructs an instance of individual job task.
|
Modifier and Type | Method and Description |
---|---|
void |
clearTaskFuture()
Clear task execution handler and thread currently being executed.
|
ScheduledFuture |
getFuture()
Get task execution handler.
|
(package private) StatusJob.Listener |
getListener()
Get server status task execution listener for asynchronous
command execution.
|
TaskStateListener[] |
getListeners()
Get all task listeners.
|
(package private) StatusResult |
getResult()
Get last command task execution result.
|
Runnable |
getTask()
Get task thread currently being executed.
|
void |
setFuture(ScheduledFuture future)
Set task execution handler.
|
(package private) void |
setListener(StatusJob.Listener listener)
Set server status task execution listener for asynchronous
command execution.
|
(package private) void |
setResult(StatusResult result)
Set last command task execution result.
|
void |
setTask(Runnable task)
Set task thread currently being executed.
|
void |
setTaskFuture(Runnable task,
ScheduledFuture future)
Set task execution handler and thread currently being executed.
|
private StatusJob.Listener listener
private StatusResult result
private Runnable task
private ScheduledFuture future
private TaskStateListener[] listeners
private StatusJob.Task(StatusJob.Listener listener)
listener
- Server status task execution listener
for asynchronous command execution.StatusJob.Listener getListener()
void setListener(StatusJob.Listener listener)
listener
- Server status task execution listener
for asynchronous command execution.StatusResult getResult()
void setResult(StatusResult result)
result
- Last command task execution result.public Runnable getTask()
public void setTask(Runnable task)
task
- Task thread currently being executed.public TaskStateListener[] getListeners()
public ScheduledFuture getFuture()
public void setFuture(ScheduledFuture future)
future
- Task execution handler.public void setTaskFuture(Runnable task, ScheduledFuture future)
task
- Task thread currently being executed.future
- Task execution handler.public void clearTaskFuture()
Copyright © 2013. All Rights Reserved.