我应该使用threeten而不是joda-time [英] Should I use threeten instead of joda-time
问题描述
我遇到了 https:// blog.joda.org/2009/11/why-jsr-310-isn-joda-time_4941.html 。
1)我目前正在迁移Java日历到joda-time。我想知道,我应该使用threeten而不是joda-time吗?是否准备好三个生产?
1) I am currently migrating Java Calendar to joda-time. I was wondering, should I use threeten instead of joda-time? Is threeten production ready?
2)三个库和joda-time库是否可以在同一个应用程序中共存?因为我正在使用一些使用joda-time库的第三方库。
2) Can threeten library and joda-time libraries exist together in a same application? As I am using some 3rd parties libraries, which is using joda-time library too.
3)joda-time是否会成为一个放弃项目,因为有三个?
3) Will joda-time become an abandon project since there is threeten?
推荐答案
官方回复:
截至2011年1月,ThreeTen仍然是什么我将其归类为Alpha。这意味着我是
更改方法名称,类出现和消失等等。也就是说,
那里的代码基本上是合理的并告诉正确的时间。
As of January 2011, ThreeTen is still what I'd classify as an Alpha. That means that I am changing method names, classes appear and disappear etc. That said, the code that is there is basically sound and tells the right time.
因此,我目前建议项目使用Joda-Time直到ThreeTen
进入Beta,这将是今年(2011年)的某个时刻。
As such, I currently advise projects to use Joda-Time until ThreeTen enters Beta, which will be this year (2011) at some point.
可以在同一
应用程序中同时使用Joda-Time和ThreeTen。当ThreeTen稳定时,我打算将ThreeTen的接口
添加到Joda-Time,提供互操作性。但是,
互操作性永远不会轻松,因为类具有相同的
名称。
It is possible to have both Joda-Time and ThreeTen in the same application. When ThreeTen is stable I intend to add the interfaces from ThreeTen to Joda-Time providing interoperability. However, interoperability will never be easy as the classes have the same names.
Joda-Time将继续发布一段时间在ThreeTen
完成之后。但是如果JSR-310
完成,那么将会推动转向ThreeTen,以便它在Java SE 8中。
Joda-Time will continue to be released for a good period after ThreeTen is complete. But there will be a push to move to ThreeTen if JSR-310 completes such that it is in Java SE 8.
更新,2014年3月,
Update, March 2014,
截至2014-03-05,JSR-310 已批准包含在Java JDK 8中。有关详细信息,请参阅 ThreeTen主页。
As of 2014-03-05, JSR-310 was approved for inclusion in Java JDK 8. For more information, see the ThreeTen home page.
这篇关于我应该使用threeten而不是joda-time的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!