37 references to EditorConfigValueSerializer
Microsoft.CodeAnalysis.Workspaces (37)
Options\Option.cs (1)
70
: this(new OptionDefinition<T>(defaultValue,
EditorConfigValueSerializer
<T>.Unsupported, group, feature + "_" + name, storageMapping, isEditorConfigOption), feature, name, storageLocations)
Options\PerLanguageOption.cs (1)
62
: this(new OptionDefinition<T>(defaultValue,
EditorConfigValueSerializer
<T>.Unsupported, group, feature + "_" + name, storageMapping, isEditorConfigOption), feature, name, storageLocations)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\CodeStyle\CodeStyleHelpers.cs (4)
123
Func<CodeStyleOption2<T>,
EditorConfigValueSerializer
<CodeStyleOption2<T>>>? serializerFactory = null)
135
EditorConfigValueSerializer
<T>? serializer = null)
147
Func<CodeStyleOption2<T>,
EditorConfigValueSerializer
<CodeStyleOption2<T>>>? serializerFactory = null)
164
internal static
EditorConfigValueSerializer
<CodeStyleOption2<UnusedValuePreference>> GetUnusedValuePreferenceSerializer(CodeStyleOption2<UnusedValuePreference> defaultValue)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\CodeStyle\CodeStyleOptions2.cs (3)
24
OptionGroup group, string name, CodeStyleOption2<T> defaultValue, Func<CodeStyleOption2<T>,
EditorConfigValueSerializer
<CodeStyleOption2<T>>>? serializerFactory = null)
28
OptionGroup group, string name, CodeStyleOption2<T> defaultValue, Func<CodeStyleOption2<T>,
EditorConfigValueSerializer
<CodeStyleOption2<T>>>? serializerFactory = null)
32
OptionGroup group, string name, T defaultValue,
EditorConfigValueSerializer
<T>? serializer = null)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\CodeStyle\VisualBasic\VisualBasicCodeStyleOptions.cs (1)
22
Func<CodeStyleOption2<T>,
EditorConfigValueSerializer
<CodeStyleOption2<T>>>? serializerFactory = null)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Options\EditorConfigValueSerializer.cs (21)
22
private static readonly
EditorConfigValueSerializer
<bool> s_bool = new(
26
private static readonly
EditorConfigValueSerializer
<int> s_int32 = new(
30
private static readonly
EditorConfigValueSerializer
<string> s_string = new(
34
private static readonly
EditorConfigValueSerializer
<bool?> s_nullableBoolean = new(
55
public static
EditorConfigValueSerializer
<T> Default<T>()
58
return (
EditorConfigValueSerializer
<T>)(object)s_bool;
61
return (
EditorConfigValueSerializer
<T>)(object)s_int32;
64
return (
EditorConfigValueSerializer
<T>)(object)s_string;
67
return (
EditorConfigValueSerializer
<T>)(object)s_nullableBoolean;
72
return
EditorConfigValueSerializer
<T>.Unsupported;
75
public static
EditorConfigValueSerializer
<string> String(string emptyStringRepresentation)
79
public static
EditorConfigValueSerializer
<CodeStyleOption2<T>> CodeStyle<T>(CodeStyleOption2<T> defaultValue)
82
return (
EditorConfigValueSerializer
<CodeStyleOption2<T>>)(object)CodeStyle((CodeStyleOption2<bool>)(object)defaultValue);
85
return (
EditorConfigValueSerializer
<CodeStyleOption2<T>>)(object)CodeStyle((CodeStyleOption2<string>)(object)defaultValue);
90
public static
EditorConfigValueSerializer
<CodeStyleOption2<bool>> CodeStyle(CodeStyleOption2<bool> defaultValue)
94
public static
EditorConfigValueSerializer
<CodeStyleOption2<string>> CodeStyle(CodeStyleOption2<string> defaultValue)
101
public static
EditorConfigValueSerializer
<T> CreateSerializerForEnum<T>() where T : struct, Enum
109
public static
EditorConfigValueSerializer
<T> CreateSerializerForEnum<T>(BidirectionalMap<string, T> map) where T : struct, Enum
116
public static
EditorConfigValueSerializer
<T> CreateSerializerForEnum<T>(BidirectionalMap<string, T> map, ImmutableDictionary<string, T> alternative) where T : struct, Enum
124
public static
EditorConfigValueSerializer
<T> CreateSerializerForEnum<T>(IEnumerable<(string name, T value)> entries, IEnumerable<(string name, T value)> alternativeEntries) where T : struct, Enum
133
public static
EditorConfigValueSerializer
<T?> CreateSerializerForNullableEnum<T>() where T : struct, Enum
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Options\EditorConfigValueSerializer`1.cs (1)
19
public static readonly
EditorConfigValueSerializer
<T> Unsupported = new(
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Options\Option2.cs (1)
55
EditorConfigValueSerializer
<T>? serializer = null)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Options\OptionDefinition.cs (2)
112
EditorConfigValueSerializer
<T>? serializer,
119
public new
EditorConfigValueSerializer
<T> Serializer { get; } = serializer ?? EditorConfigValueSerializer.Default<T>();
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Options\PerLanguageOption2.cs (1)
44
EditorConfigValueSerializer
<T>? serializer = null)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Options\PublicOptionFactory.cs (1)
52
serializer:
EditorConfigValueSerializer
<TPublicValue>.Unsupported, // public option instances do not need to be serialized to editorconfig