快去自|

Aoul

园龄:3年3个月粉丝:0关注:3

java时间戳转换

1、时间戳(毫秒)

          System.currentTimeMillis()

2、时间戳(转秒)

         System.currentTimeMillis() / 1000

3、时间戳(转分钟)

        System.currentTimeMillis() / 1000 / 60

4、时间戳(转小时)

        System.currentTimeMillis() / 1000 / (60 * 60)

5、时间戳(转天)

       System.currentTimeMillis() / 1000 / (60 * 60 * 24)

本文作者:一个热爱java的程序猿

本文链接:https://www.cnblogs.com/message-hrp/p/17254667.html

版权声明:本作品采用知识共享署名-非商业性使用-禁止演绎 2.5 中国大陆许可协议进行许可。

posted @   Aoul  阅读(727)  评论(0编辑  收藏  举报
点击右上角即可分享
微信分享提示
评论
收藏
关注
推荐
深色
回顶
收起