Overview

Namespaces

  • Faulancer
    • Controller
    • Exception
    • Form
      • Validator
        • Type
    • Helper
      • Reflection
    • Http
    • Mail
    • ORM
      • User
    • Service
      • Factory
    • ServiceLocator
    • Session
    • View
      • Helper

Classes

  • AuthenticatorServiceFactory
  • ConfigFactory
  • ControllerServiceFactory
  • DbServiceFactory
  • DispatcherServiceFactory
  • HttpServiceFactory
  • SessionManagerServiceFactory
  • Overview
  • Namespace
  • Class
 1:  2:  3:  4:  5:  6:  7:  8:  9: 10: 11: 12: 13: 14: 15: 16: 17: 18: 19: 20: 21: 22: 23: 24: 25: 26: 27: 28: 29: 30: 31: 32: 33: 34: 35: 36: 37: 38: 
<?php
/**
 * Class AuthenticatorServiceFactory | AuthenticatorServiceFactory.php
 * @package Faulancer\Service\Factory
 * @author  Florian Knapp <office@florianknapp.de>
 */
namespace Faulancer\Service\Factory;

use Faulancer\Service\AuthenticatorService;
use Faulancer\Service\Config;
use Faulancer\Controller\Controller;
use Faulancer\Service\ControllerService;
use Faulancer\ServiceLocator\FactoryInterface;
use Faulancer\ServiceLocator\ServiceLocatorInterface;

/**
 * Class AuthenticatorServiceFactory
 */
class AuthenticatorServiceFactory implements FactoryInterface
{

    /**
     * @param ServiceLocatorInterface $serviceLocator
     * @return AuthenticatorService
     * @codeCoverageIgnore
     */
    public function createService(ServiceLocatorInterface $serviceLocator)
    {
        /** @var Controller $controller */
        $controller = $serviceLocator->get(ControllerService::class);

        /** @var Config $config */
        $config = $serviceLocator->get(Config::class);

        return new AuthenticatorService($controller, $config);
    }

}
API documentation generated by ApiGen