Added the zend framework 2 library, the path is specified in line no.26 in zend_modul...
[openemr.git] / interface / modules / zend_modules / library / Zend / Mvc / Service / EventManagerFactory.php
blob01c250c769f27ad6f6a23367958c13120823a83d
1 <?php
2 /**
3 * Zend Framework (http://framework.zend.com/)
5 * @link http://github.com/zendframework/zf2 for the canonical source repository
6 * @copyright Copyright (c) 2005-2013 Zend Technologies USA Inc. (http://www.zend.com)
7 * @license http://framework.zend.com/license/new-bsd New BSD License
8 */
10 namespace Zend\Mvc\Service;
12 use Zend\EventManager\EventManager;
13 use Zend\ServiceManager\FactoryInterface;
14 use Zend\ServiceManager\ServiceLocatorInterface;
16 class EventManagerFactory implements FactoryInterface
18 /**
19 * Create an EventManager instance
21 * Creates a new EventManager instance, seeding it with a shared instance
22 * of SharedEventManager.
24 * @param ServiceLocatorInterface $serviceLocator
25 * @return EventManager
27 public function createService(ServiceLocatorInterface $serviceLocator)
29 $em = new EventManager();
30 $em->setSharedManager($serviceLocator->get('SharedEventManager'));
31 return $em;