code: def with_argparser_and_unknown_args(argparser: argparse.ArgumentParser, preserve_quotes: bool = False) -> \
          Callable[[argparse.Namespace, List], Optional[bool]]:
      
      import functools
  
      # noinspection PyProtectedMember
      def arg_decorator(func: Callable):
          @functools.wraps(func)
          def cmd_wrapper(cmd2_instance, statement: Union[Statement, str]):
              statement, parsed_arglist = cmd2_instance.statement_parser.get_command_arg_list(command_name,
                                                                                              statement,
                                                                                              preserve_quotes)
  
              try:
                  args, unknown = argparser.parse_known_args(parsed_arglist)
              except SystemExit:
                  return
              else:
                  setattr(args, '__statement__', statement)
                  return func(cmd2_instance, args, unknown)
  
          # argparser defaults the program name to sys.argv[0]
          # we want it to be the name of our command
          command_name = func.__name__[len(COMMAND_FUNC_PREFIX):]
          argparser.prog = command_name
  
          # If the description has not been set, then use the method docstring if one exists
          if argparser.description is None and func.__doc__:
              argparser.description = func.__doc__
  
          # Set the command's help text as argparser.description (which can be None)
          cmd_wrapper.__doc__ = argparser.description
  
          # Mark this function as having an argparse ArgumentParser
          setattr(cmd_wrapper, 'argparser', argparser)
  
          return cmd_wrapper
  
      return arg_decorator
docs: A decorator to alter a cmd2 method to populate its ``args`` argument by parsing arguments with the given
      instance of argparse.ArgumentParser, but also returning unknown args as a list.
  
      :param argparser: unique instance of ArgumentParser
      :param preserve_quotes: if True, then arguments passed to argparse maintain their quotes
      :return: function that gets passed argparse-parsed args in a Namespace and a list of unknown argument strings
               A member called __statement__ is added to the Namespace to provide command functions access to the
               Statement object. This can be useful if the command function needs to know the command line.