Skip to content

Instantly share code, notes, and snippets.

@akamahesh
Created December 1, 2016 09:43
Show Gist options
  • Save akamahesh/39347a0c2b11287794003d6e5f40b880 to your computer and use it in GitHub Desktop.
Save akamahesh/39347a0c2b11287794003d6e5f40b880 to your computer and use it in GitHub Desktop.
private String convert(long mill) throws ParseException {
String hms = String.format("%02d :%02d", TimeUnit.MILLISECONDS.toHours(mill),
TimeUnit.MILLISECONDS.toMinutes(mill) - TimeUnit.HOURS.toMinutes(TimeUnit.MILLISECONDS.toHours(mill)));
return hms;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment