Destroy session data.

http://php.net/manual/en/sessionhandler.destroy.php.

@param string $session_id

@return bool
973317
public function destroy($session_id)
    {
        if ($this->memcached->delete($session_id)) {
            return true;
        }

        if ($this->memcached->getResultCode() === 16) {
            return true;
        }

        return false;
    }
119340
public function destroy($id) {
        if (headers_sent() && !$this->sent)
            throw new \LogicException('Session data must be destroyed before headers are sent');
        if (!$this->sent)
            $this->sent = setcookie(
                $this->name,
                '',
                time() - 3600,
                '/',
                $this->getDomain(),
                null,
                true
            );
        return true;
    }
193380
public function destroySession($id)
    {
        $this->db->getCollection($this->sessionCollection)->remove(
            ['id' => $id],
            ['justOne' => true]
        );

        return true;
    }
863634
public function write($session_id, $session_data)
    {
        return $this->memcached->set($session_id, $session_data, $this->expire);
    }
377457
public function destroy($sessionId)
    {
        parent::destroy($sessionId);
        if (isset($_COOKIE[$this->cookieKeyName])) {
            setcookie($this->cookieKeyName, '', 1);
            unset($_COOKIE[$this->cookieKeyName]);
        }
        return true;
    }
981061
def destroy(id, options = {})
      custom_params = []
      custom_params << use_named_parameter('dc', options[:dc]) if options[:dc]
      raw = send_put_request(@conn, ["/v1/session/destroy/#{id}"], options, nil, custom_params)
      raw.body
    end
1196297
public function destroy($sessionID)
    {
        $fileName = $this->getFileName($sessionID);
        if(is_file($fileName))
        {
            unlink($fileName);
        }
    }
1332224
public function destroy($session_id)
    {
        if (!headers_sent() && ini_get('session.use_cookies')) {
            if (!$this->session_name) {
                throw new \LogicException(sprintf('Session name 不能为空, 是不是没有调用 "parent::open()" in "%s"?.', get_class($this)));
            }
            $session_cookie         = sprintf(' %s=', urlencode($this->session_name));
            $session_cookie_with_id = sprintf('%s%s;', $session_cookie, urlencode($session_id));
            $session_cookie_found   = false;
            $other_cookies          = array();
            foreach (headers_list() as $h) {
                if (0 !== stripos($h, 'Set-Cookie:')) {
                    continue;
                }
                if (11 === strpos($h, $session_cookie, 11)) {
                    $session_cookie_found = true;
                    
                    if (11 !== strpos($h, $session_cookie_with_id, 11)) {
                        $other_cookies[] = $h;
                    }
                } else {
                    $other_cookies[] = $h;
                }
            }
            if ($session_cookie_found) {
                header_remove('Set-Cookie');
                foreach ($other_cookies as $h) {
                    header('Set-Cookie:'.$h, false);
                }
            } else {
                setcookie($this->session_name, '', 0, ini_get('session.cookie_path'), ini_get('session.cookie_domain'), ini_get('session.cookie_secure'), ini_get('session.cookie_httponly'));
            }
        }
        
        return true;
    }
342496
public function destroy($id)
    {
        $query = $this->db->getQuery(true);
        $query->delete($this->db->quoteName($this->options['table']))
            ->where($this->db->quoteName($this->options['id_col']) . ' = ' . $this->db->quote($id));

        // Remove a session from the database.
        $this->db->setQuery($query);

        return (bool) $this->db->execute();
    }
969186
public function destroy($sessionID): bool
    {
        $file = $this->savePath.DIRECTORY_SEPARATOR.'sess_'.$sessionID;
        $ret = \file_exists($file) ? @\unlink($file) : true;
        return $ret;
    }
1117564
public function destroySession($id)
	{
		$this->getDbConnection()->createCommand()
			->delete($this->sessionTableName,'id=:id',array(':id'=>$id));
		return true;
	}
781617
public static function destroy($id)
    {
        $table = self::getTableNameFromClass();

        self::getOne($id);

        $query = "DELETE FROM $table WHERE id = ".$id;

        try {
            Connection::db()->query($query);
            return true;
        } catch (Exception $e) {
            return false;
        }
    }
838970
function destroy($session_id)
    {

        // deletes the current session id from the database
        $result = $this->_mysql_query('

            DELETE FROM
                ' . $this->table_name . '
            WHERE
                session_id = "' . $this->_mysql_real_escape_string($session_id) . '"

        ') or die($this->_mysql_error());

        // if anything happened
        // return true
        if ($this->_mysql_affected_rows() !== -1) return true;

        // if something went wrong, return false
        return false;

    }
1125254
public function setSessionID(string $session_id)
    {
        if (!defined('WEDETO_TEST') || WEDETO_TEST === 0)
            throw new \RuntimeException("Cannot change the session ID");

        $this->session_id = $session_id;
        return $this;
    }
265199
public static function delete_by_user_id($user_id = null)
	{
		if (empty($user_id))
		{
			return true;
		}

		$results = self::all()
			->whereEquals('user_id', $user_id)
			->rows();

		foreach ($results as $result)
		{
			if (!$result->destroy())
			{
				return false;
			}
		}

		return true;
	}
295331
public function write(
        /*# string */ $session_id,
        /*# string */ $session_data
    )/*# : bool */ {
        $file = $this->getSessionFile($session_id);
        return $this->storage->put($file, $session_data);
    }
52369
public function destroy($session_id)
    {
        if (is_null($this->handlers)) {
            $this->seedHandlerStack();
        }

        /** @var callable $start */
        $start = $this->stacks['delete']->top();
        $this->handlerLock = true;
        $data = $start($session_id);
        $this->handlerLock = false;
        return $data;
    }