Read-only snapshot of a JsSchedule, returned to app JavaScript by JsScheduler's schedule, getSchedule, find and getSchedules methods. Wraps the persisted schedule's identity, timing configuration and target function name so a script can inspect a schedule without touching the Hibernate entity directly.
Properties
| Property | Returns | Description |
|---|---|---|
| function | String | Name of the JavaScript function that is invoked when this schedule fires. |
| id | long | Database identifier of the underlying JsSchedule row. |
| name | String | Unique name the schedule was created with, used to look it up again via JsScheduler.find. |
| nextDueDate | Date | Date and time the schedule is next due to fire, as calculated when it was created or last run. |
| scheduleType | String | Whether this schedule repeats or fires only once, one of REPEAT or ONE_TIME. |
| timerMultiple | Integer | Number of timer units between each firing of a repeating schedule, e.g. 3 for "every 3 DAYS". |
| timerTime | String | Time of day the schedule is due to run, e.g. "12:00 am". |
| timerUnit | String | Unit the repeat interval is measured in, one of MINUTES, HOURS, DAYS, WEEKS, MONTHS or ANNUAL. |
Methods
getId() · getName() · getNextDueDate() · getTimerUnit() · getTimerMultiple() · getTimerTime() · getFunction() · getScheduleType() · delete()
getId()
Returns: long
Database identifier of the underlying JsSchedule row.
getName()
Returns: String
Unique name the schedule was created with, used to look it up again via JsScheduler.find.
getNextDueDate()
Returns: Date
Date and time the schedule is next due to fire, as calculated when it was created or last run.
getTimerUnit()
Returns: String
Unit the repeat interval is measured in, one of MINUTES, HOURS, DAYS, WEEKS, MONTHS or ANNUAL.
getTimerMultiple()
Returns: Integer
Number of timer units between each firing of a repeating schedule, e.g. 3 for "every 3 DAYS".
getTimerTime()
Returns: String
Time of day the schedule is due to run, e.g. "12:00 am".
getFunction()
Returns: String
Name of the JavaScript function that is invoked when this schedule fires.
getScheduleType()
Returns: String
Whether this schedule repeats or fires only once, one of REPEAT or ONE_TIME.
delete()
Returns: void
Deletes this schedule