Android examples for java.util:Date Time
get Time String in year.month.day.hour.minute.second format
import android.text.format.Time; public class Main { /**/* w ww . j a va2 s. c om*/ * @return type:"year.month.day.hour.minute.second" Use String.split("."); to * get each of time item. */ public static String getTimeString() { Time time = new Time(); time.setToNow(); return time.year + "." + time.month + "." + time.monthDay + "." + time.hour + "." + time.minute + "." + time.second; } }