Newscoop\NewscoopBundle\Session\Storage::__construct PHP Method

__construct() public method

public __construct ( array $options = [], $preferencesService, AbstractProxy | NativeSessionHandler | SessionHandlerInterface | null $handler = null, MetadataBag $metaBag = null )
$options array
$handler AbstractProxy | NativeSessionHandler | SessionHandlerInterface | null
$metaBag MetadataBag MetadataBag
    public function __construct(array $options = array(), $preferencesService, $handler = null, MetadataBag $metaBag = null)
    {
        $seconds = $preferencesService->SiteSessionLifeTime;
        $options['cookie_lifetime'] = $seconds;
        $options['gc_maxlifetime'] = $seconds;
        $this->setMetadataBag($metaBag);
        $this->setOptions($options);
        $this->setSaveHandler($handler);
    }