3 interfaces inheriting from IOption2
Microsoft.CodeAnalysis.CodeStyle (3)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Options\IPublicOption.cs (1)
13internal interface IPublicOption : IOption2
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Options\Option2.cs (1)
15internal interface ISingleValuedOption : IOption2
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Options\PerLanguageOption2.cs (1)
15internal interface IPerLanguageValuedOption : IOption2
53 references to IOption2
Microsoft.CodeAnalysis.CodeStyle (53)
src\Analyzers\Core\Analyzers\AbstractBuiltInCodeStyleDiagnosticAnalyzer.cs (8)
19/// unique <see cref="IOption2"/> code style option. 37IOption2? option, 50/// two or more <see cref="IOption2 "/> code style options. 67ImmutableHashSet<IOption2> options, 83protected AbstractBuiltInCodeStyleDiagnosticAnalyzer(ImmutableArray<(DiagnosticDescriptor Descriptor, IOption2 Option)> supportedDiagnosticsWithOptions) 96protected AbstractBuiltInCodeStyleDiagnosticAnalyzer(ImmutableArray<(DiagnosticDescriptor Descriptor, ImmutableHashSet<IOption2> Options)> supportedDiagnosticsWithOptions) 108private static void AddDiagnosticIdToOptionMapping(string diagnosticId, IOption2? option) 116private static void AddDiagnosticIdToOptionMapping(string diagnosticId, ImmutableHashSet<IOption2> options)
src\Analyzers\Core\Analyzers\AbstractBuiltInUnnecessaryCodeStyleDiagnosticAnalyzer.cs (4)
41IOption2? option, 73ImmutableHashSet<IOption2> options, 103protected AbstractBuiltInUnnecessaryCodeStyleDiagnosticAnalyzer(ImmutableArray<(DiagnosticDescriptor Descriptor, IOption2 Option)> supportedDiagnosticsWithOptions, PerLanguageOption2<bool>? fadingOption) 112protected AbstractBuiltInUnnecessaryCodeStyleDiagnosticAnalyzer(ImmutableArray<(DiagnosticDescriptor Descriptor, ImmutableHashSet<IOption2> Options)> supportedDiagnosticsWithOptions, PerLanguageOption2<bool>? fadingOption)
src\Analyzers\Core\Analyzers\IDEDiagnosticIdToOptionMappingHelper.cs (10)
23private static readonly ConcurrentDictionary<string, ImmutableHashSet<IOption2>> s_diagnosticIdToOptionMap = new(); 24private static readonly ConcurrentDictionary<string, ConcurrentDictionary<string, ImmutableHashSet<IOption2>>> s_diagnosticIdToLanguageSpecificOptionsMap = new(); 27public static bool TryGetMappedOptions(string diagnosticId, string language, [NotNullWhen(true)] out ImmutableHashSet<IOption2>? options) 39public static void AddOptionMapping(string diagnosticId, ImmutableHashSet<IOption2> options) 45var multipleLanguagesOptionsBuilder = ImmutableHashSet.CreateBuilder<IOption2>(); 50foreach (var perLanguageValuedOption in group) 64foreach (var option in languageGroup) 71var map = s_diagnosticIdToLanguageSpecificOptionsMap.GetOrAdd(language, _ => new ConcurrentDictionary<string, ImmutableHashSet<IOption2>>()); 84private static void AddOptionMapping(ConcurrentDictionary<string, ImmutableHashSet<IOption2>> map, string diagnosticId, ImmutableHashSet<IOption2> options)
src\Analyzers\Core\Analyzers\ParenthesesDiagnosticAnalyzersHelper.cs (1)
16internal static ImmutableHashSet<IOption2> Options =
src\Analyzers\Core\Analyzers\ValidateFormatString\FormatStringValidationOptionStorage.cs (1)
17public static readonly ImmutableArray<IOption2> UnsupportedOptions = [ReportInvalidPlaceholdersInStringDotFormatCalls];
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\CodeStyle\CodeStyleHelpers.cs (3)
118this ImmutableArray<IOption2>.Builder optionsBuilder, 131this ImmutableArray<IOption2>.Builder optionsBuilder, 143this ImmutableArray<IOption2>.Builder optionsBuilder,
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\CodeStyle\CodeStyleOptions2.cs (3)
20private static readonly ImmutableArray<IOption2>.Builder s_editorConfigOptionsBuilder = ImmutableArray.CreateBuilder<IOption2>(); 350internal static readonly ImmutableArray<IOption2> EditorConfigOptions = s_editorConfigOptionsBuilder.ToImmutable();
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\CodeStyle\VisualBasic\VisualBasicCodeStyleOptions.cs (3)
16private static readonly ImmutableArray<IOption2>.Builder s_allOptionsBuilder = ImmutableArray.CreateBuilder<IOption2>(); 57public static ImmutableArray<IOption2> EditorConfigOptions => s_allOptionsBuilder.ToImmutable();
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Editing\GenerationOptions.cs (1)
30public static readonly ImmutableArray<IOption2> EditorConfigOptions = [PlaceSystemNamespaceFirst, SeparateImportDirectiveGroups];
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Extensions\AnalyzerConfigOptionsExtensions.cs (3)
15public static T GetEditorConfigOption<T>(this AnalyzerConfigOptions analyzerConfigOptions, IOption2 option, T defaultValue) 18public static T GetEditorConfigOptionValue<T>(this AnalyzerConfigOptions analyzerConfigOptions, IOption2 option, T defaultValue) 21public static bool TryGetEditorConfigOption<T>(this AnalyzerConfigOptions analyzerConfigOptions, IOption2 option, out T value)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Options\InternalOptionStorageMapping.cs (2)
11internal abstract class OptionStorageMapping(IOption2 internalOption) 16public IOption2 InternalOption { get; } = internalOption;
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Options\IOption2.cs (2)
13/// This ensures that all the sub-types of <see cref="IOption2"/> in either layer see an identical 16internal interface IOption2 : IEquatable<IOption2?>
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Options\Option2.cs (5)
42internal Option2(OptionDefinition<T> definition, string? languageName, Func<IOption2, IPublicOption>? publicOptionFactory) 77OptionDefinition IOption2.Definition => Definition; 80bool IOption2.IsPerLanguage => false; 94public override bool Equals(object? obj) => Equals(obj as IOption2); 96public bool Equals(IOption2? other)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Options\OptionKey2.cs (2)
18public IOption2 Option { get; } 21public OptionKey2(IOption2 option, string? language)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Options\PerLanguageOption2.cs (5)
33internal PerLanguageOption2(OptionDefinition<T> optionDefinition, Func<IOption2, IPublicOption>? publicOptionFactory) 64OptionDefinition IOption2.Definition => Definition; 68bool IOption2.IsPerLanguage => true; 81public override bool Equals(object? obj) => Equals(obj as IOption2); 83public bool Equals(IOption2? other)