Lombok 1.16.22 发布,减少样板代码的 Java 语法糖

来源: 投稿
作者: 淡漠悠然
2018-05-30

Lombok 1.16.22 发布了,更新内容如下:

  • FEATURE: Private no-args constructor for @Data and @Value to enable deserialization frameworks (like Jackson) to operate out-of-the-box. Use lombok.noArgsConstructor.extraPrivate = false to disable this behavior.

  • FEATURE: Methods can now be marked for inclusion in toStringequals, and hashCode generation. There is a new mechanism to mark which fields (and now, methods) are to be included or excluded for the generation of these methods: mark the relevant member with for example @ToString.Include or @EqualsAndHashCode.ExcludeToString documentation EqualsAndHashCode documentation

  • FEATURE: @Getter and @Setter also allow onMethod and onParam when put on a type. Issue #1653

  • FEATURE: @FieldNameConstants is a new feature that generates string constants for your field names. Docs on @FieldNameConstants.

  • PLATFORM: Lombok can be compiled on JDK10, and should run on JDK10. Issue #1693

  • PLATFORM: lombok now counts as an incremental annotation processor for gradle. Should speed up your gradle builds considerably! Issue #1580

  • PLATFORM: Fix for using lombok together with JDK9+'s new module-info.java feature. Issue #985

  • BUGFIX: Solved some issues in eclipse that resulted in error 'A save participant caused problems'. Issue #879

  • BUGFIX: Netbeans on jdk9. Issue #1617

  • BUGFIX: Netbeans < 9. Issue #1555

  • PROMOTION: var has been promoted from experimental to the main package with no changes. The 'old' experimental one is still around but is deprecated, and is an alias for the new main package one. var documentation.

  • OLD-CRUFT: lombok.experimental.Builder and lombok.experimental.Value are deprecated remnants of when these features were still in experimental. They are now removed entirely. If your project is dependent on an older version of lombok which still has those; fret not, lombok still processes these annotations. It just no longer includes them in the jar.

详情见更新日志

下载地址:

展开阅读全文
3 收藏
分享
加载中
精彩评论

引用来自“开源中国首席技术官”的评论

听说有的公司禁用这玩意?
因为这个玩意大大的降低了码农的代码提交行数!!!千行BUG率会大大飙升、工作量也会显得不饱和~
2018-05-30 10:30
2
举报
最新评论 (6)

引用来自“YanbinQ”的评论

ide 要支持,ci 要支持
目前ide和ci都支持这个
2018-05-30 11:56
0
回复
举报
ide 要支持,ci 要支持
2018-05-30 10:55
0
回复
举报

引用来自“开源中国首席技术官”的评论

听说有的公司禁用这玩意?
因为这个玩意大大的降低了码农的代码提交行数!!!千行BUG率会大大飙升、工作量也会显得不饱和~
2018-05-30 10:30
2
回复
举报
听说有的公司禁用这玩意?
2018-05-30 09:36
0
回复
举报

引用来自“猫咪喵喵”的评论

等了好久终于正式发布了,支持JDK10的版本
jdk 10 ,我们环境还是jdk8呢...
2018-05-30 09:29
0
回复
举报
等了好久终于正式发布了,支持JDK10的版本
2018-05-30 08:13
0
回复
举报
更多评论
6 评论
3 收藏
分享
返回顶部
顶部