org.apache.ode.il
Class MockScheduler
java.lang.Object
org.apache.ode.il.MockScheduler
- All Implemented Interfaces:
- Scheduler
public class MockScheduler
- extends java.lang.Object
- implements Scheduler
Constructor Summary |
MockScheduler(javax.transaction.TransactionManager txm)
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
MockScheduler
public MockScheduler(javax.transaction.TransactionManager txm)
schedulePersistedJob
public java.lang.String schedulePersistedJob(java.util.Map<java.lang.String,java.lang.Object> detail,
java.util.Date dt)
throws ContextException
- Description copied from interface:
Scheduler
- Schedule a persisted job. Persisted jobs MUST survive system failure.
They also must not be scheduled unless the transaction associated with
the calling thread commits.
- Specified by:
schedulePersistedJob
in interface Scheduler
- Parameters:
detail
- information about the jobdt
- when the job should run (null
means now)
- Returns:
- unique job identifier
- Throws:
ContextException
cancelJob
public void cancelJob(java.lang.String arg0)
throws ContextException
- Description copied from interface:
Scheduler
- Make a good effort to cancel the job. If its already running no big
deal.
- Specified by:
cancelJob
in interface Scheduler
- Parameters:
arg0
- job identifier of the job
- Throws:
ContextException
start
public void start()
- Specified by:
start
in interface Scheduler
stop
public void stop()
- Specified by:
stop
in interface Scheduler
shutdown
public void shutdown()
- Specified by:
shutdown
in interface Scheduler
setJobProcessor
public void setJobProcessor(Scheduler.JobProcessor processor)
throws ContextException
- Specified by:
setJobProcessor
in interface Scheduler
- Throws:
ContextException
jobCompleted
public void jobCompleted(java.lang.String jobId)
- Specified by:
jobCompleted
in interface Scheduler