write() 공개 메소드

Write the current crons in the cron table
public write ( Crontab $crontab ) : CrontabFileHandler
$crontab Crontab
리턴 CrontabFileHandler
예제 #1
0
 /**
  * Save crons to file
  * 
  * @param string $file /path/to/file/
  */
 public function save()
 {
     $crontabFile = $this->getCrontabFile();
     if (!is_null($crontabFile)) {
         $this->crontabFileHandler->writeToFile($this->crontab, $crontabFile);
     } else {
         $this->crontabFileHandler->write($this->crontab);
     }
     return $this;
 }