for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
namespace JhUser\Repository\Factory;
use JhUser\Repository\RoleRepository;
use Zend\ServiceManager\FactoryInterface;
use Zend\ServiceManager\ServiceLocatorInterface;
/**
* Class RoleRepositoryFactory
* @package JhUser\Repository\Factory
* @author Aydin Hassan <[email protected]>
*/
class RoleRepositoryFactory implements FactoryInterface
{
* @param ServiceLocatorInterface $serviceLocator
* @return RoleRepository
public function createService(ServiceLocatorInterface $serviceLocator)
return new RoleRepository(
$serviceLocator->get('JhUser\ObjectManager')->getRepository('JhUser\Entity\HierarchicalRole')
);
}