Show TOC Start of Content Area

Function documentation JLin  Locate the document in its SAP Library structure

Use

You use JLin to perform predefined static tests on Java sources. The tests are delivered as part of the SAP NetWeaver Developer Studio. Uses include:

      Identifying error sources

      Enforcing code conventions

      Evaluating metrics and statistics

      Enforcing architectural patterns

      Monitoring

Features

You configure your tests under Windows Preferences Java JLin.

This graphic is explained in the accompanying text

Variants

All the predefined tests are included in the DEFAULT variant. You create your own editable variants by copying the DEFAULT variant. You can export variants as XML files. This is useful where a team has a standard variant that everyone in the team should use. When importing a variant, there is automatic validation of the XML – invalid files will not be imported. If a variant includes tests that do not exist in the importing Developer Studio, the variant can still be imported (you will get a warning) but the missing tests will be ignored.

Predefined Variants

If predefined variants are maintained in a central location, you can update selected local variants. Choose Update Predefined… followed by Check for Updates.

This graphic is explained in the accompanying text

You can then select the variants that you want to install or update.

Test Results

For most tests, the results of a JLin test run are displayed in the standard Problems view. You can also select to export the results to a file, which you can later import and display again in the Problems view.

Suppressing Messages

Developers can suppress JLin messages for their own code by inserting pseudo-comments in their code – see the individual test descriptions for the relevant pseudo-comments (for example, the Catch Block Test uses the pseudo-comment //$JL-EXC$). By selecting Display suppressed messages only, only these JLin messages will be visible in the Problems view.

Code Classification

Rather than writing pseudo-comments all over your code, you can define rules that suppress tests for certain files. Display the project properties and choose JLin to see the Code Classification. This graphic is explained in the accompanying text

When you create a rule, you can select the tests to be suppressed from list.

Priority

JLin messages have a priority level from 1 down to 3. If you select Priority threshold and enter a value for it, only messages of that priority or higher will be visible in the Problems view.

Test Descriptions

Each test has documentation that you can display by selecting the test (in any variant) and choosing Display description from the context menu.

 

 

End of Content Area