37 references to ModelBinderAttribute
Microsoft.AspNetCore.Mvc.Abstractions.Test (1)
ModelBinding\BindingInfoTest.cs (1)
102
new
ModelBinderAttribute
{ BinderType = typeof(ComplexObjectModelBinder), Name = "Test" },
Microsoft.AspNetCore.Mvc.ApiExplorer.Test (3)
DefaultApiDescriptionProviderTest.cs (3)
2457
private void AcceptsProduct_Default([
ModelBinder
] Product product)
2490
private void AcceptsManager([
ModelBinder
] Manager dto)
2598
[
ModelBinder
]
Microsoft.AspNetCore.Mvc.Core.Test (16)
ApplicationModels\InferParameterBindingInfoConventionTest.cs (2)
1010
public IActionResult ModelBinderAttribute([
ModelBinder
(Name = "top")] int value) => null;
1070
public IActionResult ModelBinderAttributeWithExplicitModelName([
ModelBinder
(Name = "top")] int value) => null;
ModelBinding\Metadata\DefaultBindingMetadataProviderTest.cs (11)
17
new
ModelBinderAttribute
() { BinderType = typeof(HeaderModelBinder) },
18
new
ModelBinderAttribute
() { BinderType = typeof(ArrayModelBinder<string>) },
40
new
ModelBinderAttribute
(),
41
new
ModelBinderAttribute
() { BinderType = typeof(HeaderModelBinder) },
42
new
ModelBinderAttribute
() { BinderType = typeof(ArrayModelBinder<string>) },
64
new
ModelBinderAttribute
() { Name = "Product" },
65
new
ModelBinderAttribute
() { Name = "Order" },
87
new
ModelBinderAttribute
(),
88
new
ModelBinderAttribute
() { Name = "Product" },
89
new
ModelBinderAttribute
() { Name = "Order" },
134
new
ModelBinderAttribute
(),
ModelBinding\Metadata\ModelAttributesTest.cs (1)
332
[
ModelBinder
(Name = "Custom")]
ModelBinding\Metadata\ModelBinderAttributeTest.cs (2)
14
var attribute = new
ModelBinderAttribute
();
27
var attribute = new
ModelBinderAttribute
Microsoft.AspNetCore.Mvc.IntegrationTests (6)
ComplexRecordIntegrationTest.cs (2)
2629
[
ModelBinder
(Name = "HomeAddress")]
3021
private record TestInnerModel([
ModelBinder
(BinderType = typeof(NumberModelBinder))] decimal Rate);
ComplexTypeIntegrationTestBase.cs (2)
2805
[
ModelBinder
(Name = "HomeAddress")]
3234
[
ModelBinder
(BinderType = typeof(NumberModelBinder))]
FormFileModelBindingIntegrationTest.cs (2)
467
[
ModelBinder
(Name = "files")]
551
[
ModelBinder
(Name = "files")]
Microsoft.AspNetCore.Mvc.RazorPages.Test (6)
ApplicationModels\DefaultPageApplicationModelProviderTest.cs (5)
598
[
ModelBinder
]
608
[
ModelBinder
]
649
[
ModelBinder
]
661
[
ModelBinder
]
927
public void OnPost(string name, [
ModelBinder
(Name = "personId")] int id) { }
Infrastructure\PageBinderFactoryTest.cs (1)
934
[
ModelBinder
]
Microsoft.AspNetCore.OpenApi.Tests (1)
Services\OpenApiDocumentService\OpenApiDocumentServiceTests.Parameters.cs (1)
210
private void ActionWithCustomBinder([
ModelBinder
(BinderType = typeof(CustomBinder))] Todo model) { }
MvcSandbox (1)
Controllers\HomeController.cs (1)
10
[
ModelBinder
]
RazorPagesWebSite (3)
Pages\PropertyBinding\PageModelWithPropertyAndArgumentBinding.cs (1)
11
[
ModelBinder
]
Pages\PropertyBinding\PageModelWithPropertyBinding.cs (1)
11
[
ModelBinder
]
Pages\TryValidateModelPageModel.cs (1)
11
[
ModelBinder
]