Skip to main content
Drupal API
User account menu
  • Log in

Breadcrumb

  1. Drupal Core 11.1.x
  2. MockFileSessionStorage.php

function MockFileSessionStorage::start

Overrides MockArraySessionStorage::start

1 call to MockFileSessionStorage::start()
MockFileSessionStorage::regenerate in vendor/symfony/http-foundation/Session/Storage/MockFileSessionStorage.php
Regenerates id that represents this storage.

File

vendor/symfony/http-foundation/Session/Storage/MockFileSessionStorage.php, line 46

Class

MockFileSessionStorage
MockFileSessionStorage is used to mock sessions for functional testing where you may need to persist session data across separate PHP processes.

Namespace

Symfony\Component\HttpFoundation\Session\Storage

Code

public function start() : bool {
    if ($this->started) {
        return true;
    }
    if (!$this->id) {
        $this->id = $this->generateId();
    }
    $this->read();
    $this->started = true;
    return true;
}

API Navigation

  • Drupal Core 11.1.x
  • Topics
  • Classes
  • Functions
  • Constants
  • Globals
  • Files
  • Namespaces
  • Deprecated
  • Services
RSS feed
Powered by Drupal