code: def command(self, func):
          
          command = Command(func)
          self._commands[func.__name__] = command
          return func
docs: Decorator to add a command function to the registry.
  
          :param func: command function.