如何在Java中获得GPS时间和TAI时间? [英] How to get GPS Time and TAI time in Java?

查看:342
本文介绍了如何在Java中获得GPS时间和TAI时间?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

有没有办法获得当前的 GPS时间 TAI时间

Is there a way to get the current GPS time and TAI time?

System.currentTimeMillis() 的返回值是POSIX时间,它不是时间的线性表示。)

( System.currentTimeMillis()'s return value is POSIX time, which isn't a linear representation of time. )

推荐答案

您的选择是查看ThreeTen项目,它是
JSR-310(新的Java日期和时间规范)的参考实现。您可以在 javadocs 中找到 TAIInstant 课程。

Your option is to look at the ThreeTen project, which is the reference implementation of the JSR-310 (new Java Date and Time spec). You can find a TAIInstant class in the javadocs

声称它仍处于alpha状态,但

It's claimed to be still in alpha, though

这篇关于如何在Java中获得GPS时间和TAI时间?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆