Clears the internal state of the bot.

        After this, the bot can be considered "re-opened", i.e. :meth:`.is_closed`
        and :meth:`.is_ready` both return ``False`` along with the bot's internal
        cache cleared.

def clear(self):
        """Clears the internal state of the bot.

        After this, the bot can be considered "re-opened", i.e. :meth:`.is_closed`
        and :meth:`.is_ready` both return ``False`` along with the bot's internal
        cache cleared.
        """
        self._closed = False
        self._ready.clear()
        self._connection.clear()
        self.http.recreate()