Neos\Flow\Package\PackageManagerInterface::getPackage PHP Метод

getPackage() публичный Метод

A package is available, if the package directory contains valid meta information.
public getPackage ( string $packageKey ) : Neos\Flow\Package\PackageInterface
$packageKey string
Результат Neos\Flow\Package\PackageInterface
    public function getPackage($packageKey);

Usage Example

Пример #1
0
 /**
  * Set the routes configuration for the Neos setup and configures the routing component
  * to skip initialisation, which would overwrite the specific settings again.
  *
  * @param ComponentContext $componentContext
  * @return void
  */
 public function handle(ComponentContext $componentContext)
 {
     $configurationSource = $this->objectManager->get(\Neos\Flow\Configuration\Source\YamlSource::class);
     $routesConfiguration = $configurationSource->load($this->packageManager->getPackage('Neos.Setup')->getConfigurationPath() . ConfigurationManager::CONFIGURATION_TYPE_ROUTES);
     $this->router->setRoutesConfiguration($routesConfiguration);
     $componentContext->setParameter(\Neos\Flow\Mvc\Routing\RoutingComponent::class, 'skipRouterInitialization', true);
 }
All Usage Examples Of Neos\Flow\Package\PackageManagerInterface::getPackage