-
Notifications
You must be signed in to change notification settings - Fork 6.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
JSONObject的toJavaObject(Class<T> clazz)方法不支持日期格式的unixtime #2300
Comments
TypeUtil类中的 if(value instanceof Number){
longValue = ((Number) value).longValue();
return new Date(longValue); // 此处需要针对unixtime的format进行特殊处理
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Fastjson版本:1.2.56
@wenshao 你好,1.2.56版本中针对issue #2241 中的问题的改动,在使用JSON.parseObject(String text, Class clazz)方法时是有效的,但是将JSON字符串先转换成JSONObject对象,再调用toJavaObject方法,获取的对象的Date成员变量就是错误的了。
The text was updated successfully, but these errors were encountered: