Property | Type | Description | |
---|---|---|---|
$action | string | (default value: 'background_process') | |
$cron_hook_identifier | mixed | Cron_hook_identifier | |
$cron_interval_identifier | mixed | Cron_interval_identifier | |
$start_time | integer | (default value: 0) |
Method | Description | |
---|---|---|
__construct ( ) | Initiate new background process | |
cancel_process ( ) | Cancel Process | |
delete ( string $key ) | Delete queue | |
dispatch ( ) : void | Dispatch | |
handle_cron_healthcheck ( ) | Handle cron healthcheck | |
maybe_handle ( ) | Maybe process queue | |
push_to_queue ( mixed $data ) | Push to queue | |
save ( ) | Save queue | |
schedule_cron_healthcheck ( mixed $schedules ) : mixed | Schedule cron healthcheck | |
update ( string $key, array $data ) | Update queue |
Method | Description | |
---|---|---|
clear_scheduled_event ( ) | Clear scheduled event | |
complete ( ) | Complete. | |
generate_key ( integer $length = 64 ) : string | Generate key | |
get_batch ( ) : stdClass | Get batch | |
get_memory_limit ( ) : integer | Get memory limit | |
handle ( ) | Handle | |
is_process_running ( ) | Is process running | |
is_queue_empty ( ) : boolean | Is queue empty | |
lock_process ( ) | Lock process | |
memory_exceeded ( ) : boolean | Memory exceeded | |
schedule_event ( ) | Schedule event | |
task ( mixed $item ) : mixed | Task | |
time_exceeded ( ) : boolean | Time exceeded. | |
unlock_process ( ) | Unlock process |
public cancel_process ( ) |
protected complete ( ) |
protected generate_key ( integer $length = 64 ) : string | ||
$length | integer | Length. |
return | string |
protected get_batch ( ) : stdClass | ||
return | stdClass | Return the first batch from the queue |
protected get_memory_limit ( ) : integer | ||
return | integer |
protected handle ( ) |
public handle_cron_healthcheck ( ) |
protected is_process_running ( ) |
protected is_queue_empty ( ) : boolean | ||
return | boolean |
protected lock_process ( ) |
public maybe_handle ( ) |
protected memory_exceeded ( ) : boolean | ||
return | boolean |
public schedule_cron_healthcheck ( mixed $schedules ) : mixed | ||
$schedules | mixed | Schedules. |
return | mixed |
protected time_exceeded ( ) : boolean | ||
return | boolean |
protected unlock_process ( ) |
protected string $action | ||
return | string |
protected mixed $cron_hook_identifier | ||
return | mixed |
protected mixed $cron_interval_identifier | ||
return | mixed |