2 instantiations of ParameterBindingMethodCache
Microsoft.AspNetCore.Mvc.Abstractions (2)
src\Shared\ParameterBindingMethodCache.cs (2)
30private static readonly Lazy<ParameterBindingMethodCache> _instance = new(() => new ParameterBindingMethodCache()); 32private static readonly Lazy<ParameterBindingMethodCache> _nonThrowingInstance = new(() => new ParameterBindingMethodCache(throwOnInvalidMethod: false));
9 references to ParameterBindingMethodCache
Microsoft.AspNetCore.Mvc.Abstractions (9)
ModelBinding\ModelMetadata.cs (1)
653return ParameterBindingMethodCache.NonThrowingInstance.FindTryParseMethod(modelType);
src\Shared\ParameterBindingMethodCache.cs (8)
15using static Microsoft.AspNetCore.Http.ParameterBindingMethodCache.SharedExpressions; 24private static readonly MethodInfo ConvertValueTaskMethod = typeof(ParameterBindingMethodCache).GetMethod(nameof(ConvertValueTask), BindingFlags.NonPublic | BindingFlags.Static)!; 25private static readonly MethodInfo ConvertValueTaskOfNullableResultMethod = typeof(ParameterBindingMethodCache).GetMethod(nameof(ConvertValueTaskOfNullableResult), BindingFlags.NonPublic | BindingFlags.Static)!; 26private static readonly MethodInfo BindAsyncMethod = typeof(ParameterBindingMethodCache).GetMethod(nameof(BindAsync), BindingFlags.NonPublic | BindingFlags.Static)!; 30private static readonly Lazy<ParameterBindingMethodCache> _instance = new(() => new ParameterBindingMethodCache()); 31public static ParameterBindingMethodCache Instance = _instance.Value; 32private static readonly Lazy<ParameterBindingMethodCache> _nonThrowingInstance = new(() => new ParameterBindingMethodCache(throwOnInvalidMethod: false)); 33public static ParameterBindingMethodCache NonThrowingInstance = _nonThrowingInstance.Value;