ActionScheduler_SimpleSchedule

ActionScheduler_SimpleSchedule represents a one-time schedule that runs at a single date/time and never recurs.

Class definition

class ActionScheduler_SimpleSchedule extends ActionScheduler_Abstract_Schedule {
	public function calculate_next( DateTime $after );
	public function is_recurring();
	public function __sleep();
	public function __wakeup();
}

When it’s used

Use this schedule for a single action scheduled at a specific DateTime.

Next-run calculation

  • calculate_next() always returns null because one-time schedules do not recur.
  • get_next( DateTime $after ) (from ActionScheduler_Abstract_Schedule) will return:
    • the original scheduled date if $after is before or equal to the scheduled date
    • null if $after is later than the scheduled date (because calculate_next() returns null)

Recurrence

  • is_recurring() returns false.

Serialization compatibility

__sleep() and __wakeup() preserve compatibility with schedules serialized before Action Scheduler 3.0.0 by mapping legacy property names (timestamp) to the unified schedule properties.