Android Long to Date Convert getShortDateString(long date, Locale locale)

Here you can find the source of getShortDateString(long date, Locale locale)

Description

get Short Date String

Declaration

public static String getShortDateString(long date, Locale locale) 

Method Source Code

//package com.java2s;
import java.text.DateFormat;

import java.util.Locale;

public class Main {
    public static String getShortDateString(long date, Locale locale) {
        return getDateString(date, DateFormat.SHORT, locale);
    }/*from   w w w  .  j  av a2  s  .com*/

    public static String getDateString(long date, int style, Locale locale) {
        DateFormat formatter = DateFormat.getDateInstance(style, locale);
        return formatter.format(date);
    }
}

Related

  1. getNumberOfDaysPassed(long date1, long date2)
  2. getReadableTimeStamp(long timeStamp)
  3. getReadableTimeUsage(long timeUsageMs)
  4. getRelativeDateLabel(long time)
  5. getRelativeTimeFromMilliSeconds(long dateInMillis)
  6. getShortDateTimeString(long date, Locale locale)
  7. getSimpleDatetime(long milliseconds)
  8. getStandardTime(long timestamp)
  9. getStartTimeOfDay(long timeInLong)