Rock Jing

Results 3 comments of Rock Jing

I have the same issue. So what's the specific items should be changed in miniserv.conf? anyone have comments? ```shell port=10000 root=/usr/share/webmin mimetypes=/usr/share/webmin/mime.types addtype_cgi=internal/cgi realm=Webmin Server logfile=/var/webmin/miniserv.log errorlog=/var/webmin/miniserv.error pidfile=/var/webmin/miniserv.pid logtime=168 ssl=1...

> ### 没找到自定义序列化和反序列化 > _之前V1.X版本支持实现接口com.alibaba.fastjson.parser.deserializer.ObjectDeserializer实现反序列化。_ 自从审计到V2.X版本后没找到这个接口类。请知道的大佬指点一下,谢谢 ![image](https://user-images.githubusercontent.com/38791046/192538622-aa357d53-bf38-493e-8ea6-2e86283fa9f3.png) > > 为什么fastjson2 的@JSONField注解只提供了 com.alibaba.fastjson2.annotation.JSONField#writeUsing 属性 而没有提供反序列化的属性呢?怎么自定义反序列化呢? RocK: 我也觉得,FastJson2 这个改动非常不友好。 本来对某个指定字段做一个deserializeUsing 就OK的事情,为什么还要去注册一下? 相比之前FastJson1 的解决方案更简洁。

实现ObjectWriter和ObjectReader实现定制序列化和反序列化 https://alibaba.github.io/fastjson2/register_custom_reader_writer_cn 可能是由于我水平低了,我实在搞不懂,怎么来通过FastJson2 实现类似 FastJson1 里面,对某个字段做反序列化的方式。