Пример #1
0
 /**
  * @param string     $expression
  * @param array|null $body
  */
 public function __construct($expression, $body = null)
 {
     $di = $this->getDI();
     if (!$di instanceof \Phalcon\DiInterface) {
         throw new CronException("A dependency injection object is required to access internal services");
     }
     parent::__construct($expression);
     $this->body = $body;
 }
Пример #2
0
 /**
  * @param string   $expression
  * @param callable $callback
  */
 public function __construct($expression, callable $callback)
 {
     parent::__construct($expression);
     $this->callback = $callback;
 }
Пример #3
0
 /**
  * @param string $expression
  * @param string $command
  * @param string $output
  */
 public function __construct($expression, $command, $output = null)
 {
     parent::__construct($expression);
     $this->command = $command;
     $this->output = $output;
 }