Here you can find the source of millisecondsToTimerString(long millis)
public static String millisecondsToTimerString(long millis)
//package com.java2s; //License from project: Open Source License import java.text.DateFormat; import java.text.SimpleDateFormat; import java.util.Date; public class Main { public static String millisecondsToTimerString(long millis) { Date date = new Date(millis); DateFormat formatter = new SimpleDateFormat("mm:ss"); return formatter.format(date); }/*w ww.j a v a2 s . co m*/ }