Java Long Number to Date getDateByLongTime(long time)

Here you can find the source of getDateByLongTime(long time)

Description

get Date By Long Time

License

Apache License

Declaration

public static String getDateByLongTime(long time) 

Method Source Code

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

import java.text.SimpleDateFormat;
import java.util.*;

public class Main {

    public static String getDateByLongTime(long time) {
        SimpleDateFormat sdf = new SimpleDateFormat("yyyyMMddHHmmss");
        Date dt = new Date(time);
        String timeStr = sdf.format(dt);
        return timeStr;
    }//from  ww  w . j a v  a 2 s . c o  m
}

Related

  1. formatEpoch(long date)
  2. formatHttpDate(long d)
  3. formatHTTPDate(long pTime)
  4. formatHttpDate(long time)
  5. getDatebyLong(long dt)
  6. getDateByMis(long m)
  7. getDateByMisSecond(long misSecond)
  8. minsSecsFromMs(long ms)
  9. secToDate(long secs, String format)