public function close()
    {
        if (!$this->connection) {
            return false;
        }
        $this->countConnections--;
        if ($this->countConnections > 0) {
            return false;
        }
        $this->implementation->close($this->connection);
        $this->connection = null;
        return true;
    }