public class JobControl extends Object implements Runnable
构造器和说明 |
---|
JobControl(String groupName)
Construct a job control for a group of jobs.
|
限定符和类型 | 方法和说明 |
---|---|
String |
addJob(Job aJob)
Add a new job.
|
void |
addJobs(Collection<Job> jobs)
Add a collection of jobs
|
boolean |
allFinished() |
ArrayList<Job> |
getFailedJobs() |
ArrayList<Job> |
getReadyJobs() |
ArrayList<Job> |
getRunningJobs() |
int |
getState() |
ArrayList<Job> |
getSuccessfulJobs() |
ArrayList<Job> |
getWaitingJobs() |
void |
resume()
resume the suspended thread
|
void |
run()
The main loop for the thread.
|
void |
stop()
set the thread state to STOPPING so that the
thread will stop when it wakes up.
|
void |
suspend()
suspend the running thread
|
public JobControl(String groupName)
groupName
- a name identifying this grouppublic void addJobs(Collection<Job> jobs)
jobs
- public int getState()
public void stop()
public void suspend()
public void resume()
public boolean allFinished()
Copyright © 2009 The Apache Software Foundation