Android Long to Date Convert getDateTime(long microsecond)

Here you can find the source of getDateTime(long microsecond)

Description

get Date Time

License

Apache License

Declaration

public static String getDateTime(long microsecond) 

Method Source Code

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

import java.text.SimpleDateFormat;

import java.util.Date;

public class Main {

    public static String getDateTime(long microsecond) {
        return getFormatDateTime(new Date(microsecond),
                "yyyy-MM-dd HH:mm:ss");
    }/*from  www .  ja  va 2s .c  om*/

    public static String getFormatDateTime(Date date, String format) {
        SimpleDateFormat sdf = new SimpleDateFormat(format);
        return sdf.format(date);
    }
}

Related

  1. getDateForMillis(final long tick)
  2. getDateLabel(long date)
  3. getDateString(long date, int style, Locale locale)
  4. getDateString(long time)
  5. getDateTime(long microsecond)
  6. getDateTimeForTimeZone(Long time)
  7. getDateTimeLabel(long time)
  8. getDateTimeString(long dateTime)
  9. getDateWeekLabel(long date)