Here you can find the source of getCurrentDate()
public static String getCurrentDate()
//package com.java2s; import java.text.Format; import java.util.Date; public class Main { /**// ww w. j a v a 2 s . c o m * get current date * * @return yyyyMMddHHmmss * @author j00105185 */ public static String getCurrentDate() { Format formatter = new java.text.SimpleDateFormat("yyyyMMddHHmmss"); return formatter.format(new Date()); } }