1 write to ModelBinderProviders
Microsoft.AspNetCore.Mvc.Core (1)
MvcOptions.cs (1)
46
ModelBinderProviders
= new List<IModelBinderProvider>();
63 references to ModelBinderProviders
Microsoft.AspNetCore.Mvc.Core (20)
Infrastructure\MvcCoreMvcOptionsSetup.cs (18)
48
options.
ModelBinderProviders
.Add(new BinderTypeModelBinderProvider());
49
options.
ModelBinderProviders
.Add(new ServicesModelBinderProvider());
50
options.
ModelBinderProviders
.Add(new BodyModelBinderProvider(options.InputFormatters, _readerFactory, _loggerFactory, options));
51
options.
ModelBinderProviders
.Add(new HeaderModelBinderProvider());
52
options.
ModelBinderProviders
.Add(new FloatingPointTypeModelBinderProvider());
53
options.
ModelBinderProviders
.Add(new EnumTypeModelBinderProvider(options));
54
options.
ModelBinderProviders
.Add(new DateTimeModelBinderProvider());
55
options.
ModelBinderProviders
.Add(new SimpleTypeModelBinderProvider());
56
options.
ModelBinderProviders
.Add(new TryParseModelBinderProvider());
57
options.
ModelBinderProviders
.Add(new CancellationTokenModelBinderProvider());
58
options.
ModelBinderProviders
.Add(new ByteArrayModelBinderProvider());
59
options.
ModelBinderProviders
.Add(new FormFileModelBinderProvider());
60
options.
ModelBinderProviders
.Add(new FormCollectionModelBinderProvider());
61
options.
ModelBinderProviders
.Add(new KeyValuePairModelBinderProvider());
62
options.
ModelBinderProviders
.Add(new DictionaryModelBinderProvider());
63
options.
ModelBinderProviders
.Add(new ArrayModelBinderProvider());
64
options.
ModelBinderProviders
.Add(new CollectionModelBinderProvider());
65
options.
ModelBinderProviders
.Add(new ComplexObjectModelBinderProvider());
ModelBinding\ModelBinderFactory.cs (2)
41
_providers = options.Value.
ModelBinderProviders
.ToArray();
59
nameof(MvcOptions.
ModelBinderProviders
),
Microsoft.AspNetCore.Mvc.Core.Test (31)
ModelBinding\Binders\ComplexObjectModelBinderTest.cs (10)
608
options.
ModelBinderProviders
.Insert(0, propertyBinder);
673
options.
ModelBinderProviders
.Insert(0, propertyBinder);
712
options.
ModelBinderProviders
.Insert(0, propertyBinder);
744
options.
ModelBinderProviders
.Insert(0, propertyBinder);
767
options.
ModelBinderProviders
.Insert(0, propertyBinder);
792
options.
ModelBinderProviders
.Insert(0, propertyBinder);
817
options.
ModelBinderProviders
.Insert(0, propertyBinder);
845
options.
ModelBinderProviders
.Insert(0, new TestModelBinderProvider(firstNameProperty, ModelBindingResult.Success("John")));
848
options.
ModelBinderProviders
.Insert(0, new TestModelBinderProvider(lastNameProperty, ModelBindingResult.Success("Doe")));
1092
var factory = TestModelBinderFactory.Create(options.Value.
ModelBinderProviders
.ToArray());
ModelBinding\Binders\ComplexTypeModelBinderTest.cs (4)
1252
var lastIndex = options.Value.
ModelBinderProviders
.Count - 1;
1253
options.Value.
ModelBinderProviders
.RemoveType<ComplexObjectModelBinderProvider>();
1254
options.Value.
ModelBinderProviders
.Add(new TestableComplexTypeModelBinderProvider());
1256
var factory = TestModelBinderFactory.Create(options.Value.
ModelBinderProviders
.ToArray());
ModelBinding\ModelBinderFactoryTest.cs (17)
20
var expected = $"'{typeof(MvcOptions).FullName}.{nameof(MvcOptions.
ModelBinderProviders
)}' must not be " +
44
options.Value.
ModelBinderProviders
.Add(new TestModelBinderProvider(_ => null));
70
options.Value.
ModelBinderProviders
.Add(new TestModelBinderProvider(c =>
110
options.Value.
ModelBinderProviders
.Add(new TestModelBinderProvider(c =>
145
options.Value.
ModelBinderProviders
.Add(new TestModelBinderProvider(c =>
186
options.Value.
ModelBinderProviders
.Add(new TestModelBinderProvider(c =>
224
options.Value.
ModelBinderProviders
.Add(new TestModelBinderProvider(c =>
255
options.Value.
ModelBinderProviders
.Add(new TestModelBinderProvider(c =>
370
options.Value.
ModelBinderProviders
.Insert(0, modelBinderProvider);
425
options.Value.
ModelBinderProviders
.Add(widgetProvider);
426
options.Value.
ModelBinderProviders
.Add(widgetIdProvider);
487
options.Value.
ModelBinderProviders
.Add(widgetProvider);
488
options.Value.
ModelBinderProviders
.Add(widgetIdProvider);
541
options.Value.
ModelBinderProviders
.Add(widgetProvider);
542
options.Value.
ModelBinderProviders
.Add(widgetIdProvider);
605
options.Value.
ModelBinderProviders
.Add(widgetProvider);
606
options.Value.
ModelBinderProviders
.Add(widgetIdProvider);
Microsoft.AspNetCore.Mvc.Core.TestCommon (2)
TestModelBinderFactory.cs (2)
39
options.Value.
ModelBinderProviders
.Add(provider);
61
options.Value.
ModelBinderProviders
.Add(provider);
Microsoft.AspNetCore.Mvc.IntegrationTests (9)
ActionParametersIntegrationTest.cs (2)
463
options.
ModelBinderProviders
.RemoveType<ComplexObjectModelBinderProvider>();
465
options.
ModelBinderProviders
.Add(new ComplexTypeModelBinderProvider());
BindingSourceMetadataProviderIntegrationTest.cs (2)
22
options.
ModelBinderProviders
.Insert(0, new CancellationTokenModelBinderProvider());
76
options.
ModelBinderProviders
.Insert(0, new FormFileModelBinderProvider());
ComplexTypeModelBinderIntegrationTest.cs (2)
24
options.
ModelBinderProviders
.RemoveType<ComplexObjectModelBinderProvider>();
25
options.
ModelBinderProviders
.Add(new ComplexTypeModelBinderProvider());
ExcludeBindingMetadataProviderIntegrationTest.cs (2)
23
options.
ModelBinderProviders
.Insert(0, modelBinderProvider);
68
options.
ModelBinderProviders
.Insert(0, modelBinderProvider);
ModelBindingTestHelper.cs (1)
94
options.Value.
ModelBinderProviders
.Insert(0, binderProvider);
Microsoft.AspNetCore.Mvc.Test (1)
MvcOptionsSetupTest.cs (1)
47
options.
ModelBinderProviders
,