コード例 #1
0
 /**
  * Import templates.
  *
  * @throws Exception
  */
 protected function processTemplates()
 {
     if ($templates = $this->getFormattedTemplates()) {
         $templateImporter = new CTemplateImporter($this->options, $this->referencer);
         $templateImporter->import($templates);
     }
 }
コード例 #2
0
 /**
  * Import templates.
  *
  * @throws Exception
  */
 protected function processTemplates()
 {
     if ($this->options['templates']['updateExisting'] || $this->options['templates']['createMissing']) {
         $templates = $this->getFormattedTemplates();
         if ($templates) {
             $templateImporter = new CTemplateImporter($this->options, $this->referencer, $this->importedObjectContainer);
             $templateImporter->import($templates);
             // get list of imported template IDs and add them processed template ID list
             $templateIds = $templateImporter->getProcessedTemplateIds();
             $this->importedObjectContainer->addTemplateIds($templateIds);
         }
     }
 }