Intra-JVM (Internal) Validation

If you are working on a Java application as a project in Eclipse, you can validate it right from within the Java Perspective if it meets the criteria defined here.

To perform validations from the Java Perspective, follow these steps:

  1. Open the Java Perspective.
  2. Be sure that both the Rendered GUI View and the Validation Report View are open and visible, as follows.

  3. Open the source folder of a Java project.
  4. Right-click on any appropriate type or member in the project from the Package Explorer to bring up the context menu. You have two options here:
  5. Try the ACTF->Perform Validation action this time.

  6. You should see a validation report in the Validation Report View and the GUI should be rendered in the Rendered GUI View. Note that if you make any changes to the file at this point, validation will not automatically occur. You can invoke another validation by either performing the same action, or selecting the Validate button () on the toolbar of the Rendered GUI View.
  7. You should see something similar to this:

  8. Validation problems will also appear in the Problems View along with any compilation errors or warnings, and the source code in the Package Explorer will show problem markers.

  9. Double-click a line in the Problems View and the editor will move to the matching line.

    You will see something similar to this:

  10. Now, turn on automatic validation by selecting the Refresh button () on the toolbar of the Rendered GUI View. The Validate button becomes disabled because validation will now be automatic. Now when you fix Accessibility problems in your code and save the change ACTF will validate and clear the problem markers, just as the Java compiler does in Eclipse.
  11. Let's fix one of the problems found by ACTF and see. The first problem in the Problems view says "Keyboard shortcuts should be valid ALT- combinations". We can fix this by adding a mnemonic to the Clear button. Now save the file. ACTF will validate the file again and we now have one less problem in the Problems View.