How to make lombok annotation @NotNull work in IntelliJ?

For some reason lombok @NotNull annotation does not work in my maven project in IntelliJ IDEA.

I have a maven lombok dependency on version 1.16.16.

Here is my import statements.

As you see other lombok dependencies work fine. I discovered that @NotNull annotation has retention policy CLASS and other annotations (@Data, @NoArgsConstructor, etc) have retention policy SOURCE. Any ideas how to fix the issue?


注释是@NonNull,带有'n'

链接地址: http://www.djcxy.com/p/96594.html

上一篇: IntelliJ Idea不承认Lombok的注释

下一篇: 如何使lombok注释@NotNull在IntelliJ中工作?