__construct() public method

For backwards compatibility, the signature of sf <2.6 still works.
public __construct ( Symfony\Component\Security\Core\Authentication\Token\Storage\TokenStorageInterface | Symfony\Component\Security\Core\Authentication\AuthenticationManagerInterface $tokenStorage, Symfony\Component\Security\Core\Authorization\AuthorizationCheckerInterface | Symfony\Component\Security\Core\Authorization\AccessDecisionManagerInterface $authorizationChecker, boolean $alwaysAuthenticate = false )
$tokenStorage Symfony\Component\Security\Core\Authentication\Token\Storage\TokenStorageInterface | Symfony\Component\Security\Core\Authentication\AuthenticationManagerInterface
$authorizationChecker Symfony\Component\Security\Core\Authorization\AuthorizationCheckerInterface | Symfony\Component\Security\Core\Authorization\AccessDecisionManagerInterface
$alwaysAuthenticate boolean only applicable with old signature
 /**
  * @param $security_config
  * @param $encoderFactory
  * @param $doctrine
  */
 public function __construct($security_config, $encoderFactory, $doctrine)
 {
     $this->security_config = $security_config;
     $this->encoderFactory = $encoderFactory;
     $this->doctrine = $doctrine;
     parent::__construct($this->getAuthenticationManager(), $this->getAccessDecisionManager());
 }
Esempio n. 2
0
 public function __construct(BBApplication $application, AuthenticationManagerInterface $authenticationManager, AccessDecisionManagerInterface $accessDecisionManager)
 {
     $this->application = $application;
     $this->logger = $this->application->getLogging();
     $this->dispatcher = $this->application->getEventDispatcher();
     if (null === ($securityConfig = $this->application->getConfig()->getSecurityConfig())) {
         trigger_error('None security configuration found', E_USER_NOTICE);
         return;
     }
     $this->config = $securityConfig;
     $this->authmanager = $authenticationManager;
     $this->createEncoderFactory($securityConfig);
     $this->createProviders($securityConfig);
     $this->createACLProvider($securityConfig);
     $this->createFirewallMap($securityConfig);
     $this->registerFirewall();
     parent::__construct($this->authmanager, $accessDecisionManager);
 }