docs: def get_log_format_types():
      '''
      Get all available log format names and ids.
  
      :return: A dictionary of the log format names and ids.
      :rtype: dict
  
      CLI Example:
  
      .. code-block:: bash
  
          salt '*' win_smtp_server.get_log_format_types
      '''
      ret = dict()
      prefix = 'logging/'
  
      with salt.utils.winapi.Com():
          try:
              connection = wmi.WMI(namespace=_WMI_NAMESPACE)
              objs = connection.IISLogModuleSetting()
  
              # Remove the prefix from the name.
              for obj in objs:
                  name = six.text_type(obj.Name).replace(prefix, '', 1)
                  ret[name] = six.text_type(obj.LogModuleId)
          except wmi.x_wmi as error:
              _LOG.error('Encountered WMI error: %s', error.com_error)
          except (AttributeError, IndexError) as error:
              _LOG.error('Error getting IISLogModuleSetting: %s', error)
  
      if not ret:
          _LOG.error('Unable to get log format types.')
      return ret