AppserverIo\Appserver\ServletEngine\Session\FilesystemSessionHandler::delete PHP Méthode

delete() public méthode

Deletes the session with the passed ID from the persistence layer.
public delete ( string $id ) : void
$id string The ID of the session we want to delete
Résultat void
    public function delete($id)
    {
        // prepare the pathname to the file containing the session data
        $filename = $this->getSessionSettings()->getSessionFilePrefix() . $id;
        $pathname = $this->getSessionSavePath($filename);
        // remove the session from the file system
        if ($this->removeSessionFile($pathname) === false) {
            throw new SessionCanNotBeDeletedException(sprintf('Session with ID %s can not be deleted', $id));
        }
    }