public function register($name, $project) { if (empty($name)) { $name = md5($project->getConfigXml()->asXml()); $this->log->info("Automatic project name {$name} given."); $project->setName($name); } parent::register($name, $project); }
/** * @param string $name * @param object $task * * @throws Xinc::Core::Registry::RegistryException * @throws Xinc::Core::Validation::Exception::TypeMismatch */ public function register($name, $widget) { parent::register($name, $widget); $paths = $widget->getPaths(); if (!is_array($paths)) { $this->log->warn(get_class($widget) . '::getPaths has invalid return value.'); $paths = array(); } foreach ($paths as $path) { $this->paths[$path] = $widget; } }
/** * * @param string $name * @param object $task * @throws Xinc\Core\Registry\Exception */ public function register($name, $task) { parent::register($name, $task); $this->slot[$task->getPluginSlot()][$name] = $task; }