Java Long Number to Time convertMillisToHHMMSS(long millis)

Here you can find the source of convertMillisToHHMMSS(long millis)

Description

convert Millis To HHMMSS

License

Apache License

Declaration

public static String convertMillisToHHMMSS(long millis) 

Method Source Code


//package com.java2s;
//License from project: Apache License 

import java.text.SimpleDateFormat;

import java.util.Date;
import java.util.TimeZone;

public class Main {
    public static String convertMillisToHHMMSS(long millis) {
        TimeZone tz = TimeZone.getTimeZone("UTC");
        SimpleDateFormat df = new SimpleDateFormat("HH:mm:ss");
        df.setTimeZone(tz);//from w w  w.  j  av  a  2  s.  com
        return df.format(new Date(millis));
    }
}

Related

  1. convertLongDate(long lDate, String format)
  2. convertLongTimeStampToString(long localTimeStamp)
  3. convertLongTimeToText(Long time)
  4. convertLongToTimestampString(String dateFormat, Long millSec)
  5. ConvertLongToTimeString(long lastModified)
  6. convertMillsToDateString(long currentTimeMillis)
  7. convertTime(long difference)
  8. convertTime(long time)
  9. convertTime(Long time)