综合(智能)数据库
我正在寻找一个完整的 Java 日期管理库,它可以让我理解如下字符串:
- 明天中午 => 2011-10-20 12:00
- 今天下午4点=> 2011-10-20 16:00
等等...
但是如果这个库也能国际化那就太完美了。我计划在多种语言中使用它,“仅”英语是不够的。
我已经发现 http://www.datejs.com/ 是一种可能性,但它适用于 Javascript(客户端)的一边。我正在寻找服务器端的东西。
感谢您的帮助!
I'm looking for a complete Date management library in java that would allow me to understand strings like :
- Tomorrow at noon => 2011-10-20 12:00
- Today at 4pm => 2011-10-20 16:00
etc...
But it would be perfect if this lib would also be Internationalized. I plan to use it in many languages, and "just" english wouldn't be enough.
I already found http://www.datejs.com/ as a possibility, but it's for Javascript (client)'s side. I'm looking for something in Server side.
Thanks for your help!
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(3)
PrettyTime 就是您所需要的
PrettyTime is what you need
您可以使用例如 Joda Time 轻松地自己构建它。
You could easily build that yourself with e.g. Joda Time.
类似的问题是 PHP's strtotime() in Java ,这里有一个很好的答案。 @dfa 做了一个完全符合我正在寻找的对象,您可以在此处找到链接< /a>
An similar question was at PHP's strtotime() in Java and here's a good answer. @dfa did an object that do exactly what I'm looking for, you can find the link here