Cron.
More...
|
| before ($interval,\DateTime $time=null) |
| Execute commands before cron interval is run. More...
|
|
| execute ($interval,\DateTime $time=null) |
| Execute handlers attached to a specific cron interval. More...
|
|
| after ($output, $interval) |
| Printers handler result. More...
|
|
| cronLog ($setting, $interval, $msg= '') |
| Log the results of a cron interval. More...
|
|
Cron.
Definition at line 16 of file Cron.php.
Constructor.
- Parameters
-
Definition at line 46 of file Cron.php.
Elgg\Cron::after |
( |
|
$output, |
|
|
|
$interval |
|
) |
| |
|
protected |
Printers handler result.
- Parameters
-
string | $output | Output string |
string | $interval | Interval name |
- Returns
- void
Definition at line 166 of file Cron.php.
Elgg\Cron::before |
( |
|
$interval, |
|
|
\DateTime |
$time = null |
|
) |
| |
|
protected |
Execute commands before cron interval is run.
- Parameters
-
string | $interval | Interval name |
\DateTime | $time | Time of the cron initialization |
- Returns
- void
Definition at line 101 of file Cron.php.
Elgg\Cron::cronLog |
( |
|
$setting, |
|
|
|
$interval, |
|
|
|
$msg = '' |
|
) |
| |
|
protected |
Log the results of a cron interval.
- Parameters
-
string | $setting | 'output'|'completion' |
string | $interval | Interval name |
string | $msg | Logged message |
- Returns
- void
Definition at line 187 of file Cron.php.
Elgg\Cron::execute |
( |
|
$interval, |
|
|
\DateTime |
$time = null |
|
) |
| |
|
protected |
Execute handlers attached to a specific cron interval.
- Parameters
-
string | $interval | Cron interval to execute |
\DateTime | $time | Time of cron initialization |
- Returns
- string
Definition at line 128 of file Cron.php.
Elgg\Cron::getConfiguredIntervals |
( |
bool |
$only_names = false | ) |
|
Get the cron interval configuration.
- Parameters
-
bool | $only_names | Only return the names of the intervals |
- Returns
- array
- Since
- 3.2
Definition at line 234 of file Cron.php.
Elgg\Cron::getLog |
( |
|
$setting, |
|
|
|
$interval |
|
) |
| |
Get the log contents of a cron interval.
- Parameters
-
string | $setting | 'output'|'completion' |
string | $interval | Interval name |
- Returns
- string
Definition at line 207 of file Cron.php.
Elgg\Cron::run |
( |
array |
$intervals = null , |
|
|
|
$force = false |
|
) |
| |
Executes handlers for periods that have elapsed since last cron.
- Parameters
-
array | $intervals | Interval names to run |
bool | $force | Force cron jobs to run even they are not yet due |
- Returns
- Job[]
- Exceptions
-
Definition at line 59 of file Cron.php.
Elgg\Cron::$default_intervals |
|
protected |
Initial value:= [
'minute' => '* * * * *'
Definition at line 24 of file Cron.php.
The documentation for this class was generated from the following file: