/// <summary> /// Converts a indent type enum value to the code /// </summary> /// <param name="indentType">Indent type enum value</param> /// <returns>Indent type code</returns> private static string ConvertIndentTypeEnumValueToCode(IndentType indentType) { string code; switch (indentType) { case IndentType.Space: code = "space"; break; case IndentType.Tab: code = "tab"; break; default: throw new InvalidCastException(string.Format(CoreStrings.Common_EnumValueToCodeConversionFailed, indentType.ToString(), typeof(IndentType))); } return(code); }