vendor/symfony/src/Symfony/Bundle/SecurityBundle/Security/FirewallContext.php
changeset 0 7f95f8617b0b
equal deleted inserted replaced
-1:000000000000 0:7f95f8617b0b
       
     1 <?php
       
     2 
       
     3 /*
       
     4  * This file is part of the Symfony framework.
       
     5  *
       
     6  * (c) Fabien Potencier <fabien@symfony.com>
       
     7  *
       
     8  * This source file is subject to the MIT license that is bundled
       
     9  * with this source code in the file LICENSE.
       
    10  */
       
    11 
       
    12 namespace Symfony\Bundle\SecurityBundle\Security;
       
    13 
       
    14 use Symfony\Component\Security\Http\Firewall\ExceptionListener;
       
    15 
       
    16 /**
       
    17  * This is a wrapper around the actual firewall configuration which allows us
       
    18  * to lazy load the context for one specific firewall only when we need it.
       
    19  *
       
    20  * @author Johannes M. Schmitt <schmittjoh@gmail.com>
       
    21  */
       
    22 class FirewallContext
       
    23 {
       
    24     private $listeners;
       
    25     private $exceptionListener;
       
    26 
       
    27     public function __construct(array $listeners, ExceptionListener $exceptionListener = null)
       
    28     {
       
    29         $this->listeners = $listeners;
       
    30         $this->exceptionListener = $exceptionListener;
       
    31     }
       
    32 
       
    33     public function getContext()
       
    34     {
       
    35         return array($this->listeners, $this->exceptionListener);
       
    36     }
       
    37 }