/// <summary>
 /// Convert <see cref="string"/> to TEnum.
 /// </summary>
 /// <typeparam name="TEnum">枚举类型</typeparam>
 /// <param name="str"></param>
 /// <param name="ignoreCase">是否区分大小写</param>
 /// <param name="defaultVal"></param>
 /// <returns></returns>
 public static TEnum CastToEnum <TEnum>(this string str, bool ignoreCase, TEnum defaultVal) where TEnum : struct, Enum => EnumConv.StringToEnum(str, defaultVal, ignoreCase);
 /// <summary>
 /// Convert <see cref="string"/> to TEnum.
 /// </summary>
 /// <typeparam name="TEnum">枚举类型</typeparam>
 /// <param name="str"></param>
 /// <param name="defaultVal"></param>
 /// <returns></returns>
 public static TEnum CastToEnum <TEnum>(this string str, TEnum defaultVal) where TEnum : struct, Enum => EnumConv.StringToEnum(str, defaultVal);
 /// <summary>
 /// Convert <see cref="string"/> to TEnum.
 /// </summary>
 /// <typeparam name="TEnum">枚举类型</typeparam>
 /// <param name="str">     </param>
 /// <param name="ignoreCase"> 是否区分大小写 </param>
 /// <returns></returns>
 public static TEnum CastToEnum <TEnum>(this string str, bool ignoreCase) where TEnum : struct, Enum => EnumConv.StringToEnum <TEnum>(str, ignoreCase);
 /// <summary>
 /// Convert <see cref="string"/> to TEnum.
 /// </summary>
 /// <typeparam name="TEnum">枚举类型</typeparam>
 /// <param name="str"></param>
 /// <returns></returns>
 public static TEnum CastToEnum <TEnum>(this string str) where TEnum : struct, Enum => EnumConv.StringToEnum <TEnum>(str);
 /// <summary>
 /// Convert <see cref="string"/> to the given type enum.
 /// </summary>
 /// <param name="member"></param>
 /// <param name="enumType"></param>
 /// <param name="ignoreCase"></param>
 /// <param name="defaultVal"></param>
 /// <returns></returns>
 public static object ToEnum(string member, Type enumType, bool ignoreCase = false, object defaultVal = default)
 {
     return(EnumConv.StringToEnum(member, enumType, defaultVal, ignoreCase));
 }
 /// <summary>
 /// Convert <see cref="string"/> to TEnum.
 /// </summary>
 /// <param name="member"></param>
 /// <param name="ignoreCase"></param>
 /// <param name="defaultVal"></param>
 /// <typeparam name="TEnum"></typeparam>
 /// <returns></returns>
 public static TEnum ToEnum <TEnum>(string member, bool ignoreCase = false, TEnum defaultVal = default) where TEnum : struct, Enum
 {
     return(EnumConv.StringToEnum(member, defaultVal, ignoreCase));
 }