26 instantiations of ModelExplorer
Microsoft.AspNetCore.Mvc.ViewFeatures (14)
DefaultDisplayTemplates.cs (1)
120var modelExplorer = new ModelExplorer(
DefaultEditorTemplates.cs (1)
102var modelExplorer = new ModelExplorer(
HtmlHelper.cs (1)
666modelExplorer = new ModelExplorer(
ModelExplorer.cs (8)
220return new ModelExplorer(_metadataProvider, Metadata, model); 224return new ModelExplorer(_metadataProvider, Container, Metadata, model); 272return new ModelExplorer(_metadataProvider, this, propertyMetadata, modelAccessor); 297return new ModelExplorer(_metadataProvider, this, propertyMetadata, model); 345return new ModelExplorer(_metadataProvider, this, metadata, model); 394return new ModelExplorer(_metadataProvider, this, metadata, modelAccessor); 416return new ModelExplorer(_metadataProvider, this, propertyMetadata, modelAccessor: null); 424return new ModelExplorer(_metadataProvider, this, propertyMetadata, modelAccessor);
ModelMetadataProviderExtensions.cs (1)
32return new ModelExplorer(provider, modelMetadata, model);
ViewDataDictionary.cs (2)
223ModelExplorer = new ModelExplorer( 477ModelExplorer = new ModelExplorer(_metadataProvider, ModelExplorer.Container, ModelMetadata, value);
Microsoft.AspNetCore.Mvc.ViewFeatures.Test (12)
DefaultHtmlGeneratorTest.cs (9)
200var modelExplorer = new ModelExplorer(metadataProvider, modelMetadata, null); 224var modelExplorer = new ModelExplorer(metadataProvider, modelMetadata, null); 248var modelExplorer = new ModelExplorer(metadataProvider, modelMetadata, null); 270var modelExplorer = new ModelExplorer(metadataProvider, modelMetadata, null); 292var modelExplorer = new ModelExplorer(metadataProvider, modelMetadata, null); 315var modelExplorer = new ModelExplorer(metadataProvider, modelMetadata, null); 368var modelExplorer = new ModelExplorer(metadataProvider, modelMetadata, null); 398var modelExplorer = new ModelExplorer(metadataProvider, modelMetadata, null); 423var modelExplorer = new ModelExplorer(metadataProvider, modelMetadata, null);
FormatWeekHelperTest.cs (1)
33var modelExplorer = new ModelExplorer(provider, metadata, model);
ViewDataDictionaryTest.cs (2)
350var explorer = new ModelExplorer(metadataProvider, metadata, model: null); 375var explorer = new ModelExplorer(metadataProvider, metadata, model: null);
307 references to ModelExplorer
Microsoft.AspNetCore.Mvc.Razor.Test (3)
RazorPageCreateModelExpressionTest.cs (3)
24var modelExplorer = viewContext.ViewData.ModelExplorer.GetExplorerForProperty( 49var modelExplorer = viewContext.ViewData.ModelExplorer.GetExplorerForProperty( 110var modelExplorer = viewData.ModelExplorer;
Microsoft.AspNetCore.Mvc.TagHelpers (9)
InputTagHelper.cs (9)
181var modelExplorer = For.ModelExplorer; 278/// <param name="modelExplorer">The <see cref="ModelExplorer"/> to use.</param> 282protected string GetInputType(ModelExplorer modelExplorer, out string inputTypeHint) 298ModelExplorer modelExplorer, 374private TagBuilder GenerateRadio(ModelExplorer modelExplorer, IDictionary<string, object> htmlAttributes) 396ModelExplorer modelExplorer, 450private TagBuilder GenerateHidden(ModelExplorer modelExplorer, IDictionary<string, object> htmlAttributes) 472private string GetFormat(ModelExplorer modelExplorer, string inputTypeHint, string inputType) 524private static IEnumerable<string> GetInputTypeHints(ModelExplorer modelExplorer)
Microsoft.AspNetCore.Mvc.TagHelpers.Test (47)
InputTagHelperTest.cs (14)
264var modelExplorer = metadataProvider.GetModelExplorerForType(typeof(bool), model); 307var modelExplorer = metadataProvider.GetModelExplorerForType(typeof(int), model); 359var modelExplorer = metadataProvider.GetModelExplorerForType(typeof(bool), model); 415var modelExplorer = metadataProvider.GetModelExplorerForType(typeof(bool), model); 471var modelExplorer = metadataProvider.GetModelExplorerForType(typeof(string), model); 520var modelExplorer = metadataProvider.GetModelExplorerForType(typeof(int), model); 846var modelExplorer = metadataProvider.GetModelExplorerForType(typeof(bool), model); 921var modelExplorer = metadataProvider.GetModelExplorerForType(typeof(bool), model); 980var modelExplorer = metadataProvider.GetModelExplorerForType(typeof(bool), model); 1040var modelExplorer = metadataProvider.GetModelExplorerForType(typeof(bool), model); 1100var modelExplorer = metadataProvider.GetModelExplorerForType(typeof(bool), model); 1342var modelExplorer = metadataProvider.GetModelExplorerForType(typeof(bool), model); 2401var containerExplorer = metadataProvider.GetModelExplorerForType(containerType, container); 2404var modelExplorer = containerExplorer.GetExplorerForExpression(propertyMetadata, model);
LabelTagHelperTest.cs (4)
169var containerExplorer = metadataProvider.GetModelExplorerForType(containerType, model); 172var modelExplorer = containerExplorer.GetExplorerForExpression(propertyMetadata, modelAccessor()); 299var containerExplorer = metadataProvider.GetModelExplorerForType(typeof(NestedModel), model: null); 300var modelExplorer = containerExplorer.GetExplorerForProperty(name);
PartialTagHelperTest.cs (12)
69var containerModelExplorer = modelMetadataProvider.GetModelExplorerForType( 72var propertyModelExplorer = containerModelExplorer.GetExplorerForProperty(nameof(TestModel.Property)); 110var containerModelExplorer = modelMetadataProvider.GetModelExplorerForType( 113var propertyModelExplorer = containerModelExplorer.GetExplorerForProperty(nameof(TestModel.Property)); 132var containerModelExplorer = modelMetadataProvider.GetModelExplorerForType( 135var propertyModelExplorer = containerModelExplorer.GetExplorerForProperty(nameof(TestModel.Property)); 319var containerModelExplorer = modelMetadataProvider.GetModelExplorerForType( 322var propertyModelExplorer = containerModelExplorer.GetExplorerForProperty(nameof(TestModel.Property)); 366var containerModelExplorer = modelMetadataProvider.GetModelExplorerForType( 369var propertyModelExplorer = containerModelExplorer.GetExplorerForProperty(nameof(TestModel.Property)); 413var containerModelExplorer = modelMetadataProvider.GetModelExplorerForType( 416var propertyModelExplorer = containerModelExplorer.GetExplorerForProperty(nameof(TestModel.Property));
SelectTagHelperTest.cs (10)
191var containerExplorer = metadataProvider.GetModelExplorerForType(containerType, model); 194var modelExplorer = containerExplorer.GetExplorerForExpression(propertyMetadata, modelAccessor()); 281var containerExplorer = metadataProvider.GetModelExplorerForType(containerType, model); 284var modelExplorer = containerExplorer.GetExplorerForExpression(propertyMetadata, modelAccessor()); 461var containerExplorer = metadataProvider.GetModelExplorerForType(containerType, model); 464var modelExplorer = containerExplorer.GetExplorerForExpression(propertyMetadata, modelAccessor()); 574var modelExplorer = metadataProvider.GetModelExplorerForType(typeof(string), model); 655var modelExplorer = metadataProvider.GetModelExplorerForType(modelType, model); 714var modelExplorer = metadataProvider.GetModelExplorerForType(typeof(string), model); 746var modelExplorer = metadataProvider.GetModelExplorerForType(typeof(string), model);
TestableHtmlGenerator.cs (1)
113ModelExplorer modelExplorer,
TextAreaTagHelperTest.cs (4)
100var containerExplorer = metadataProvider.GetModelExplorerForType(containerType, container); 103var modelExplorer = containerExplorer.GetExplorerForExpression(propertyMetadata, model); 169var modelExplorer = metadataProvider.GetModelExplorerForType(typeof(string), model); 202var modelExplorer = metadataProvider.GetModelExplorerForType(typeof(string), model);
ValidationMessageTagHelperTest.cs (2)
309It.IsAny<ModelExplorer>(), 372It.IsAny<ModelExplorer>(),
Microsoft.AspNetCore.Mvc.ViewFeatures (184)
DefaultDisplayTemplates.cs (4)
120var modelExplorer = new ModelExplorer( 190var modelExplorer = viewData.ModelExplorer; 213foreach (var propertyExplorer in modelExplorer.PropertiesInternal) 258private static bool ShouldShow(ModelExplorer modelExplorer, TemplateInfo templateInfo)
DefaultEditorTemplates.cs (4)
102var modelExplorer = new ModelExplorer( 232var modelExplorer = viewData.ModelExplorer; 255foreach (var propertyExplorer in modelExplorer.PropertiesInternal) 326private static bool ShouldShow(ModelExplorer modelExplorer, TemplateInfo templateInfo)
DefaultHtmlGenerator.cs (20)
189ModelExplorer modelExplorer, 235ModelExplorer modelExplorer, 330ModelExplorer modelExplorer, 362ModelExplorer modelExplorer, 400ModelExplorer modelExplorer, 425ModelExplorer modelExplorer, 507ModelExplorer modelExplorer, 531ModelExplorer modelExplorer, 598ModelExplorer modelExplorer, 686ModelExplorer modelExplorer, 712ModelExplorer modelExplorer, 902ModelExplorer modelExplorer, 1119/// <param name="modelExplorer">The <see cref="ModelExplorer"/>.</param> 1132ModelExplorer modelExplorer, 1300/// <param name="modelExplorer">The <see cref="ModelExplorer"/> for the <paramref name="expression"/>.</param> 1305ModelExplorer modelExplorer, 1325/// <param name="modelExplorer">The <see cref="ModelExplorer"/> for the <paramref name="expression"/>.</param> 1330ModelExplorer modelExplorer, 1363/// <param name="modelExplorer">The <see cref="ModelExplorer"/> for the <paramref name="expression"/>.</param> 1368ModelExplorer modelExplorer,
DefaultValidationHtmlAttributeProvider.cs (1)
46ModelExplorer modelExplorer,
ExpressionMetadataProvider.cs (7)
14public static ModelExplorer FromLambdaExpression<TModel, TResult>( 125/// Gets <see cref="ModelExplorer"/> for named <paramref name="expression"/> in given 134/// <see cref="ModelExplorer"/> for named <paramref name="expression"/> in given <paramref name="viewData"/>. 136public static ModelExplorer FromStringExpression( 147var propertyExplorer = viewData.ModelExplorer.GetExplorerForProperty(expression); 165ModelExplorer containerExplorer = viewData.ModelExplorer; 195private static ModelExplorer FromModel(
FormatWeekHelper.cs (1)
10public static string GetFormattedWeek(ModelExplorer modelExplorer)
HtmlHelper.cs (33)
311var metadata = ExpressionMetadataProvider.FromStringExpression(expression, ViewData, MetadataProvider); 323var modelExplorer = ExpressionMetadataProvider.FromStringExpression(expression, ViewData, MetadataProvider); 330var modelExplorer = ExpressionMetadataProvider.FromStringExpression(expression, ViewData, MetadataProvider); 356var modelExplorer = ExpressionMetadataProvider.FromStringExpression(expression, ViewData, MetadataProvider); 420var modelExplorer = ExpressionMetadataProvider.FromStringExpression(expression, ViewData, MetadataProvider); 471/// <param name="modelExplorer">The <see cref="ModelExplorer"/>.</param> 477ModelExplorer modelExplorer, 657var modelExplorer = ExpressionMetadataProvider.FromStringExpression(expression, ViewData, MetadataProvider); 706/// <param name="modelExplorer">The <see cref="ModelExplorer"/>.</param> 715ModelExplorer modelExplorer, 766/// <param name="modelExplorer">The <see cref="ModelExplorer"/>.</param> 769protected virtual string GenerateDisplayName(ModelExplorer modelExplorer, string expression) 797/// <param name="modelExplorer">The <see cref="ModelExplorer"/>.</param> 799protected virtual string GenerateDisplayText(ModelExplorer modelExplorer) 807/// <param name="modelExplorer">The <see cref="ModelExplorer"/>.</param> 817ModelExplorer modelExplorer, 842/// <param name="modelExplorer">The <see cref="ModelExplorer"/>.</param> 848ModelExplorer modelExplorer, 995ModelExplorer modelExplorer, 1031/// <param name="modelExplorer">The <see cref="ModelExplorer"/>.</param> 1040ModelExplorer modelExplorer, 1083/// <param name="modelExplorer">The <see cref="ModelExplorer"/>.</param> 1092ModelExplorer modelExplorer, 1127/// <param name="modelExplorer">The <see cref="ModelExplorer"/>.</param> 1136ModelExplorer modelExplorer, 1158/// <param name="modelExplorer">The <see cref="ModelExplorer"/>.</param> 1168ModelExplorer modelExplorer, 1192/// <param name="modelExplorer">The <see cref="ModelExplorer"/>.</param> 1202ModelExplorer modelExplorer, 1226/// <param name="modelExplorer">The <see cref="ModelExplorer"/>.</param> 1236ModelExplorer modelExplorer, 1260/// <param name="modelExplorer">The <see cref="ModelExplorer"/>.</param> 1270ModelExplorer modelExplorer,
HtmlHelperOfT.cs (3)
327/// Gets the <see cref="ModelExplorer"/> for <paramref name="expression"/>. 331/// <returns>The <see cref="ModelExplorer"/>.</returns> 332protected ModelExplorer GetModelExplorer<TResult>(Expression<Func<TModel, TResult>> expression)
IHtmlGenerator.cs (23)
123/// <param name="modelExplorer">The <see cref="ModelExplorer"/> for the <paramref name="expression"/>.</param> 135ModelExplorer modelExplorer, 147ModelExplorer modelExplorer, 241/// <param name="modelExplorer">The <see cref="ModelExplorer"/> for the <paramref name="expression"/>.</param> 254ModelExplorer modelExplorer, 264/// <param name="modelExplorer">The <see cref="ModelExplorer"/> for the <paramref name="expression"/>.</param> 276ModelExplorer modelExplorer, 285/// <param name="modelExplorer">The <see cref="ModelExplorer"/> for the <paramref name="expression"/>.</param> 297ModelExplorer modelExplorer, 306/// <param name="modelExplorer">The <see cref="ModelExplorer"/> for the <paramref name="expression"/>.</param> 319ModelExplorer modelExplorer, 362/// <see cref="ModelExplorer"/> for the <paramref name="expression"/>. If <c>null</c>, determines validation 393ModelExplorer modelExplorer, 405/// <see cref="ModelExplorer"/> for the <paramref name="expression"/>. If <c>null</c>, determines validation 442ModelExplorer modelExplorer, 467/// <param name="modelExplorer">The <see cref="ModelExplorer"/> for the <paramref name="expression"/>.</param> 480ModelExplorer modelExplorer, 490/// <param name="modelExplorer">The <see cref="ModelExplorer"/> for the <paramref name="expression"/>.</param> 503ModelExplorer modelExplorer, 514/// <param name="modelExplorer">The <see cref="ModelExplorer"/> for the <paramref name="expression"/>.</param> 533ModelExplorer modelExplorer, 565/// <see cref="ModelExplorer"/> for the <paramref name="expression"/>. If <c>null</c>, calculates the 596ModelExplorer modelExplorer,
ModelExplorer.cs (57)
20private ModelExplorer[] _properties; 23/// Creates a new <see cref="ModelExplorer"/>. 42/// Creates a new <see cref="ModelExplorer"/>. 45/// <param name="container">The container <see cref="ModelExplorer"/>.</param> 50ModelExplorer container, 65/// Creates a new <see cref="ModelExplorer"/>. 68/// <param name="container">The container <see cref="ModelExplorer"/>.</param> 73ModelExplorer container, 87/// Gets the container <see cref="ModelExplorer"/>. 92/// <see cref="GetExplorerForProperty(string)"/>. In this case, the returned <see cref="ModelExplorer"/> will 99/// occur when constructing a <see cref="ModelExplorer"/> based on evaluation of a complex 103/// If calling code relies on a parent-child relationship between <see cref="ModelExplorer"/> 107public ModelExplorer Container { get; } 119/// <see cref="ModelExplorer"/> was provided with one. 140/// <see cref="ModelExplorer"/> was provided with one. 170/// Includes a <see cref="ModelExplorer"/> for each property of the <see cref="ModelMetadata"/> 173public IEnumerable<ModelExplorer> Properties => PropertiesInternal; 175internal ModelExplorer[] PropertiesInternal 185_properties = new ModelExplorer[properties.Count]; 212/// Gets a <see cref="ModelExplorer"/> for the given <paramref name="model"/> value. 215/// <returns>A <see cref="ModelExplorer"/>.</returns> 216public ModelExplorer GetExplorerForModel(object model) 229/// Gets a <see cref="ModelExplorer"/> for the property with given <paramref name="name"/>, or <c>null</c> if 233/// <returns>A <see cref="ModelExplorer"/>, or <c>null</c>.</returns> 234public ModelExplorer GetExplorerForProperty(string name) 240var property = PropertiesInternal[i]; 251/// Gets a <see cref="ModelExplorer"/> for the property with given <paramref name="name"/>, or <c>null</c> if 256/// <returns>A <see cref="ModelExplorer"/>, or <c>null</c>.</returns> 260public ModelExplorer GetExplorerForProperty(string name, Func<object, object> modelAccessor) 276/// Gets a <see cref="ModelExplorer"/> for the property with given <paramref name="name"/>, or <c>null</c> if 281/// <returns>A <see cref="ModelExplorer"/>, or <c>null</c>.</returns> 285public ModelExplorer GetExplorerForProperty(string name, object model) 301/// Gets a <see cref="ModelExplorer"/> for the provided model value and model <see cref="Type"/>. 305/// <returns>A <see cref="ModelExplorer"/>.</returns> 308/// A <see cref="ModelExplorer"/> created by <see cref="GetExplorerForExpression(Type, object)"/> 310/// in the current <see cref="ModelExplorer"/> instance. 313/// The returned <see cref="ModelExplorer"/> will have the current instance set as its <see cref="Container"/>. 316public ModelExplorer GetExplorerForExpression(Type modelType, object model) 325/// Gets a <see cref="ModelExplorer"/> for the provided model value and model <see cref="Type"/>. 329/// <returns>A <see cref="ModelExplorer"/>.</returns> 332/// A <see cref="ModelExplorer"/> created by 335/// in the current <see cref="ModelExplorer"/> instance. 338/// The returned <see cref="ModelExplorer"/> will have the current instance set as its <see cref="Container"/>. 341public ModelExplorer GetExplorerForExpression(ModelMetadata metadata, object model) 349/// Gets a <see cref="ModelExplorer"/> for the provided model value and model <see cref="Type"/>. 353/// <returns>A <see cref="ModelExplorer"/>.</returns> 356/// A <see cref="ModelExplorer"/> created by 359/// in the current <see cref="ModelExplorer"/> instance. 362/// The returned <see cref="ModelExplorer"/> will have the current instance set as its <see cref="Container"/>. 365public ModelExplorer GetExplorerForExpression(Type modelType, Func<object, object> modelAccessor) 374/// Gets a <see cref="ModelExplorer"/> for the provided model value and model <see cref="Type"/>. 378/// <returns>A <see cref="ModelExplorer"/>.</returns> 381/// A <see cref="ModelExplorer"/> created by 384/// in the current <see cref="ModelExplorer"/> instance. 387/// The returned <see cref="ModelExplorer"/> will have the current instance set as its <see cref="Container"/>. 390public ModelExplorer GetExplorerForExpression(ModelMetadata metadata, Func<object, object> modelAccessor) 410private ModelExplorer CreateExplorerForProperty(
ModelExplorerExtensions.cs (7)
10/// Extension methods for <see cref="ModelExplorer"/>. 15/// Gets a simple display string for the <see cref="ModelExplorer.Model"/> property 18/// <param name="modelExplorer">The <see cref="ModelExplorer"/>.</param> 23/// <see cref="ModelExplorer.Model" /> converted to string (if the result is interesting), 29public static string GetSimpleDisplayText(this ModelExplorer modelExplorer) 35var propertyExplorer = modelExplorer.GetExplorerForProperty( 80var firstProperty = modelExplorer.PropertiesInternal[0];
ModelExpression.cs (3)
22public ModelExpression(string name, ModelExplorer modelExplorer) 54/// Getting <see cref="ModelExplorer.Model"/> will evaluate a compiled version of the original 57public ModelExplorer ModelExplorer { get; }
ModelExpressionProvider.cs (2)
53var modelExplorer = ExpressionMetadataProvider.FromLambdaExpression(expression, viewData, _modelMetadataProvider); 78var modelExplorer = ExpressionMetadataProvider.FromStringExpression(expression, viewData, _modelMetadataProvider);
ModelMetadataProviderExtensions.cs (3)
14/// Gets a <see cref="ModelExplorer"/> for the provided <paramref name="modelType"/> and 21/// A <see cref="ModelExplorer"/> for the <paramref name="modelType"/> and <paramref name="model"/>. 23public static ModelExplorer GetModelExplorerForType(
TemplateBuilder.cs (2)
20private readonly ModelExplorer _modelExplorer; 33ModelExplorer modelExplorer,
TemplateInfo.cs (2)
113/// <param name="modelExplorer">The <see cref="ModelExplorer"/>.</param> 115public bool Visited(ModelExplorer modelExplorer)
ValidationHelpers.cs (1)
27ModelExplorer modelExplorer)
ValidationHtmlAttributeProvider.cs (4)
18/// <param name="modelExplorer">The <see cref="ModelExplorer"/> for an expression.</param> 29ModelExplorer modelExplorer, 38/// <param name="modelExplorer">The <see cref="ModelExplorer"/> for the <paramref name="expression"/>.</param> 52ModelExplorer modelExplorer,
ViewDataDictionary.cs (7)
31/// <see cref="IModelMetadataProvider"/> instance used to create <see cref="ViewFeatures.ModelExplorer"/> 68/// <see cref="IModelMetadataProvider"/> instance used to create <see cref="ViewFeatures.ModelExplorer"/> 81/// <see cref="IModelMetadataProvider"/> instance used to create <see cref="ViewFeatures.ModelExplorer"/> 101/// <see cref="IModelMetadataProvider"/> instance used to create <see cref="ViewFeatures.ModelExplorer"/> 294/// Gets or sets the <see cref="ViewFeatures.ModelExplorer"/> for the <see cref="Model"/>. 296public ModelExplorer ModelExplorer { get; set; } = default!; 434/// Set <see cref="ModelExplorer"/> to ensure <see cref="Model"/> and <see cref="ModelExplorer.Model"/>
Microsoft.AspNetCore.Mvc.ViewFeatures.Test (64)
DefaultHtmlGeneratorTest.cs (20)
54var modelExplorer = metadataProvider.GetModelExplorerForType(typeof(string), model: null); 74var modelExplorer = metadataProvider.GetModelExplorerForType(typeof(string), model: null); 87var modelExplorer = metadataProvider.GetModelExplorerForType(typeof(string), model: null); 115var modelExplorer = metadataProvider.GetModelExplorerForType(typeof(string), model: null); 143var modelExplorer = metadataProvider.GetModelExplorerForType(typeof(string), model: null); 170var modelExplorer = metadataProvider.GetModelExplorerForType(typeof(string), model: null); 200var modelExplorer = new ModelExplorer(metadataProvider, modelMetadata, null); 224var modelExplorer = new ModelExplorer(metadataProvider, modelMetadata, null); 248var modelExplorer = new ModelExplorer(metadataProvider, modelMetadata, null); 270var modelExplorer = new ModelExplorer(metadataProvider, modelMetadata, null); 292var modelExplorer = new ModelExplorer(metadataProvider, modelMetadata, null); 315var modelExplorer = new ModelExplorer(metadataProvider, modelMetadata, null); 368var modelExplorer = new ModelExplorer(metadataProvider, modelMetadata, null); 398var modelExplorer = new ModelExplorer(metadataProvider, modelMetadata, null); 423var modelExplorer = new ModelExplorer(metadataProvider, modelMetadata, null); 443var modelExplorer = metadataProvider.GetModelExplorerForType(typeof(string), model: null); 470var modelExplorer = metadataProvider.GetModelExplorerForType(typeof(string), model: null); 620var modelExplorer = metadataProvider.GetModelExplorerForType(typeof(string), "ignored model value"); 668var modelExplorer = metadataProvider.GetModelExplorerForType(typeof(string), rawValue); 774var modelExplorer =
DefaultValidationHtmlAttributeProviderTest.cs (11)
30var modelExplorer = metadataProvider 65var modelExplorer = metadataProvider 101var modelExplorer = metadataProvider 124var modelExplorer = metadataProvider 132It.IsAny<ModelExplorer>(), 149It.IsAny<ModelExplorer>(), 165var modelExplorer = metadataProvider 199var modelExplorer = metadataProvider 207It.IsAny<ModelExplorer>(), 224It.IsAny<ModelExplorer>(), 237var modelExplorer = metadataProvider
ExpressionMetadataProviderTest.cs (10)
25var explorer = ExpressionMetadataProvider.FromLambdaExpression(m => m, viewData, provider); 43var explorer = ExpressionMetadataProvider.FromLambdaExpression(m => m.SelectedCategory, viewData, provider); 61var explorer = ExpressionMetadataProvider.FromLambdaExpression(m => m[23], viewData, provider); 80var explorer = ExpressionMetadataProvider.FromLambdaExpression( 103var metadata = ExpressionMetadataProvider.FromLambdaExpression<TestModel, Category>( 127var explorer = ExpressionMetadataProvider.FromStringExpression(expression, viewData, provider); 147var metadata = ExpressionMetadataProvider.FromStringExpression("Object.SelectedCategory", 165var explorer = ExpressionMetadataProvider.FromLambdaExpression( 187var explorer = ExpressionMetadataProvider.FromLambdaExpression( 209var explorer = ExpressionMetadataProvider.FromLambdaExpression(
FormatWeekHelperTest.cs (1)
33var modelExplorer = new ModelExplorer(provider, metadata, model);
ModelExplorerExtensionsTest.cs (1)
52var modelExplorer = provider.GetModelExplorerForType(modelType, model);
ModelExplorerTest.cs (13)
15var modelExplorer = provider.GetModelExplorerForType(typeof(BaseClass), new DerivedClass()); 29var modelExplorer = provider.GetModelExplorerForType(typeof(BaseClass), model: null); 43var modelExplorer = provider.GetModelExplorerForType(typeof(BaseClass), new DerivedClass()); 51var baseProperty = Assert.Single(properties, p => p.Metadata.PropertyName == "Base1"); 56var derivedProperty = Assert.Single(properties, p => p.Metadata.PropertyName == "Derived1"); 67var modelExplorer = provider.GetModelExplorerForType(typeof(BaseClass), model: null); 75var baseProperty = Assert.Single(properties, p => p.Metadata.PropertyName == "Base1"); 91var modelExplorer = provider.GetModelExplorerForType(typeof(BaseClass), model); 94var propertyExplorer = modelExplorer.GetExplorerForProperty("Base1"); 109var modelExplorer = provider.GetModelExplorerForType(typeof(BaseClass), model: null); 111var propertyExplorer = modelExplorer.GetExplorerForProperty("Base1"); 130var modelExplorer = provider.GetModelExplorerForType(typeof(BaseClass), model); 133var propertyExplorer = modelExplorer.GetExplorerForProperty("BadName");
Rendering\DefaultTemplatesUtilities.cs (2)
330var modelExplorer = helper.MetadataProvider.GetModelExplorerForType(model.GetType(), model); 334private static string FormatOutput(ModelExplorer modelExplorer)
Rendering\HtmlHelperLabelExtensionsTest.cs (1)
115var modelExplorer = provider
ViewDataDictionaryTest.cs (5)
328var originalExplorer = viewData.ModelExplorer; 350var explorer = new ModelExplorer(metadataProvider, metadata, model: null); 375var explorer = new ModelExplorer(metadataProvider, metadata, model: null); 420var originalExplorer = viewData.ModelExplorer; 447var originalExplorer = viewData.ModelExplorer;