WordPress at Your Fingertips
function is not described

ActionScheduler_ActionFactory::single() public WC 1.0

{} It's a method of the class: ActionScheduler_ActionFactory{}

No Hooks.

Return

Int. The ID of the stored action

Usage

$ActionScheduler_ActionFactory = new ActionScheduler_ActionFactory();
$ActionScheduler_ActionFactory->single( $hook, $args, $when, $group );
$hook(string) (required)
The hook to trigger when this action runs
$args(array)
Args to pass when the hook is triggered
Default: array()
$when(int)
Unix timestamp when the action will run
Default: null
$group(string)
A group to put the action in
Default: ''

Code of ActionScheduler_ActionFactory::single() WC 6.1.1

public function single( $hook, $args = array(), $when = null, $group = '' ) {
	$date = as_get_datetime_object( $when );
	$schedule = new ActionScheduler_SimpleSchedule( $date );
	$action = new ActionScheduler_Action( $hook, $args, $schedule, $group );
	return $this->store( $action );
}