Java - Date as long value:TimeZone如何相关? [英] Java - Date as long value: how does TimeZone relate?

查看:139
本文介绍了Java - Date as long value:TimeZone如何相关?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

有人可以详细解释以下内容:



我有一个值,代表 date


  1. 与<$ c $相关联的时区 c> long value?


  2. 如何将 long 值转换为带有正确时区的日期 c>

    是否有方法可以识别与相关联的时区 长日期价值?



解决方案>

这是从1970年1月,GMT的毫秒。所以,在这方面,它是GMT。


Could someone please explain in detail the following:

I have a long value which represents a date.

  1. What will be the timezone associated with the long value?

  2. How to convert the long value to a date with proper time zone?

  3. Is there is way to identify the timezone associated with the long date value?

解决方案

The long is milliseconds since Jan 1970, GMT. So, to that respect, it is GMT.

这篇关于Java - Date as long value:TimeZone如何相关?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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