<PackageReference Include="System.ComponentModel.Annotations" Version="5.0.0-preview.5.20278.1" />

System.ComponentModel.DataAnnotations.RangeAttribute

Specifies the numeric range constraints for the value of a data field.
namespace System.ComponentModel.DataAnnotations { public class RangeAttribute : ValidationAttribute { public object Minimum { get; } public object Maximum { get; } public Type OperandType { get; } public bool ParseLimitsInInvariantCulture { get; set; } public bool ConvertValueInInvariantCulture { get; set; } public RangeAttribute(int minimum, int maximum); public RangeAttribute(double minimum, double maximum); public RangeAttribute(Type type, string minimum, string maximum); } }