Neos\Flow\Session\SessionManager::getSession PHP Метод

getSession() публичный Метод

Returns the specified session. If no session with the given identifier exists, NULL is returned.
public getSession ( string $sessionIdentifier ) : Neos\Flow\Session\SessionInterface
$sessionIdentifier string The session identifier
Результат Neos\Flow\Session\SessionInterface
    public function getSession($sessionIdentifier)
    {
        if ($this->currentSession !== null && $this->currentSession->isStarted() && $this->currentSession->getId() === $sessionIdentifier) {
            return $this->currentSession;
        }
        if (isset($this->remoteSessions[$sessionIdentifier])) {
            return $this->remoteSessions[$sessionIdentifier];
        }
        if ($this->metaDataCache->has($sessionIdentifier)) {
            $sessionInfo = $this->metaDataCache->get($sessionIdentifier);
            $this->remoteSessions[$sessionIdentifier] = new Session($sessionIdentifier, $sessionInfo['storageIdentifier'], $sessionInfo['lastActivityTimestamp'], $sessionInfo['tags']);
            return $this->remoteSessions[$sessionIdentifier];
        }
    }