The Quality Report presents a quality model for files, functions and for C++ classes. The model is based on Principal Component Analysis of metrics (including message counts and message densities for files and functions). The metrics used in the analysis can be selected. This includes selection of user defined metrics created by secondary analysis, giving the option of creating a weighted metric formula.
A summary of code size, number of items analysed and number of metrics used is displayed on the title page.
The main body of the report is divided in to sections, described below. If no metrics have been selected for a section it will be omitted.
A horizonatal bar chart of functions is shown, with the highest quality functions first. The function name is shown, with the file it is defined in afterwards in square brackets. A Pie chart is shown with five segments, representing five quality levels. The number of functions in each level is shown.
This section shows the files in descending order of quality.
This section shows the classes in descending order of quality.
file_metrics - Specify what file metrics to use in the PCA. The report provides an additional two built in metrics: QRFLTOT: Total number of messages in file and QRFLDEN: Message density in file.
function_metrics - Specify what function metrics to use in the PCA. The report provides an additional two built in metrics: QRFUTOT: Total number of messages in function and QRFUDEN: Message density in function.
class_metrics - Specify what class metrics to use in the PCA. Note that some class metrics are generated during Cross Module Analysis: therefore this should be run to ensure the full complement of class metrics.
By default all metrics are used in the PCA. If analysis of a particular type of metrics is not required, supply an empty set of metrics, for example:
-po Quality\ Report::file_metrics=[]
This will omit the file metrics section. The option:
-po Quality\ Report::function_metrics=['STCYC','STPTH','QRFUTOT','QRFUDEN']
will use the cyclomatic complexity, static path count, number of messages and message density for each function in calculation.
bar_style - Specifies whether to plot the chart with bars or diamonds (the default) .
For example:
-po Quality\ Report::bar_style=bar
Specify with -po Quality\ Report::<setting>
to turn on.
-po Quality\ Report::full_name
- Print out the full file names, including the paths. For classes, use the fully qualified name.