Java Regex Date Vaidate checkDateYYYYMMMDD(String date)

Here you can find the source of checkDateYYYYMMMDD(String date)

Description

check Date YYYYMMMDD

License

Open Source License

Declaration

public static boolean checkDateYYYYMMMDD(String date) 

Method Source Code


//package com.java2s;

import java.util.regex.Pattern;

public class Main {

    public static boolean checkDateYYYYMMMDD(String date) {
        String regex = "[1|2][0-9]{7}";
        return Pattern.matches(regex, date);
    }//from  ww  w . ja va2 s .c o m
}

Related

  1. checkDate(String date)
  2. checkDate(String strDate, String dateFmt)
  3. dateMatcher(String dt)
  4. dateOfAny(final String value)
  5. datePatternPattern(String appenderPrefix)
  6. dateTimeMatcher(String dt)