PHP Class Autarky\Http\SessionMiddleware

Inheritance: implements Symfony\Component\HttpKernel\HttpKernelInterface
Show file Open project: autarky/framework

Protected Properties

Property Type Description
$cookies array Additional cookie parameters to add to the session ID cookie.
$forceStart boolean Whether the sessions should always be started. Normal behaviour is to start the sesion whenever an operation is requested from it.
$kernel Symfony\Component\HttpKernel\HttpKernelInterface
$session Symfony\Component\HttpFoundation\Session\SessionInterface

Public Methods

Method Description
__construct ( Symfony\Component\HttpKernel\HttpKernelInterface $kernel, Application $app )
handle ( Request $request, $type = HttpKernelInterface::MASTER_REQUEST, $catch = true )

Protected Methods

Method Description
closeSession ( Request $request, Response $response )
initSession ( Request $request )
makeCookie ( Request $request )

Method Details

__construct() public method

public __construct ( Symfony\Component\HttpKernel\HttpKernelInterface $kernel, Application $app )
$kernel Symfony\Component\HttpKernel\HttpKernelInterface
$app Autarky\Application

closeSession() protected method

protected closeSession ( Request $request, Response $response )
$request Symfony\Component\HttpFoundation\Request
$response Symfony\Component\HttpFoundation\Response

handle() public method

public handle ( Request $request, $type = HttpKernelInterface::MASTER_REQUEST, $catch = true )
$request Symfony\Component\HttpFoundation\Request

initSession() protected method

protected initSession ( Request $request )
$request Symfony\Component\HttpFoundation\Request

makeCookie() protected method

protected makeCookie ( Request $request )
$request Symfony\Component\HttpFoundation\Request

Property Details

$cookies protected property

Additional cookie parameters to add to the session ID cookie.
protected array $cookies
return array

$forceStart protected property

Whether the sessions should always be started. Normal behaviour is to start the sesion whenever an operation is requested from it.
protected bool $forceStart
return boolean

$kernel protected property

protected HttpKernelInterface,Symfony\Component\HttpKernel $kernel
return Symfony\Component\HttpKernel\HttpKernelInterface

$session protected property

protected SessionInterface,Symfony\Component\HttpFoundation\Session $session
return Symfony\Component\HttpFoundation\Session\SessionInterface