Standard metrics
A sample for dealing with the standard metrics is provided below.
In this example, "650" (= 650 bytes) is defined as the upper limit for the metric Code size [number of bytes] and "5" as the upper limit for the metric Number of input variables. The Rule SA0150: Violations of lower or upper limits of the metrics is also activated and configured as a warning.
When the command 'View Standard Metrics' is issued, the metric view opens and the indicators that were determined are displayed in tabular form. As the size of the MAIN program is 688 bytes and the SampleProgram program has 7 input variables, these figures exceed the defined upper limits, so the corresponding table fields are highlighted in red.

In this sample, the fact that the defined upper limits are exceeded is not only apparent in the metric view. Since rule SA0150 is configured as warning, the static analysis checks for violations of lower and upper metric limits. After the static analysis has been performed, the violation of the two upper limits is therefore reported as a warning in the message window.
