3 instantiations of ObjectMethodExecutor
Microsoft.AspNetCore.Mvc.Core (3)
src\Shared\ObjectMethodExecutor\ObjectMethodExecutor.cs (3)
107
return new
ObjectMethodExecutor
(methodInfo, targetTypeInfo, null);
116
return new
ObjectMethodExecutor
(methodInfo, targetTypeInfo, parameterDefaultValues);
129
return new
ObjectMethodExecutor
(methodInfo, targetTypeInfo, isTrimAotCompatible: true);
79 references to ObjectMethodExecutor
Microsoft.AspNetCore.Mvc.Core (43)
Infrastructure\ActionMethodExecutor.cs (30)
35
ObjectMethodExecutor
executor,
39
protected abstract bool CanExecute(
ObjectMethodExecutor
executor);
43
public static ActionMethodExecutor GetExecutor(
ObjectMethodExecutor
executor)
71
ObjectMethodExecutor
executor,
86
protected override bool CanExecute(
ObjectMethodExecutor
executor)
99
ObjectMethodExecutor
executor,
109
var
executor = invocationContext.Executor;
117
protected override bool CanExecute(
ObjectMethodExecutor
executor)
128
ObjectMethodExecutor
executor,
140
var
executor = invocationContext.Executor;
150
protected override bool CanExecute(
ObjectMethodExecutor
executor)
161
ObjectMethodExecutor
executor,
173
var
executor = invocationContext.Executor;
185
protected override bool CanExecute(
ObjectMethodExecutor
executor) => !executor.IsMethodAsync;
194
ObjectMethodExecutor
executor,
204
var
executor = invocationContext.Executor;
212
protected override bool CanExecute(
ObjectMethodExecutor
executor) => executor.MethodReturnType == typeof(Task);
222
ObjectMethodExecutor
executor,
232
var
executor = invocationContext.Executor;
240
protected override bool CanExecute(
ObjectMethodExecutor
executor)
253
ObjectMethodExecutor
executor,
268
var
executor = invocationContext.Executor;
281
protected override bool CanExecute(
ObjectMethodExecutor
executor)
292
ObjectMethodExecutor
executor,
305
var
executor = invocationContext.Executor;
316
protected override bool CanExecute(
ObjectMethodExecutor
executor)
330
ObjectMethodExecutor
executor,
342
var
executor = invocationContext.Executor;
352
protected override bool CanExecute(
ObjectMethodExecutor
executor) => true;
355
private static void EnsureActionResultNotNull(
ObjectMethodExecutor
executor, IActionResult actionResult)
Infrastructure\ControllerActionInvoker.cs (3)
386
var
objectMethodExecutor = _cacheEntry.ObjectMethodExecutor;
410
var
objectMethodExecutor = invoker._cacheEntry.ObjectMethodExecutor;
529
ObjectMethodExecutor
actionMethodExecutor)
Infrastructure\ControllerActionInvokerCache.cs (2)
57
var
objectMethodExecutor =
ObjectMethodExecutor
.Create(
Infrastructure\ControllerActionInvokerCacheEntry.cs (2)
17
ObjectMethodExecutor
objectMethodExecutor,
38
internal
ObjectMethodExecutor
ObjectMethodExecutor { get; }
Infrastructure\ControllerEndpointFilterInvocationContext.cs (2)
17
ObjectMethodExecutor
executor,
36
internal
ObjectMethodExecutor
Executor { get; }
src\Shared\ObjectMethodExecutor\ObjectMethodExecutor.cs (3)
105
public static
ObjectMethodExecutor
Create(MethodInfo methodInfo, TypeInfo targetTypeInfo)
112
public static
ObjectMethodExecutor
Create(MethodInfo methodInfo, TypeInfo targetTypeInfo, object?[] parameterDefaultValues)
127
public static
ObjectMethodExecutor
CreateTrimAotCompatible(MethodInfo methodInfo, TypeInfo targetTypeInfo)
src\Shared\ObjectMethodExecutor\ObjectMethodExecutorAwaitable.cs (1)
12
/// Provides a common awaitable structure that <see cref="
ObjectMethodExecutor
.ExecuteAsync"/> can
Microsoft.AspNetCore.Mvc.Core.Test (27)
Filters\MiddlewareFilterTest.cs (3)
420
private static
ObjectMethodExecutor
CreateExecutor(ControllerActionDescriptor actionDescriptor)
422
return
ObjectMethodExecutor
.Create(actionDescriptor.MethodInfo, actionDescriptor.ControllerTypeInfo);
443
var
objectMethodExecutor = CreateExecutor(actionDescriptor);
Infrastructure\ActionMethodExecutorTest.cs (18)
20
var
objectMethodExecutor = GetExecutor(nameof(TestController.VoidAction));
46
var
objectMethodExecutor = GetExecutor(nameof(TestController.ReturnIActionResult));
72
var
objectMethodExecutor = GetExecutor(nameof(TestController.ReturnsIActionResultSubType));
97
var
objectMethodExecutor = GetExecutor(nameof(TestController.ReturnsActionResultOfT));
126
var
objectMethodExecutor = GetExecutor(nameof(TestController.ReturnsModelAsModel));
155
var
objectMethodExecutor = GetExecutor(nameof(TestController.ReturnModelAsObject));
184
var
objectMethodExecutor = GetExecutor(nameof(TestController.ReturnsIActionResultSubType));
209
var
objectMethodExecutor = GetExecutor(nameof(TestController.ReturnsTask));
235
var
objectMethodExecutor = GetExecutor(nameof(TestController.ReturnsAwaitable));
261
var
objectMethodExecutor = GetExecutor(nameof(TestController.ReturnIActionResultAsync));
286
var
objectMethodExecutor = GetExecutor(nameof(TestController.ReturnActionResultAsync));
312
var
objectMethodExecutor = GetExecutor(nameof(TestController.ReturnsModelAsModelAsync));
341
var
objectMethodExecutor = GetExecutor(nameof(TestController.ReturnsModelAsObjectAsync));
370
var
objectMethodExecutor = GetExecutor(nameof(TestController.ReturnIActionResultAsObjectAsync));
395
var
objectMethodExecutor = GetExecutor(nameof(TestController.ReturnActionResultOFTAsync));
424
var
objectMethodExecutor = GetExecutor(nameof(TestController.ReturnsCustomConvertibleFromIActionResult));
450
private static
ObjectMethodExecutor
GetExecutor(string methodName)
455
return
ObjectMethodExecutor
.Create(methodInfo, type.GetTypeInfo());
Infrastructure\ControllerActionInvokerTest.cs (6)
1416
var
objectMethodExecutor =
ObjectMethodExecutor
.Create(
1739
var
objectMethodExecutor =
ObjectMethodExecutor
.Create(
1966
private static
ObjectMethodExecutor
CreateExecutor(ControllerActionDescriptor actionDescriptor)
1968
return
ObjectMethodExecutor
.Create(
Microsoft.AspNetCore.Mvc.ViewFeatures (9)
ViewComponents\DefaultViewComponentInvoker.cs (4)
55
var
executor = _viewComponentInvokerCache.GetViewComponentMethodExecutor(context);
91
private async Task<IViewComponentResult> InvokeAsyncCore(
ObjectMethodExecutor
executor, object component, ViewComponentContext context)
148
private IViewComponentResult InvokeSyncCore(
ObjectMethodExecutor
executor, object component, ViewComponentContext context)
200
ObjectMethodExecutor
objectMethodExecutor)
ViewComponents\ViewComponentInvokerCache.cs (5)
39
internal
ObjectMethodExecutor
GetViewComponentMethodExecutor(ViewComponentContext viewComponentContext)
44
if (cache.Entries.TryGetValue(viewComponentDescriptor, out
var
executor))
60
executor =
ObjectMethodExecutor
.Create(
76
public ConcurrentDictionary<ViewComponentDescriptor,
ObjectMethodExecutor
> Entries { get; } =
77
new ConcurrentDictionary<ViewComponentDescriptor,
ObjectMethodExecutor
>();