Java Year Format getYYYYMMDDHHMMSS(Date date)

Here you can find the source of getYYYYMMDDHHMMSS(Date date)

Description

get YYYYMMDDHHMMSS

License

Open Source License

Declaration

public static String getYYYYMMDDHHMMSS(Date date) 

Method Source Code

//package com.java2s;
//License from project: Open Source License 

import java.text.DateFormat;
import java.text.SimpleDateFormat;

import java.util.Date;

public class Main {
    public static String getYYYYMMDDHHMMSS(Date date) {
        if (date == null) {
            return null;
        }/*w w  w. j  a v a 2 s. c  om*/
        DateFormat dateformat = new SimpleDateFormat("yyyyMMddHHmmss");
        return dateformat.format(date);
    }
}

Related

  1. getyyyyMMddDateStr(Date date)
  2. getYYYYMMDDFormat()
  3. getYYYYMMDDHH(Date date)
  4. getYYYYMMDDHHMISS()
  5. getYYYYMMDDHHMMSS()
  6. getYyyyMMddWithoutDate()
  7. isPartialYear(String s, String yearFormat)
  8. isValidDateMMddyyyy(String theString)
  9. isYear(int y)