Editing annotations using the Annotations view

You can edit annotations in your source code by directly modifying the annotation in the Java™ editor or by using the Annotations view.

Before you begin

In the Java EE perspective, if the Annotations view does not appear in the workspace, you need to add the Annotations view. For more information, see Annotations view.

Procedure

  1. In the Enterprise Explorer view, double-click your Java class to open the file in the Java editor.
  2. Click the Annotations view tab.
  3. In the Java editor, highlight the annotation that you want to edit. In the Annotations view, you see the values that are associated with the annotation:

    Add parameters to annotation

  4. Edit the field by highlighting the value in the text box and typing the value that you want:

    Edit parameter

    In this example, the default value of the Name field was changed from Default (JPACounterEntity) to TestEntity.
  5. When you press CTRL+S to save, the change is reflected in the Java class:

    Edit parameter result

Icon that indicates the type of topic Task topic
Timestamp icon Last updated: July 17, 2017 21:58

File name: teditannoview.html