Here you can find the source of getCurrentDay()
public static String getCurrentDay()
//package com.java2s; //License from project: Apache License import java.text.SimpleDateFormat; public class Main { public static String getCurrentDay() { return getDefaultDateFormat().format(java.util.Calendar.getInstance().getTime()); }/*from w w w .jav a 2s . c o m*/ public static SimpleDateFormat getDefaultDateFormat() { return new SimpleDateFormat("yyyyMMdd"); } }