With your cursor on the field name (i.e. bootstrapDataEvent), type Alt + Enter (Windows) or ⌥⏎ (Mac) . From the popup, select the "Suppress for fields annotated by 'package.name.Inject'".
If that option does not show, arrow down to the "Create Setter" option and hit the right arrow. On the side menu select "Edit inspection profile setting". That will open the Inspections Configuration dialog, with the "Unused symbol" inspection selected. Click the "Configure annotations..." button and add your annotation.
IDEA提示注入的属性 is never assigned
最新推荐文章于 2024-07-29 19:50:16 发布