Here you can find the source of getCurrentDate()
public static String getCurrentDate()
//package com.java2s; //License from project: Apache License import java.text.SimpleDateFormat; public class Main { public static String getCurrentDate() { String currentDate = ""; SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd"); currentDate = sdf.format(new java.util.Date()); return currentDate; }/*from ww w . j a va 2 s .c o m*/ }