def add_cog(self, cog):
if not isinstance(cog, Cog):<EOL><INDENT>raise TypeError('<STR_LIT>')<EOL><DEDENT>cog = cog._inject(self)<EOL>self.__cogs[cog.__cog_name__] = cog<EOL>
Adds a "cog" to the bot.

        A cog is a class that has its own event listeners and commands.

        Parameters
        -----------
        cog: :class:`.Cog`
            The cog to register to the bot.

        Raises
        -------
        TypeError
            The cog does not inherit from :class:`.Cog`.
        CommandError
            An error happened during loading.