Here you can find the source of timeString(long timestamp)
public static String timeString(long timestamp)
//package com.java2s; //License from project: Open Source License import java.text.SimpleDateFormat; import java.util.Date; import java.util.Locale; public class Main { public static String timeString(long timestamp) { return new SimpleDateFormat("yyyy-MM-dd HH:mm:ss.SSS", Locale.getDefault()).format(new Date(timestamp)); }//from w ww .j av a2 s. c o m }