Timestamp timestamp1 = new Timestamp(System.currentTimeMillis());
System.out.println(timestamp1);
Timestamp timestamp2 = new Timestamp(new Date().getTime());
System.out.println(timestamp2);
Timestamp timestamp3 = new Timestamp(Calendar.getInstance().getTimeInMillis());
System.out.println(timestamp3);

 

Java获取时间戳

 

相关文章:

  • 2022-12-23
  • 2021-11-18
  • 2022-12-23
  • 2022-12-23
  • 2021-12-28
  • 2022-02-04
猜你喜欢
  • 2021-09-01
  • 2022-12-23
  • 2021-09-06
  • 2022-12-23
相关资源
相似解决方案