/**
* @Description 日期字符串转换时间
* @param date 1610616741000
* @Throws
* @Return java.util.Date
* @Date 2021-01-14 20:59:53
* @Author WangKun
**/
public static Date simpleDate(String date) throws ParseException {
Date dat = new Date(Long.parseLong(date));
GregorianCalendar gc = new GregorianCalendar();
gc.setTime(dat);
SimpleDateFormat format = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
return format.parse(format.format(gc.getTime()));
}
System.out.println(simpleDate("1610616741000"));