Android Date Format getFormatDateTime(String formatString, Date d)

Here you can find the source of getFormatDateTime(String formatString, Date d)

Description

get Format Date Time

License

Apache License

Declaration

public static String getFormatDateTime(String formatString, Date d) 

Method Source Code

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

import java.text.SimpleDateFormat;
import java.util.Date;
import java.util.Locale;

public class Main {
    public static String getFormatDateTime(String formatString, Date d) {
        SimpleDateFormat sdf = new SimpleDateFormat(formatString,
                Locale.ENGLISH);//w w w  . ja v a2  s .  c  o  m
        return sdf.format(d);

    }
}

Related

  1. formatDate(Date date, String pattern, Locale locale)
  2. format(Date d, String dateFormat)
  3. getShortFriendlyDate(Date dt)
  4. getFormatDateString(String format)
  5. getFormatDateString(String format, java.util.Date date)
  6. formatDateToString(Date timestamp)
  7. getStringByFormat(Date date, String format)
  8. getStringByFormat(Date date, String format)
  9. convertDateToString(Date date)