コード例 #1
0
 public static string RegularExpression(int yearsInFutureAllowed = 0)
 {
     return(YearRegexRangeGenerator.GetRegex((DateTime.UtcNow.Year + yearsInFutureAllowed).ToString(CultureInfo.InvariantCulture)));
 }
コード例 #2
0
 public static string RegularExpression()
 {
     return(YearRegexRangeGenerator.GetRegex(DateTime.Now.Year.ToString(CultureInfo.InvariantCulture)));
 }