Close will close the connection to the server.

@return void
548916
public function close()
    {
        if ($this->streamSocket === null) {
            return;
        }

        fclose($this->streamSocket);
        $this->streamSocket = null;
    }
1065432
public function close() {
        if ($this->users_rs) {
            $this->users_rs->close();
            $this->users_rs = null;
        }
        if ($this->grades_rs) {
            $this->grades_rs->close();
            $this->grades_rs = null;
        }
        $this->gradestack = array();
    }
207043
public function disconnect()
	{
		// Close the connection.
		if (\is_resource($this->connection))
		{
			sqlsrv_close($this->connection);
		}

		$this->connection = null;
	}
977496
final public function close()
    {

        $this->onCloseConnection();

        if($this->socket){
            $this->write("</stream:stream>");
            parent::close();
            $this->connected = false;
        }

    }
65891
public function close(): void
  {
    foreach($this->channels as $channel)
    {
      $channel->close();
    }
    $this->connection->close();
  }
1265208
function close()
    {
        if ($this->_opened) {
            $this->_opened = false;
            return fclose($this->_socket);
        }
        return true;
    }
501107
public function close()
    {
        if (is_resource($this->curl)) {
            curl_close($this->curl);
        }
        $this->options = null;
        $this->jsonDecoder = null;
        $this->xmlDecoder = null;
    }
1146029
public function close(): void
    {
        if ($this->type == self::TYPE_MYSQL_LINK) {
            $this->object->close();
        } elseif ($this->type == self::TYPE_PGSQL_LINK) {
            pg_close($this->object);
        }

        $this->reset();
    }
717698
public function close() {
		if ($this->isConnected()) {
			$this->_connection->close();
		}

		$this->connected = false;
		$this->_connection = null;

		return true;
	}
133929
protected function close()
    {
        if (is_resource($this->stream)) {
            $this->flush();
            fclose($this->stream);
        }
        $this->stream = false;
    }
632771
private function _closeConnection()
    {
        if (!$this->ftp) {
            return;
        }
        if (!$this->isSFTP()) {
            ftp_close($this->ftp);
            $this->ftp = null;
        }
    }
497935
public function close()
    {
        $this->error = array();
        $this->helo_rply = null;
        if (is_resource($this->smtp_conn)) {
            // close the connection and cleanup
            fclose($this->smtp_conn);
            if ($this->do_debug >= 3) {
                $this->edebug('Connection: closed');
            }
        }
    }
411990
function _close()
	{
		$this->lastQuery = false;
		if($this->_connectionID) {
			return ifx_close($this->_connectionID);
		}
		return true;
	}
896537
protected function do_close()
    {
        if ($this->channel_id !== null) {
            unset($this->connection->channels[$this->channel_id]);
        }
        $this->channel_id = $this->connection = null;
        $this->is_open = false;
        $this->callbacks = array();
    }
768023
public function close(): void
    {
        if ($this->closeAfter) {
            $this->closeAfter = false;
            \fclose($this->fp);
            \clearstatcache();
        }
    }
1155556
public function close()
    {
        if (isset($this->zip)) {
            $this->zip->close();
            $this->zip = null;
        }
    }
1082504
public function close()
    {
        $outputFrame = ProtocolChannel\ChannelCloseFrame::create(
            0,//@todo replyCode
            'Channel closed by client'
        );
        $outputFrame->frameChannelId = $this->id;
        $this->connection->command($outputFrame);
    }