-
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
对于ExtraProcessor的使用 #555
Milestone
Comments
是否可以提供重现问题的testcase |
public class A{ |
已经解决,将会在这两天内发布1.2.12版本解决此问题 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
比如我有个A类,其中有字段
List<B> listVar
,B类中有个特殊的类字段spec(这字段是来自某一个jar包的,没有提供无参的默认构造函数),我toJsonString时用了ValueFilter把这个特殊类序列化成一个有带有指定符号的String,整体序列化是能成功,但是用ExtraProcessor时: //不知道这样传入对不对JSON.parseObject(testAString, A.class, new ProcessorContainer());
在这个ProcessorContainer里面,我通过判断value值如果含有指定符号,我才自己处理这个spec
p.s 这个spec我失能了反序列化
@JSONField(serialize = true, deserialize = false)
Spec spec;
现在错误是Spec default constructor not found,因为这个Spec没有提供无参的默认构造函数(new Spec()肯定失败 ),我失能了反序列化,fastjson也要去拜访这个特殊的类,然后new Spec()吗?按理来说不应该吧~~~
The text was updated successfully, but these errors were encountered: