Android Date Format getFormatTime(Date date)

Here you can find the source of getFormatTime(Date date)

Description

get Format Time

Declaration

public static String getFormatTime(Date date) 

Method Source Code

//package com.java2s;

import java.text.SimpleDateFormat;

import java.util.Date;

public class Main {
    public static String getFormatTime(Date date) {
        return getFormatDateTime(date, "yyyy-MM-dd HH:mm:ss");
    }//from  w  ww.  j a v  a2 s  .  c om

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

Related

  1. getFormatDateTime(Date date, String format)
  2. getFormatDateTime(Date date, String format)
  3. getFormatDateTommorrow(String sourceDate, String format)
  4. getFormatDateTommorrow(String sourceDate, String format)
  5. getFormatShortTime(Date date)
  6. getFormatTomorrow(String format)
  7. getFormatYestoday(String format)
  8. getUniversalDateStamp(Date date)
  9. getUtcTimeStringFromDate(Date date)