code: def ParseOptions(self, options):
      
      self._ParseInformationalOptions(options)
  
      self._verbose = getattr(options, 'verbose', False)
  
      self._output_filename = getattr(options, 'write', None)
  
      argument_helper_names = ['process_resources', 'storage_file']
      helpers_manager.ArgumentHelperManager.ParseOptions(
          options, self, names=argument_helper_names)
  
      # TODO: move check into _CheckStorageFile.
      if not self._storage_file_path:
        raise errors.BadConfigOption('Missing storage file option.')
  
      if not os.path.isfile(self._storage_file_path):
        raise errors.BadConfigOption(
            'No such storage file: {0:s}.'.format(self._storage_file_path))
  
      compare_storage_file_path = self.ParseStringOption(
          options, 'compare_storage_file')
      if compare_storage_file_path:
        if not os.path.isfile(compare_storage_file_path):
          raise errors.BadConfigOption(
              'No such storage file: {0:s}.'.format(compare_storage_file_path))
  
        self._compare_storage_file_path = compare_storage_file_path
        self.compare_storage_information = True
  
      self._output_format = self.ParseStringOption(options, 'output_format')
  
      if self._output_filename:
        if os.path.exists(self._output_filename):
          raise errors.BadConfigOption(
              'Output file already exists: {0:s}.'.format(self._output_filename))
        output_file_object = open(self._output_filename, 'wb')
        self._output_writer = tools.FileObjectOutputWriter(output_file_object)
  
      self._EnforceProcessMemoryLimit(self._process_memory_limit)
docs: Parses the options.
  
      Args:
        options (argparse.Namespace): command line arguments.
  
      Raises:
        BadConfigOption: if the options are invalid.