コード例 #1
0
 /**
  * @param string $file
  * @throws \Exception
  */
 public function addConfiguration($file)
 {
     $fileName = GeneralUtility::getFileAbsFileName($file);
     if (!file_exists($fileName)) {
         return;
     }
     $configuration = Configuration::parse($fileName);
     if (!isset($this->configurations[$configuration->getIdentifier()])) {
         try {
             $this->configurations[$configuration->getIdentifier()] = $configuration;
             ModuleService::create()->assignModule($configuration);
         } catch (\Exception $exception) {
             // @todo Handle and output failed parsing process
             throw $exception;
         }
     }
 }
コード例 #2
0
 /**
  * Registers any sub-module below the main "Apps" module.
  *
  * @param Configuration $configuration
  */
 protected function registerSubModule(Configuration $configuration)
 {
     ExtensionUtility::registerModule('TYPO3Incubator.AppEngine', 'App', 'ID' . $configuration->getIdentifier(), '', array('App' => 'dispatch,invalid'), array('access' => 'user,group', 'icon' => $configuration->getValue('app.iconFile'), 'labels' => $configuration->getValue('app.labelFile')));
 }