Ejemplo n.º 1
0
 /**
  * Validate reference existence before retrieving file
  *
  * @param ReferenceInterface $reference
  * @param $filePath
  *
  * @return $this
  */
 private function validateReference(ReferenceInterface $reference, $filePath)
 {
     if ($this->options[self::VALIDATE_REFERENCE] && !file_exists($filePath)) {
         $container = $reference->getSource()->load();
         $this->writePhpFile($filePath, $container);
     }
     return $this;
 }