public class RecurringTask extends Object
Constructor and Description |
---|
RecurringTask(ServerContext serverContext,
TaskScheduler taskScheduler,
Entry recurringTaskEntry)
Creates a new recurring task based on the information in the provided entry.
|
Modifier and Type | Method and Description |
---|---|
Entry |
getRecurringTaskEntry()
Retrieves the entry containing the data for this recurring task.
|
Dn |
getRecurringTaskEntryDN()
Retrieves the DN of the entry containing the data for this recurring task.
|
String |
getRecurringTaskID()
Retrieves the unique ID assigned to this recurring task.
|
String |
getTaskClassName()
Retrieves the fully-qualified name of the Java class that provides the implementation logic for this recurring
task.
|
static void |
parseTaskTab(String taskSchedule)
Parse and validate recurring task schedule.
|
static boolean[] |
parseTaskTabField(String tabField,
int minValue,
int maxValue)
Parse and validate recurring task schedule field.
|
Task |
scheduleNextIteration(GregorianCalendar calendar)
Schedules the next iteration of this recurring task for processing.
|
public RecurringTask(ServerContext serverContext, TaskScheduler taskScheduler, Entry recurringTaskEntry) throws LdapException
serverContext
- The server context.taskScheduler
- A reference to the task scheduler that may be used to schedule new tasks.recurringTaskEntry
- The entry containing the information to use to define the task to process.LdapException
- If the provided entry does not contain a valid recurring task definition.public String getRecurringTaskID()
public Dn getRecurringTaskEntryDN()
public Entry getRecurringTaskEntry()
public String getTaskClassName()
public Task scheduleNextIteration(GregorianCalendar calendar) throws LdapException
calendar
- date and time to schedule next iteration from.LdapException
- to indicate an error.public static void parseTaskTab(String taskSchedule) throws LdapException
taskSchedule
- recurring task schedule tab in crontab(5) format.LdapException
- to indicate an error.public static boolean[] parseTaskTabField(String tabField, int minValue, int maxValue) throws IllegalArgumentException
tabField
- recurring task schedule field in crontab(5) format.minValue
- minimum value allowed for this field.maxValue
- maximum value allowed for this field.IllegalArgumentException
- if tab field is invalid.Copyright 2010-2022 ForgeRock AS.