Package org.apache.sling.event.jobs
Interface ScheduledJobInfo
-
@ProviderType public interface ScheduledJobInfo
Information about a scheduled job- Since:
- 1.3
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description java.util.Map<java.lang.String,java.lang.Object>
getJobProperties()
Return the optional job topics.java.lang.String
getJobTopic()
Return the job topic.java.util.Date
getNextScheduledExecution()
Return the next scheduled execution date.java.util.Collection<ScheduleInfo>
getSchedules()
Get all schedules for this jobboolean
isSuspended()
Is the processing currently suspended?JobBuilder.ScheduleBuilder
reschedule()
Reschedule this job with a new rescheduling information.void
resume()
Resume job processing.void
suspend()
Suspend this job scheduling.void
unschedule()
Unschedule this scheduled job.
-
-
-
Method Detail
-
getSchedules
java.util.Collection<ScheduleInfo> getSchedules()
Get all schedules for this job- Returns:
- A non null and non empty list of schedules.
-
getNextScheduledExecution
java.util.Date getNextScheduledExecution()
Return the next scheduled execution date.- Returns:
- the next scheduled execution date.
-
getJobTopic
java.lang.String getJobTopic()
Return the job topic.- Returns:
- The job topic
-
getJobProperties
java.util.Map<java.lang.String,java.lang.Object> getJobProperties()
Return the optional job topics.- Returns:
- The job topics or
null
-
unschedule
void unschedule()
Unschedule this scheduled job.
-
reschedule
JobBuilder.ScheduleBuilder reschedule()
Reschedule this job with a new rescheduling information. If rescheduling fails (due to wrong arguments), the job schedule is left as is.- Returns:
- The schedule builder
-
suspend
void suspend()
Suspend this job scheduling. Job scheduling can be resumed withresume()
. This information is persisted and survives a restart.
-
resume
void resume()
Resume job processing.suspend()
. If the queue is not suspended, calling this method has no effect.
-
isSuspended
boolean isSuspended()
Is the processing currently suspended?- Returns:
true
if processing is suspended.
-
-