简体   繁体   中英

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'

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM