Inspectopedia
 
2024.3

'public' field

Info
New
Last modified: 03 December 2024

Reports public fields. Constants (fields marked with static and final) are not reported.

Example:

After the quick-fix is applied:

Configure the inspection:

  • Use the Ignore If Annotated By list to specify annotations to ignore. The inspection will ignore fields with any of these annotations.

  • Use the Ignore 'public final' fields of an enum option to ignore public final fields of the enum type.