1 type derived from RegularExpressionAttribute
Microsoft.AspNetCore.Mvc.DataAnnotations.Test (1)
ValidationAttributeAdapterProviderTest.cs (1)
91class CustomRegularExpressionAttribute : RegularExpressionAttribute
13 instantiations of RegularExpressionAttribute
BasicWebSite (1)
Models\Contact.cs (1)
24[RegularExpression(@"\d{5}")]
FormatterWebSite (2)
Models\User.cs (1)
25[RegularExpression("[0-9a-zA-Z]*")]
Models\ValidationProviderAttributeModel.cs (1)
26new RegularExpressionAttribute(pattern: "[A-Za-z]*"),
HtmlGenerationWebSite (1)
Models\ValidationProviderAttributeModel.cs (1)
26new RegularExpressionAttribute(pattern: "[A-Za-z]*"),
Microsoft.AspNetCore.Mvc.Core.Test (2)
ModelBinding\Validation\DefaultModelValidatorProviderTest.cs (1)
231[RegularExpression(".*")]
ModelBinding\Validation\DefaultObjectValidatorTests.cs (1)
1525[RegularExpression("hehehe")]
Microsoft.AspNetCore.Mvc.Core.TestCommon (1)
ValidationAttributeUtil.cs (1)
29var attr = new RegularExpressionAttribute(pattern);
Microsoft.AspNetCore.Mvc.DataAnnotations.Test (3)
DataAnnotationsModelValidatorTest.cs (1)
452new RegularExpressionAttribute(regex) { ErrorMessage = LocalizationKey },
DefaultModelClientValidatorProviderTest.cs (1)
259[RegularExpression(".*")]
ValidationAttributeAdapterProviderTest.cs (1)
20new RegularExpressionAttribute("abc"),
Microsoft.AspNetCore.Mvc.IntegrationTests (3)
Models\Product.cs (1)
14[RegularExpression("^[0-9]*$")]
Models\ProductViewModel.cs (1)
19[RegularExpression("^[a-zA-Z]*$")]
Models\SoftwareViewModel.cs (1)
11[RegularExpression("^[0-9]*$")]
8 references to RegularExpressionAttribute
Microsoft.AspNetCore.Mvc.Core.Test (1)
ModelBinding\Validation\DefaultModelValidatorProviderTest.cs (1)
138Assert.Single(validatorItems, v => ((DataAnnotationsModelValidator)v.Validator).Attribute is RegularExpressionAttribute);
Microsoft.AspNetCore.Mvc.Core.TestCommon (1)
ValidationAttributeUtil.cs (1)
29var attr = new RegularExpressionAttribute(pattern);
Microsoft.AspNetCore.Mvc.DataAnnotations (4)
RegularExpressionAttributeAdapter.cs (2)
10internal sealed class RegularExpressionAttributeAdapter : AttributeAdapterBase<RegularExpressionAttribute> 12public RegularExpressionAttributeAdapter(RegularExpressionAttribute attribute, IStringLocalizer? stringLocalizer)
ValidationAttributeAdapterProvider.cs (2)
26if (typeof(RegularExpressionAttribute).IsAssignableFrom(type)) 28return new RegularExpressionAttributeAdapter((RegularExpressionAttribute)attribute, stringLocalizer);
Microsoft.AspNetCore.OpenApi (1)
Extensions\JsonNodeSchemaExtensions.cs (1)
112else if (attribute is RegularExpressionAttribute regularExpressionAttribute)
System.ComponentModel.DataAnnotations (1)
System.ComponentModel.DataAnnotations.cs (1)
27[assembly: System.Runtime.CompilerServices.TypeForwardedTo(typeof(System.ComponentModel.DataAnnotations.RegularExpressionAttribute))]