123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263 |
- <?php
- namespace Symfony\Component\HttpFoundation\Session\Storage;
- class PhpBridgeSessionStorage extends NativeSessionStorage
- {
-
- public function __construct($handler = null, MetadataBag $metaBag = null)
- {
- if (!\extension_loaded('session')) {
- throw new \LogicException('PHP extension "session" is required.');
- }
- $this->setMetadataBag($metaBag);
- $this->setSaveHandler($handler);
- }
-
- public function start()
- {
- if ($this->started) {
- return true;
- }
- $this->loadSession();
- return true;
- }
-
- public function clear()
- {
-
-
- foreach ($this->bags as $bag) {
- $bag->clear();
- }
-
- $this->loadSession();
- }
- }
|