[Skip to content]

2.8.17. Annotations

Lets you configure annotations that should be added to top-level class, interface, enum and annotation type declarations.

Figure 2.93. Annotations settings page

Annotations settings page

Insert annotations

Enables or disables the automatic insertion of annotations. When enabled, all custom defined annotations (see below) that are not already present for a top-level declaration, will be inserted during formatting.

Since 1.8

2.8.17.1. Annotation patterns

Lets you define the annotation patterns that should be inserted. You can specify an arbitrary amount of patterns. The patterns will be inserted during formatting in the given order. The list component displays all patterns currently defined. Use the button bar on the right to add, remove or change patterns and define the order in which the patterns should be inserted.

Add...

Lets you add new annotation patterns. Pressing the button will invoke a new dialog where you can enter the pattern. Please note that the annotation must be fully qualified. During insertion, the package name will be stripped and the corresponding import declaration inserted.

Edit...

Lets you alter an already defined annotation pattern. This button is only available if an item is currently selected in the pattern list. Pressing the button will invoke a new dialog where you can change the Annotation pattern for the currently selected item in the pattern list.

Remove

Lets you remove an already defined annotation pattern. This button is only available if an item is currently selected in the pattern list.

Up

Lets you change the position of an already defined annotation pattern in the pattern list. This button is only available if an item is currently selected in the pattern list and this is not the topmost item.

Down

Lets you change the position of an already defined annotation pattern in the pattern list. This button is only available if an item is currently selected in the pattern list and this is not the last item.