public class SchedulerMixin extends Object implements Scheduler, ServiceActivation
| Modifier and Type | Class and Description |
|---|---|
static class |
SchedulerMixin.ScheduleRunner
|
ServiceActivation.ServiceActivator| Constructor and Description |
|---|
SchedulerMixin() |
| Modifier and Type | Method and Description |
|---|---|
void |
activateService()
Called after ServiceComposite Activation.
|
static String |
getSchedulesIdentity(SchedulerService service) |
void |
passivateService()
Called before ServiceComposite Passivation.
|
Schedule |
scheduleCron(Task task,
String cronExpression,
boolean durable)
Schedule a Task using a CronExpression.
|
Schedule |
scheduleCron(Task task,
String cronExpression,
DateTime start,
boolean durable)
Schedule a Task using a CronExpression starting at a given date.
|
Schedule |
scheduleCron(Task task,
String cronExpression,
long initialDelay,
boolean durable)
Schedule a Task using a CronExpression with a given initial delay in milliseconds.
|
Schedule |
scheduleOnce(Task task,
DateTime runAt,
boolean durable)
Schedule a Task to be run after a given initial delay in seconds.
|
Schedule |
scheduleOnce(Task task,
int initialSecondsDelay,
boolean durable)
Schedule a Task to be run after a given initial delay in seconds.
|
public Schedule scheduleOnce(Task task, int initialSecondsDelay, boolean durable)
SchedulerscheduleOnce in interface Schedulertask - Task to be scheduled onceinitialSecondsDelay - Initial delay the Task will be run after, in secondsdurable - true if this Schedule should survive a restart.public Schedule scheduleOnce(Task task, DateTime runAt, boolean durable)
SchedulerscheduleOnce in interface Schedulertask - Task to be scheduled oncerunAt - The future point in time when the Schedule will be run.durable - true if this Schedule should survive a restart.public Schedule scheduleCron(Task task, String cronExpression, boolean durable)
SchedulerscheduleCron in interface Schedulertask - Task to be scheduled oncecronExpression - CronExpression for creating the Schedule for the given Taskdurable - true if this Schedule should survive a restart.public Schedule scheduleCron(Task task, String cronExpression, DateTime start, boolean durable)
SchedulerscheduleCron in interface Schedulertask - Task to be scheduled oncecronExpression - CronExpression for creating the Schedule for the given Taskstart - Date from which the Schedule will become activedurable - true if this Schedule should survive a restart.public Schedule scheduleCron(Task task, String cronExpression, long initialDelay, boolean durable)
SchedulerscheduleCron in interface Schedulertask - Task to be scheduled oncecronExpression - CronExpression for creating the Schedule for the given TaskinitialDelay - Initial delay the Schedule will be active after, in millisecondsdurable - true if this Schedule should survive a restart.public void activateService()
throws Exception
ServiceActivationactivateService in interface ServiceActivationExceptionpublic static String getSchedulesIdentity(SchedulerService service)
public void passivateService()
throws Exception
ServiceActivationpassivateService in interface ServiceActivationException