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

Breadcrumb

  1. Drupal Core 11.1.x

SessionManagerInterface.php

Namespace

Drupal\Core\Session

File

core/lib/Drupal/Core/Session/SessionManagerInterface.php

View source
<?php

namespace Drupal\Core\Session;

use Symfony\Component\HttpFoundation\Session\Storage\SessionStorageInterface;

/**
 * Defines the session manager interface.
 */
interface SessionManagerInterface extends SessionStorageInterface {
    
    /**
     * Ends a specific user's session(s).
     *
     * @param int $uid
     *   User ID.
     */
    public function delete($uid);
    
    /**
     * Destroys the current session and removes session cookies.
     */
    public function destroy();
    
    /**
     * Sets the write safe session handler.
     *
     * @todo This should be removed once all database queries are removed from
     *   the session manager class.
     *
     * @var \Drupal\Core\Session\WriteSafeSessionHandlerInterface
     */
    public function setWriteSafeHandler(WriteSafeSessionHandlerInterface $handler);

}

Interfaces

Title Deprecated Summary
SessionManagerInterface Defines the session manager interface.

API Navigation

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