[英]JodaTime: How do I get the human-readable name of a DateTimeZone
The method org.joda.time.getName(long instant)
requires a long
, I don't understand what this "instant" is and the documentation doesn't address the question. 方法
org.joda.time.getName(long instant)
需要很long
,我不明白这个“即时”是什么,文档没有解决这个问题。
I have a DateTimeZone
that I generated from a timezone ID, and all I want now is the readable name. 我有一个从时区ID生成的
DateTimeZone
,现在我想要的只是可读的名称。 Why do I have to pass it a value? 为什么我必须传递一个值?
The instant
is the time in milliseconds from 1970-01-01T00:00:00Z to get the name for. instant
是从1970-01-01T00:00:00Z获取名称的时间(以毫秒为单位)。
http://joda-time.sourceforge.net/apidocs/org/joda/time/DateTimeZone.html#getName%28long%29 http://joda-time.sourceforge.net/apidocs/org/joda/time/DateTimeZone.html#getName%28long%29
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.