7 use Symfony\Component\Console\Input\InputOption;
18 $this->setName(
'cron')
19 ->setDescription(
elgg_echo(
'cli:cron:description'))
20 ->addOption(
'interval',
'i', InputOption::VALUE_OPTIONAL,
23 ->addOption(
'force',
'f', InputOption::VALUE_NONE,
26 ->addOption(
'time',
't', InputOption::VALUE_OPTIONAL,
36 $interval = $this->
option(
'interval');
52 elgg_log($e->getMessage(), LogLevel::ERROR);
if(! $annotation instanceof ElggAnnotation) $time
option($name)
Returns option value.
Abstract command with some utility methods.
elgg-cli cron [–interval] [–quiet]
command()
{Command to be executed.This method should return an integer code of the error (or 0 for success)....
A generic parent class for cron exceptions.
elgg_log($message, $level=\Psr\Log\LogLevel::NOTICE)
Log a message.
_elgg_services()
Get the global service provider.
elgg_echo(string $message_key, array $args=[], string $language='')
Elgg language module Functions to manage language and translations.
elgg_strtolower()
Wrapper function for mb_strtolower().