Skip to content
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

json bean处理字段序列化忽略 #3490

Closed
walkwolf opened this issue Feb 20, 2024 · 1 comment
Closed

json bean处理字段序列化忽略 #3490

walkwolf opened this issue Feb 20, 2024 · 1 comment
Labels

Comments

@walkwolf
Copy link

版本情况

JDK版本: openjdk_8_201
hutool版本: 5.8.8(请确保最新尝试是否还有问题)

问题描述(包括截图)

是否可可以支持在 beanjson 字符串的序列化和反序列化时候的 个性化 字段定义?
目前一旦字段设置了@PropIgnore,则序列化反序列化,该字段都不参与

  1. fastjson支持的定义,支持定义序列化、反序列化的支持
    @JSONField(serialize = false)
    public String name;
@looly
Copy link
Member

looly commented Feb 22, 2024

你可以使用JSONUtil.putSerializer自定义序列化。

@looly looly closed this as completed Feb 22, 2024
@looly looly added the question label Feb 22, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants