3 instantiations of Option2
Microsoft.CodeAnalysis.Workspaces (3)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\CodeStyle\CodeStyleHelpers.cs (2)
125var option = new Option2<CodeStyleOption2<T>>(name, defaultValue, group, languageName, isEditorConfigOption: true, serializer: (serializerFactory ?? EditorConfigValueSerializer.CodeStyle).Invoke(defaultValue)); 137var option = new Option2<T>(name, defaultValue, group, languageName: null, isEditorConfigOption: true, serializer: serializer);
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Formatting\FormattingOptions2.cs (1)
59internal static Option2<bool> InsertFinalNewLine = new(
35 references to Option2
Microsoft.CodeAnalysis.EditorFeatures (1)
Tagging\AbstractAsynchronousTaggerProvider.cs (1)
72/// <remarks>All values must either be an <see cref="Option2{T}"/> or a <see cref="PerLanguageOption2{T}"/>.</remarks>
Microsoft.CodeAnalysis.Workspaces (32)
Options\GlobalOptionService.cs (2)
102public T GetOption<T>(Option2<T> option) 177public void SetGlobalOption<T>(Option2<T> option, T value)
Options\IGlobalOptionService.cs (2)
21T GetOption<T>(Option2<T> option); 39void SetGlobalOption<T>(Option2<T> option, T value);
Options\Option.cs (1)
14/// <inheritdoc cref="Option2{T}"/>
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\CodeStyle\CodeStyleHelpers.cs (4)
117public static Option2<CodeStyleOption2<T>> CreateEditorConfigOption<T>( 125var option = new Option2<CodeStyleOption2<T>>(name, defaultValue, group, languageName, isEditorConfigOption: true, serializer: (serializerFactory ?? EditorConfigValueSerializer.CodeStyle).Invoke(defaultValue)); 130public static Option2<T> CreateEditorConfigOption<T>( 137var option = new Option2<T>(name, defaultValue, group, languageName: null, isEditorConfigOption: true, serializer: serializer);
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\CodeStyle\CodeStyleOptions2.cs (6)
26private static Option2<CodeStyleOption2<T>> CreateOption<T>( 30private static Option2<T> CreateOption<T>( 106internal static readonly Option2<OperatorPlacementWhenWrappingPreference> OperatorPlacementWhenWrapping = CreateOption( 231internal static readonly Option2<string> FileHeaderTemplate = CreateOption( 237internal static readonly Option2<string> RemoveUnnecessarySuppressionExclusions = CreateOption( 303internal static readonly Option2<CodeStyleOption2<ForEachExplicitCastInSourcePreference>> ForEachExplicitCastInSource = CreateOption(
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\CodeStyle\VisualBasic\VisualBasicCodeStyleOptions.cs (6)
18private static Option2<CodeStyleOption2<T>> CreateOption<T>( 27public static readonly Option2<CodeStyleOption2<string>> PreferredModifierOrder = CreateOption( 35public static readonly Option2<CodeStyleOption2<bool>> PreferIsNotExpression = CreateOption( 40public static readonly Option2<CodeStyleOption2<bool>> PreferSimplifiedObjectCreation = CreateOption( 45public static readonly Option2<CodeStyleOption2<UnusedValuePreference>> UnusedValueExpressionStatement = CreateOption( 51public static readonly Option2<CodeStyleOption2<UnusedValuePreference>> UnusedValueAssignment = CreateOption(
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Formatting\FormattingOptions2.cs (1)
59internal static Option2<bool> InsertFinalNewLine = new(
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Options\IPublicOption.cs (1)
11/// to distinguish them from internal ones (<see cref="Option2{T}"/> and <see cref="PerLanguageOption2{T}"/>).
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Options\Option2.cs (1)
106public static implicit operator OptionKey2(Option2<T> option)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Options\PublicOptionFactory.cs (8)
58public static Option2<T> WithPublicOption<T, TPublicValue>(this Option2<T> option, string feature, string name, Func<T, TPublicValue> toPublicValue, Func<TPublicValue, T> toInternalValue) 77public static Option2<T> WithPublicOption<T>(this Option2<T> option, string feature, string name) 80public static Option2<CodeStyleOption2<T>> WithPublicOption<T>(this Option2<CodeStyleOption2<T>> option, string feature, string name) 89public static Option<T> ToPublicOption<T>(this Option2<T> option) 101public static Option<CodeStyleOption<T>> ToPublicOption<T>(this Option2<CodeStyleOption2<T>> option)
Microsoft.CodeAnalysis.Workspaces.UnitTests (2)
Options\DocumentOptionSetTests.cs (2)
93var option = CSharpFormattingOptions2.NewLineBeforeOpenBrace; 155var option = CSharpFormattingOptions2.SpaceBetweenParentheses;