You are here

public function Session::__construct in Zircon Profile 8

Same name in this branch
  1. 8 vendor/behat/mink/src/Session.php \Behat\Mink\Session::__construct()
  2. 8 vendor/symfony/http-foundation/Session/Session.php \Symfony\Component\HttpFoundation\Session\Session::__construct()
  3. 8 core/lib/Drupal/Core/StackMiddleware/Session.php \Drupal\Core\StackMiddleware\Session::__construct()
Same name and namespace in other branches
  1. 8.0 vendor/behat/mink/src/Session.php \Behat\Mink\Session::__construct()

Initializes session.

Parameters

DriverInterface $driver:

SelectorsHandler $selectorsHandler:

File

vendor/behat/mink/src/Session.php, line 34

Class

Session
Mink session.

Namespace

Behat\Mink

Code

public function __construct(DriverInterface $driver, SelectorsHandler $selectorsHandler = null) {
  $driver
    ->setSession($this);
  if (null === $selectorsHandler) {
    $selectorsHandler = new SelectorsHandler();
  }
  $this->driver = $driver;
  $this->selectorsHandler = $selectorsHandler;
  $this->page = new DocumentElement($this);
}