Java Long Number to Timestamp prettyPrintDate(long timestamp)

Here you can find the source of prettyPrintDate(long timestamp)

Description

pretty Print Date

License

Open Source License

Declaration

public static String prettyPrintDate(long timestamp) 

Method Source Code


//package com.java2s;
//License from project: Open Source License 

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

public class Main {
    private final static SimpleDateFormat sdf = new SimpleDateFormat("dd-MM-yyyy HH:mm:ss");

    public static String prettyPrintDate(long timestamp) {
        return sdf.format(new Date(timestamp));
    }/*from ww  w .  j  a v  a2s .  c  o m*/
}

Related

  1. getCompactStringTimestamp(long timestamp)
  2. getIndex(String index, long timestamp)
  3. longToDate(long timestamp)
  4. longToDateTime(long timestamp)
  5. longToDateTime(long timestamp)
  6. printTimestamp(Long c)
  7. reverseTimestampToNormalTime(long timestamp)
  8. timestamp(long time)
  9. timestamp2DataTime(long timestamp)