‪TYPO3CMS  ‪main
TYPO3\CMS\Core\Session\SessionManager Class Reference
Inheritance diagram for TYPO3\CMS\Core\Session\SessionManager:
TYPO3\CMS\Core\SingletonInterface

Public Member Functions

 getSessionBackend (string $identifier)
 
 invalidateAllSessionsByUserId (SessionBackendInterface $backend, int $userId, AbstractUserAuthentication $userAuthentication=null)
 

Protected Member Functions

 createSessionBackendFromConfiguration (string $identifier, array $configuration)
 

Protected Attributes

SessionBackendInterface[] $sessionBackends = array( )
 

Detailed Description

Class SessionManager

Example Configuration

‪$GLOBALS['TYPO3_CONF_VARS']['SYS']['session'] => [
'BE' => [
'backend' => \TYPO3\CMS\Core\Session\Backend\FileSessionBackend::class,
'savePath' => '/var/www/t3sessionframework/data/'
],
];

Definition at line 40 of file SessionManager.php.

Member Function Documentation

◆ createSessionBackendFromConfiguration()

TYPO3\CMS\Core\Session\SessionManager::createSessionBackendFromConfiguration ( string  $identifier,
array  $configuration 
)
protected

Creates a session backend from the configuration

Parameters
string$identifier‪the identifier
array<string,class-string>‪$configuration The session configuration array
Exceptions

Definition at line 105 of file SessionManager.php.

References TYPO3\CMS\Webhooks\Message\$identifier.

Referenced by TYPO3\CMS\Core\Session\SessionManager\getSessionBackend().

◆ getSessionBackend()

TYPO3\CMS\Core\Session\SessionManager::getSessionBackend ( string  $identifier)

Gets the currently running session backend for the given context

Exceptions

Definition at line 51 of file SessionManager.php.

References $GLOBALS, TYPO3\CMS\Webhooks\Message\$identifier, and TYPO3\CMS\Core\Session\SessionManager\createSessionBackendFromConfiguration().

◆ invalidateAllSessionsByUserId()

TYPO3\CMS\Core\Session\SessionManager::invalidateAllSessionsByUserId ( SessionBackendInterface  $backend,
int  $userId,
AbstractUserAuthentication  $userAuthentication = null 
)

Removes all sessions for a specific user ID

Parameters
SessionBackendInterface$backend‪see constants

Definition at line 73 of file SessionManager.php.

References TYPO3\CMS\Core\Session\Backend\SessionBackendInterface\getAll(), and TYPO3\CMS\Core\Session\Backend\SessionBackendInterface\remove().

Member Data Documentation

◆ $sessionBackends

SessionBackendInterface [] TYPO3\CMS\Core\Session\SessionManager::$sessionBackends = array( )
protected

Definition at line 44 of file SessionManager.php.

‪$GLOBALS
‪$GLOBALS['TYPO3_CONF_VARS']['EXTCONF']['adminpanel']['modules']
Definition: ext_localconf.php:25