166 instantiations of DisplayAttribute
BasicWebSite (3)
Models\LoginViewModel.cs (3)
11
[
Display
(Name = "User name")]
16
[
Display
(Name = "Password")]
19
[
Display
(Name = "Remember me?")]
FormatterWebSite (1)
Controllers\TopLevelValidationController.cs (1)
35
[Range(1, 100),
Display
(Name = "Some Display Name For Param")] int optionalRangeDisplayNameParam)
HtmlGenerationWebSite (4)
Models\Item.cs (3)
11
[
Display
(Name = "ItemName")]
15
[
Display
(Name = "ItemNo")]
18
[
Display
(Name = "ItemDesc")]
Models\Month.cs (1)
10
[
Display
(Name = "January")]
Identity.ExternalClaims (15)
Pages\Account\Login.cshtml.cs (1)
49
[
Display
(Name = "Remember me?")]
Pages\Account\LoginWith2fa.cshtml.cs (2)
40
[
Display
(Name = "Authenticator code")]
43
[
Display
(Name = "Remember this machine")]
Pages\Account\LoginWithRecoveryCode.cshtml.cs (1)
38
[
Display
(Name = "Recovery Code")]
Pages\Account\Manage\ChangePassword.cshtml.cs (3)
43
[
Display
(Name = "Current password")]
49
[
Display
(Name = "New password")]
53
[
Display
(Name = "Confirm new password")]
Pages\Account\Manage\EnableAuthenticator.cshtml.cs (1)
51
[
Display
(Name = "Verification Code")]
Pages\Account\Manage\Index.cshtml.cs (1)
51
[
Display
(Name = "Phone number")]
Pages\Account\Manage\SetPassword.cshtml.cs (2)
40
[
Display
(Name = "New password")]
44
[
Display
(Name = "Confirm new password")]
Pages\Account\Register.cshtml.cs (3)
46
[
Display
(Name = "Email")]
52
[
Display
(Name = "Password")]
56
[
Display
(Name = "Confirm password")]
Pages\Account\ResetPassword.cshtml.cs (1)
40
[
Display
(Name = "Confirm password")]
IdentitySample.DefaultUI (8)
Areas\Identity\Pages\Account\Manage\Index.cshtml.cs (3)
36
[
Display
(Name = "Phone number")]
41
[
Display
(Name = "Full Name")]
46
[
Display
(Name = "Age")]
Areas\Identity\Pages\Account\Register.cshtml.cs (5)
45
[
Display
(Name = "Email")]
51
[
Display
(Name = "Password")]
55
[
Display
(Name = "Confirm password")]
61
[
Display
(Name = "Full name")]
66
[
Display
(Name = "Age")]
IdentitySample.Mvc (16)
Models\AccountViewModels\LoginViewModel.cs (1)
18
[
Display
(Name = "Remember me?")]
Models\AccountViewModels\RegisterViewModel.cs (3)
12
[
Display
(Name = "Email")]
18
[
Display
(Name = "Password")]
22
[
Display
(Name = "Confirm password")]
Models\AccountViewModels\ResetPasswordViewModel.cs (1)
20
[
Display
(Name = "Confirm password")]
Models\AccountViewModels\VerifyAuthenticatorCodeViewModel.cs (2)
15
[
Display
(Name = "Remember this browser?")]
18
[
Display
(Name = "Remember me?")]
Models\AccountViewModels\VerifyCodeViewModel.cs (2)
18
[
Display
(Name = "Remember this browser?")]
21
[
Display
(Name = "Remember me?")]
Models\ManageViewModels\AddPhoneNumberViewModel.cs (1)
12
[
Display
(Name = "Phone number")]
Models\ManageViewModels\ChangePasswordViewModel.cs (3)
12
[
Display
(Name = "Current password")]
18
[
Display
(Name = "New password")]
22
[
Display
(Name = "Confirm new password")]
Models\ManageViewModels\SetPasswordViewModel.cs (2)
13
[
Display
(Name = "New password")]
17
[
Display
(Name = "Confirm new password")]
Models\ManageViewModels\VerifyPhoneNumberViewModel.cs (1)
15
[
Display
(Name = "Phone number")]
Microsoft.AspNetCore.Identity.UI (32)
Areas\Identity\Pages\V4\Account\Login.cshtml.cs (1)
75
[
Display
(Name = "Remember me?")]
Areas\Identity\Pages\V4\Account\LoginWith2fa.cshtml.cs (2)
53
[
Display
(Name = "Authenticator code")]
60
[
Display
(Name = "Remember this machine")]
Areas\Identity\Pages\V4\Account\LoginWithRecoveryCode.cshtml.cs (1)
47
[
Display
(Name = "Recovery Code")]
Areas\Identity\Pages\V4\Account\Manage\ChangePassword.cshtml.cs (3)
44
[
Display
(Name = "Current password")]
54
[
Display
(Name = "New password")]
62
[
Display
(Name = "Confirm new password")]
Areas\Identity\Pages\V4\Account\Manage\Email.cshtml.cs (1)
58
[
Display
(Name = "New email")]
Areas\Identity\Pages\V4\Account\Manage\EnableAuthenticator.cshtml.cs (1)
68
[
Display
(Name = "Verification Code")]
Areas\Identity\Pages\V4\Account\Manage\Index.cshtml.cs (1)
48
[
Display
(Name = "Phone number")]
Areas\Identity\Pages\V4\Account\Manage\SetPassword.cshtml.cs (2)
44
[
Display
(Name = "New password")]
52
[
Display
(Name = "Confirm new password")]
Areas\Identity\Pages\V4\Account\Register.cshtml.cs (3)
57
[
Display
(Name = "Email")]
67
[
Display
(Name = "Password")]
75
[
Display
(Name = "Confirm password")]
Areas\Identity\Pages\V4\Account\ResetPassword.cshtml.cs (1)
56
[
Display
(Name = "Confirm password")]
Areas\Identity\Pages\V5\Account\Login.cshtml.cs (1)
75
[
Display
(Name = "Remember me?")]
Areas\Identity\Pages\V5\Account\LoginWith2fa.cshtml.cs (2)
53
[
Display
(Name = "Authenticator code")]
60
[
Display
(Name = "Remember this machine")]
Areas\Identity\Pages\V5\Account\LoginWithRecoveryCode.cshtml.cs (1)
47
[
Display
(Name = "Recovery Code")]
Areas\Identity\Pages\V5\Account\Manage\ChangePassword.cshtml.cs (3)
44
[
Display
(Name = "Current password")]
54
[
Display
(Name = "New password")]
62
[
Display
(Name = "Confirm new password")]
Areas\Identity\Pages\V5\Account\Manage\Email.cshtml.cs (1)
58
[
Display
(Name = "New email")]
Areas\Identity\Pages\V5\Account\Manage\EnableAuthenticator.cshtml.cs (1)
68
[
Display
(Name = "Verification Code")]
Areas\Identity\Pages\V5\Account\Manage\Index.cshtml.cs (1)
48
[
Display
(Name = "Phone number")]
Areas\Identity\Pages\V5\Account\Manage\SetPassword.cshtml.cs (2)
44
[
Display
(Name = "New password")]
52
[
Display
(Name = "Confirm new password")]
Areas\Identity\Pages\V5\Account\Register.cshtml.cs (3)
57
[
Display
(Name = "Email")]
67
[
Display
(Name = "Password")]
75
[
Display
(Name = "Confirm password")]
Areas\Identity\Pages\V5\Account\ResetPassword.cshtml.cs (1)
56
[
Display
(Name = "Confirm password")]
Microsoft.AspNetCore.Mvc.Core.Test (2)
ModelBinding\Validation\DefaultObjectValidatorTests.cs (2)
1555
[
Display
(Name = "Never valid")]
1563
[
Display
(Name = "Never valid")]
Microsoft.AspNetCore.Mvc.DataAnnotations.Test (46)
CompareAttributeAdapterTest.cs (2)
240
[
Display
(Name = "MyPropertyDisplayName")]
243
[
Display
(Name = "OtherPropertyDisplayName")]
DataAnnotationsMetadataProviderTest.cs (27)
20
[
Display
(Name = "DisplayNameValue")]
35
{ new
DisplayAttribute
() { Description = "d" }, d => d.Description(), "d" },
36
{ new
DisplayAttribute
() { Name = "DN" }, d => d.DisplayName(), "DN" },
37
{ new
DisplayAttribute
() { Order = 3 }, d => d.Order, 3 },
38
{ new
DisplayAttribute
() { Prompt = "Enter Value" }, d => d.Placeholder(), "Enter Value" },
192
var display = new
DisplayAttribute
()
215
var display = new
DisplayAttribute
()
238
var display = new
DisplayAttribute
()
348
var display = new
DisplayAttribute
()
372
var display = new
DisplayAttribute
()
407
var display = new
DisplayAttribute
()
442
var display = new
DisplayAttribute
()
471
var display = new
DisplayAttribute
()
506
var display = new
DisplayAttribute
()
535
var display = new
DisplayAttribute
()
584
var display = new
DisplayAttribute
()
1789
[
Display
(Name = "Loc_Two_Name")]
1791
[
Display
(Name = nameof(TestResources.Type_Three_Name), ResourceType = typeof(TestResources))]
1801
[
Display
(Name = "tres")]
1804
[
Display
(Name = "dos")]
1808
[
Display
(ShortName = "uno")]
1811
[
Display
(Name = "", GroupName = "Zero")]
1814
[
Display
(Name = "menos uno", GroupName = "Negatives")]
1820
[
Display
(Name = nameof(TestResources.DisplayAttribute_Name), ResourceType = typeof(TestResources))]
1827
[
Display
(Order = 3)]
1830
[
Display
(Order = 2)]
1833
[
Display
(Order = 1)]
ModelMetadataProviderTest.cs (15)
188
new
DisplayAttribute
{ Description = "value" }, metadata => metadata.Description
191
new
DisplayAttribute
{ Name = "value" }, metadata => metadata.DisplayName
194
new
DisplayAttribute
{ Prompt = "value" }, metadata => metadata.Placeholder
364
new
DisplayAttribute
(), ModelMetadata.DefaultOrder
367
new
DisplayAttribute
{ Order = int.MinValue }, int.MinValue
370
new
DisplayAttribute
{ Order = -100 }, -100
373
new
DisplayAttribute
{ Order = -1 }, -1
376
new
DisplayAttribute
{ Order = 0 }, 0
379
new
DisplayAttribute
{ Order = 1 }, 1
382
new
DisplayAttribute
{ Order = 200 }, 200
385
new
DisplayAttribute
{ Order = int.MaxValue }, int.MaxValue
412
var display = new
DisplayAttribute
() { Description = "description" };
428
var display = new
DisplayAttribute
() { Prompt = "prompt" };
444
var display = new
DisplayAttribute
()
470
var display = new
DisplayAttribute
()
NumericClientModelValidatorTest.cs (1)
156
[
Display
(Name = "DisplayId")]
ValidatableObjectAdapterTest.cs (1)
212
[
Display
(Name = "sample model")]
Microsoft.AspNetCore.Mvc.IntegrationTests (6)
ActionParametersIntegrationTest.cs (1)
953
[
Display
(Name = "My Display Name"), StringLength(3)] string displayNameStringLengthParam,
Models\Product.cs (1)
15
[
Display
(Name = "Contact Us")]
ValidationIntegrationTests.cs (2)
1326
[
Display
(Name = "Not ever valid")]
1330
[
Display
(Name = "Never valid")]
ValidationWithRecordIntegrationTests.cs (2)
1175
[
Display
(Name = "Not ever valid")] NeverValid NeverValidBecauseType,
1178
[
Display
(Name = "Never valid")]
Microsoft.AspNetCore.Mvc.ViewFeatures.Test (27)
DefaultDisplayTemplatesTest.cs (4)
391
[
Display
(Order = 10001)]
398
[
Display
(Order = 23)]
400
[
Display
(Order = 23)]
402
[
Display
(Order = 23)]
DefaultEditorTemplatesTest.cs (4)
1339
[
Display
(Order = 10001)]
1346
[
Display
(Order = 23)]
1348
[
Display
(Order = 23)]
1350
[
Display
(Order = 23)]
Rendering\DefaultTemplatesUtilities.cs (1)
34
[
Display
(Name = "Prop2")]
Rendering\HtmlHelperDisplayExtensionsTest.cs (2)
516
[
Display
(Name = "CreatedKey")]
518
[
Display
(Name = "FaultedKey", ResourceType = typeof(StatusResource))]
Rendering\HtmlHelperDisplayTextTest.cs (1)
369
[
Display
(Name = "Value One")]
Rendering\HtmlHelperPasswordTest.cs (1)
537
[
Display
(Prompt = "placeholder")]
Rendering\HtmlHelperSelectTest.cs (6)
1652
[
Display
(Name = "tres")]
1655
[
Display
(Name = "dos")]
1659
[
Display
(ShortName = "uno")]
1662
[
Display
(Name = "cero")]
1665
[
Display
(Name = "menos uno")]
1671
[
Display
(Name = nameof(TestResources.DisplayAttribute_Name), ResourceType = typeof(TestResources))]
Rendering\HtmlHelperTextAreaTest.cs (1)
162
[
Display
(Prompt = "placeholder")]
Rendering\HtmlHelperTextBoxTest.cs (1)
180
[
Display
(Prompt = "placeholder")]
Rendering\HtmlHelperValidationSummaryTest.cs (6)
725
[
Display
(Order = 10001)]
732
[
Display
(Order = 23)]
734
[
Display
(Order = 23)]
736
[
Display
(Order = 23)]
753
[
Display
(Order = 1)]
756
[
Display
(Order = 2)]
RazorPagesWebSite (3)
Pages\CustomModelTypeModel.cshtml.cs (3)
26
[
Display
(Name = "Email")]
32
[
Display
(Name = "Password")]
36
[
Display
(Name = "Confirm password")]
RazorWebSite (2)
Models\EnumModel.cs (2)
10
[
Display
(Name = "FirstOptionDisplay")]
17
[
Display
(Name = "ModelEnum")]
TagHelpersWebSite (1)
Models\Employee.cs (1)
12
[
Display
(Name = "Full Name", ShortName = "FN")]
36 references to DisplayAttribute
Microsoft.AspNetCore.Mvc.Abstractions (1)
ModelBinding\ModelMetadata.cs (1)
384
/// By default, this is configured using <see cref="System.ComponentModel.DataAnnotations.
DisplayAttribute
.Prompt" />.
Microsoft.AspNetCore.Mvc.DataAnnotations (7)
DataAnnotationsMetadataProvider.cs (7)
60
var
displayAttribute = attributes.OfType<
DisplayAttribute
>().FirstOrDefault();
186
.OrderBy(field => field.GetCustomAttribute<
DisplayAttribute
>(inherit: false)?.GetOrder() ?? 1000);
393
var
display = field.GetCustomAttribute<
DisplayAttribute
>(inherit: false);
412
var
display = field.GetCustomAttribute<
DisplayAttribute
>(inherit: false);
Microsoft.AspNetCore.Mvc.DataAnnotations.Test (18)
DataAnnotationsMetadataProviderTest.cs (11)
192
var
display = new DisplayAttribute()
215
var
display = new DisplayAttribute()
238
var
display = new DisplayAttribute()
348
var
display = new DisplayAttribute()
372
var
display = new DisplayAttribute()
407
var
display = new DisplayAttribute()
442
var
display = new DisplayAttribute()
471
var
display = new DisplayAttribute()
506
var
display = new DisplayAttribute()
535
var
display = new DisplayAttribute()
584
var
display = new DisplayAttribute()
ModelMetadataProviderTest.cs (7)
357
public static TheoryData<
DisplayAttribute
, int> DisplayAttribute_OverridesOrderData
361
return new TheoryData<
DisplayAttribute
, int>
393
public void DisplayAttribute_OverridesOrder(
DisplayAttribute
attribute, int expectedOrder)
412
var
display = new DisplayAttribute() { Description = "description" };
428
var
display = new DisplayAttribute() { Prompt = "prompt" };
444
var
display = new DisplayAttribute()
470
var
display = new DisplayAttribute()
System.ComponentModel.Annotations (9)
System\ComponentModel\DataAnnotations\CompareAttribute.cs (1)
67
if (attribute is
DisplayAttribute
display)
System\ComponentModel\DataAnnotations\ValidationAttributeStore.cs (6)
44
/// Retrieves the <see cref="
DisplayAttribute
" /> associated with the given type. It may be null.
49
internal
DisplayAttribute
? GetTypeDisplayAttribute(ValidationContext validationContext)
71
/// Retrieves the <see cref="
DisplayAttribute
" /> associated with the given property
76
internal
DisplayAttribute
? GetPropertyDisplayAttribute(ValidationContext validationContext)
153
DisplayAttribute = attributes.OfType<
DisplayAttribute
>().SingleOrDefault();
158
internal
DisplayAttribute
? DisplayAttribute { get; }
System\ComponentModel\DataAnnotations\ValidationContext.cs (2)
126
/// If this name was not explicitly set, this property will consult an associated <see cref="
DisplayAttribute
" />
207
DisplayAttribute
? displayAttribute = null;
System.ComponentModel.DataAnnotations (1)
System.ComponentModel.DataAnnotations.cs (1)
12
[assembly: System.Runtime.CompilerServices.TypeForwardedTo(typeof(System.ComponentModel.DataAnnotations.
DisplayAttribute
))]