Here you can find the source of currtimeToString8()
public static String currtimeToString8()
//package com.java2s; //License from project: LGPL import java.text.SimpleDateFormat; import java.util.Date; public class Main { public static String currtimeToString8() { return dateToString(new Date(), "yyyyMMdd"); }//from www . j a va2 s. c om public static String dateToString(Date date, String format) { SimpleDateFormat sf = new SimpleDateFormat(format); return sf.format(date); } }