15 references to Parsability
Microsoft.AspNetCore.App.Analyzers (15)
RouteEmbeddedLanguage\FrameworkParametersCompletionProvider.cs (1)
396return ParsabilityHelper.GetParsability(typeSymbol, wellKnownTypes) == Parsability.Parsable;
RouteHandlers\DisallowNonParsableComplexTypesOnParameters.cs (4)
70var parsability = ParsabilityHelper.GetParsability(parameterTypeSymbol, wellKnownTypes); 72if (parsability != Parsability.Parsable) 100var parsability = ParsabilityHelper.GetParsability(parameterTypeSymbol, wellKnownTypes); 101if (parameter.HasAttributeImplementingInterface(fromMetadataInterfaceTypeSymbol) && parsability != Parsability.Parsable)
src\Shared\RoslynUtils\ParsabilityHelper.cs (10)
21private static readonly BoundedCacheWithFactory<ITypeSymbol, (Parsability, ParsabilityMethod?)> ParsabilityCache = new(); 50internal static Parsability GetParsability(ITypeSymbol typeSymbol, WellKnownTypes wellKnownTypes) 55internal static Parsability GetParsability(ITypeSymbol typeSymbol, WellKnownTypes wellKnownTypes, [NotNullWhen(false)] out ParsabilityMethod? parsabilityMethod) 57var parsability = Parsability.NotParsable; 64return (Parsability.Parsable, parsabilityMethod); 70return (Parsability.Parsable, ParsabilityMethod.IParsable); 80return (Parsability.Parsable, ParsabilityMethod.TryParseWithFormatProvider); 85return (Parsability.Parsable, ParsabilityMethod.TryParse); 88return (Parsability.NotParsable, null);