Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/bareos/bareos-webui.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'vendor/zendframework/zend-servicemanager/src/Proxy/LazyServiceFactoryFactory.php')
-rw-r--r--vendor/zendframework/zend-servicemanager/src/Proxy/LazyServiceFactoryFactory.php62
1 files changed, 0 insertions, 62 deletions
diff --git a/vendor/zendframework/zend-servicemanager/src/Proxy/LazyServiceFactoryFactory.php b/vendor/zendframework/zend-servicemanager/src/Proxy/LazyServiceFactoryFactory.php
deleted file mode 100644
index 9c94e75..0000000
--- a/vendor/zendframework/zend-servicemanager/src/Proxy/LazyServiceFactoryFactory.php
+++ /dev/null
@@ -1,62 +0,0 @@
-<?php
-/**
- * Zend Framework (http://framework.zend.com/)
- *
- * @link http://github.com/zendframework/zf2 for the canonical source repository
- * @copyright Copyright (c) 2005-2015 Zend Technologies USA Inc. (http://www.zend.com)
- * @license http://framework.zend.com/license/new-bsd New BSD License
- */
-
-namespace Zend\ServiceManager\Proxy;
-
-use ProxyManager\Configuration;
-use ProxyManager\Factory\LazyLoadingValueHolderFactory;
-use ProxyManager\GeneratorStrategy\EvaluatingGeneratorStrategy;
-use Zend\ServiceManager\FactoryInterface;
-use Zend\ServiceManager\ServiceLocatorInterface;
-use Zend\ServiceManager\Exception;
-
-/**
- * Service factory responsible of instantiating {@see \Zend\ServiceManager\Proxy\LazyServiceFactory}
- * and configuring it starting from application configuration
- */
-class LazyServiceFactoryFactory implements FactoryInterface
-{
- /**
- * {@inheritDoc}
- *
- * @return \Zend\ServiceManager\Proxy\LazyServiceFactory
- */
- public function createService(ServiceLocatorInterface $serviceLocator)
- {
- $config = $serviceLocator->get('Config');
-
- if (!isset($config['lazy_services'])) {
- throw new Exception\InvalidArgumentException('Missing "lazy_services" config key');
- }
-
- $lazyServices = $config['lazy_services'];
-
- if (!isset($lazyServices['class_map'])) {
- throw new Exception\InvalidArgumentException('Missing "class_map" config key in "lazy_services"');
- }
-
- $factoryConfig = new Configuration();
-
- if (isset($lazyServices['proxies_namespace'])) {
- $factoryConfig->setProxiesNamespace($lazyServices['proxies_namespace']);
- }
-
- if (isset($lazyServices['proxies_target_dir'])) {
- $factoryConfig->setProxiesTargetDir($lazyServices['proxies_target_dir']);
- }
-
- if (!isset($lazyServices['write_proxy_files']) || ! $lazyServices['write_proxy_files']) {
- $factoryConfig->setGeneratorStrategy(new EvaluatingGeneratorStrategy());
- }
-
- spl_autoload_register($factoryConfig->getProxyAutoloader());
-
- return new LazyServiceFactory(new LazyLoadingValueHolderFactory($factoryConfig), $lazyServices['class_map']);
- }
-}