SessionManager
class SessionManager implements SessionManagerInterface (View source)
Session Manager
Properties
protected SessionInterface | $currentSession | ||
protected array | $remoteSessions | ||
protected VariableFrontend | $metaDataCache | Meta data cache used by sessions |
|
protected VariableFrontend | $storageCache | Storage cache for by sessions |
|
protected float | $garbageCollectionProbability | ||
protected int | $garbageCollectionMaximumPerRun | ||
protected int | $inactivityTimeout | ||
protected LoggerInterface | $logger |
Methods
Returns the currently active session which stores session data for the current HTTP request on this local system.
Returns the specified session. If no session with the given identifier exists, NULL is returned.
Returns all active sessions, even remote ones.
Returns all sessions which are tagged by the specified tag.
Destroys all sessions which are tagged with the specified tag.
Iterates over all existing sessions and removes their data if the inactivity timeout was reached.
Shuts down this session
Details
SessionInterface
getCurrentSession()
Returns the currently active session which stores session data for the current HTTP request on this local system.
bool
initializeCurrentSessionFromCookie(Cookie $cookie)
No description
bool
createCurrentSessionFromCookie(Cookie $cookie)
No description
SessionInterface|null
getSession(string $sessionIdentifier)
Returns the specified session. If no session with the given identifier exists, NULL is returned.
Session[]
getActiveSessions()
Returns all active sessions, even remote ones.
array
getSessionsByTag(string $tag)
Returns all sessions which are tagged by the specified tag.
int
destroySessionsByTag(string $tag, string $reason = '')
Destroys all sessions which are tagged with the specified tag.
int|null
collectGarbage()
Iterates over all existing sessions and removes their data if the inactivity timeout was reached.
void
shutdownObject()
Shuts down this session
This method must not be called manually – it is invoked by Flow's object management.