//返回的是long类型
long time = System.currentTimeMillis();
SimpleDateFormat format = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss SSS");
String string = format.format(time);
获取系统当前时间
最新推荐文章于 2021-12-01 11:20:03 发布