Here you can find the source of getTodayDbFormat()
public static String getTodayDbFormat()
//package com.java2s; //License from project: Open Source License import java.text.SimpleDateFormat; import java.util.Calendar; import java.util.Date; public class Main { public static SimpleDateFormat dbSdf = new SimpleDateFormat("yyyy-MM-dd"); public static String getTodayDbFormat() { return dbSdf.format(getToday()); }// ww w . j a v a 2 s . c om public static Date getToday() { Calendar cal = Calendar.getInstance(); return cal.getTime(); } }