annotate core/lib/Drupal/Core/Session/SessionConfigurationInterface.php @ 19:fa3358dc1485 tip

Add ndrum files
author Chris Cannam
date Wed, 28 Aug 2019 13:14:47 +0100
parents 4c8ae668cc8c
children
rev   line source
Chris@0 1 <?php
Chris@0 2
Chris@0 3 namespace Drupal\Core\Session;
Chris@0 4
Chris@0 5 use Symfony\Component\HttpFoundation\Request;
Chris@0 6
Chris@0 7 /**
Chris@0 8 * Defines an interface for session configuration generators.
Chris@0 9 */
Chris@0 10 interface SessionConfigurationInterface {
Chris@0 11
Chris@0 12 /**
Chris@0 13 * Determines whether a session identifier is on the request.
Chris@0 14 *
Chris@0 15 * This method detects whether a session was started during one of the
Chris@0 16 * previous requests from the same user agent. Session identifiers are
Chris@0 17 * normally passed along using cookies and hence a typical implementation
Chris@0 18 * checks whether the session cookie is on the request.
Chris@0 19 *
Chris@0 20 * @param \Symfony\Component\HttpFoundation\Request $request
Chris@0 21 * The request.
Chris@0 22 *
Chris@0 23 * @return bool
Chris@0 24 * TRUE if there is a session identifier on the request.
Chris@0 25 */
Chris@0 26 public function hasSession(Request $request);
Chris@0 27
Chris@0 28 /**
Chris@0 29 * Returns a list of options suitable for passing to the session storage.
Chris@0 30 *
Chris@0 31 * @see \Symfony\Component\HttpFoundation\Session\Storage\NativeSessionStorage::__construct()
Chris@0 32 *
Chris@0 33 * @param \Symfony\Component\HttpFoundation\Request $request
Chris@0 34 * The request.
Chris@0 35 *
Chris@0 36 * @return array
Chris@0 37 * An associative array of session ini settings.
Chris@0 38 */
Chris@0 39 public function getOptions(Request $request);
Chris@0 40
Chris@0 41 }