|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorc.orchard.Job
public final class Job
Standard implementation of a JobService. Extenders should only need to provide a constructor and override onFinish() to clean up any external resources.
| Nested Class Summary | |
|---|---|
static interface |
Job.FinishListener
Used to handle cleanup when the job finishes. |
| Constructor Summary | |
|---|---|
protected |
Job(Expr expression,
JobConfiguration configuration)
|
| Method Summary | |
|---|---|
void |
cancelPrompt(int promptID)
|
JobConfiguration |
configuration()
|
void |
finish()
|
java.util.List<JobEvent> |
getEvents(Waiter waiter)
Return events which occurred since the job started or purgeEvents was last called. |
java.util.Date |
getStartDate()
|
void |
halt()
|
void |
onFinish(Job.FinishListener f)
Register a listener to be called when the job finishes. |
void |
purgeEvents()
|
void |
respondToPrompt(int promptID,
java.lang.String response)
Submit a response to a prompt (initiated by the Prompt site). |
void |
setEventBufferSize(java.lang.Integer eventBufferSize)
|
void |
setStartDate(java.util.Date startDate)
|
void |
start()
|
java.lang.String |
state()
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
protected Job(Expr expression,
JobConfiguration configuration)
| Method Detail |
|---|
public void start()
throws InvalidJobStateException
InvalidJobStateExceptionpublic void finish()
public void onFinish(Job.FinishListener f)
public void halt()
public JobConfiguration configuration()
public java.util.List<JobEvent> getEvents(Waiter waiter)
throws java.lang.InterruptedException
java.lang.InterruptedExceptionpublic void purgeEvents()
public java.lang.String state()
public void setStartDate(java.util.Date startDate)
public java.util.Date getStartDate()
public void setEventBufferSize(java.lang.Integer eventBufferSize)
public void respondToPrompt(int promptID,
java.lang.String response)
throws InvalidPromptException
InvalidPromptException - if promptID is invalid
public void cancelPrompt(int promptID)
throws InvalidPromptException
InvalidPromptException
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||