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

mapstruct确实蛮好用的 | 柚子816 #29

Open
leemotive opened this issue Aug 25, 2024 · 0 comments
Open

mapstruct确实蛮好用的 | 柚子816 #29

leemotive opened this issue Aug 25, 2024 · 0 comments

Comments

@leemotive
Copy link
Owner

https://leemotive.github.io/2024/08/23/mapstruct%E7%A1%AE%E5%AE%9E%E8%9B%AE%E5%A5%BD%E7%94%A8%E7%9A%84/index.html

最近在做一个 java 的项目,需要把 dto啊 vo啊 entity啊这些对象进行转换,这些对象很多属性名称及类型都是一样的,甚至是完全一样的。部分属性的类型或者名字有不一致的地方。刚开始准备简单暴力先将源对象转换成 json 字符串,然后再转换成目标对象。反正这两个逻辑早就已经准备好了。完美,简单 BeanUtils在 apache 和 spring 中都有 BeanUtils 类,使用其 c

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant