General

GUI Reference: Metric Report

Displays the results of a metric search.

For general information about metric reports, see GUI Reference: General Information About Metric Reports.

Metric report availability is independent of the language or languages involved, but the report contents will depend on the metric values available. In particular:

For the results of searches in other domains, see Search Results.



Important Note: the CodeSonar Web GUI makes extensive use of JavaScript. Make sure JavaScript is enabled in your web browser.

Navigating to

The Metric Report page can be reached in any of the following ways.

From Analysis: Expand the Metrics section, then select one of the report links.
From Advanced Search: Execute an advanced search in the Metrics tab.
From the Simple Search Tool: Execute a search with a domain/scope setting that specifies the metrics domain.
From Metric Report Creation: Use the Open Saved Report or Create New Report functionality.

Page Properties

Output formats CSV, JSON, XML (metrics.xsd)
Visibility Filter Applied Visible Metrics
RBAC Permissions Needed
Page AccessANALYSIS_READ
PROJECT_READ
Page Contents/FunctionalityNAMEDSEARCH_WRITE
For more information, see Searching: Permissions.

Contents and Usage

The following annotated screenshot shows the various parts of a Metric Report page.

Annotated Screenshot: Project Page standard header breadcrumbs page heading Save Report controls Save Report controls Edit Report controls Edit Report controls analysis-granularity metric values report contents standard footer

Standard Header It is worth noting that the simple search tool is initially populated with the component search specification for the report.

Screenshot fragment: populated search widget

  • The search domain is always "metrics".
  • It is not unusual for the text field to be empty, meaning that no constraints are imposed on code components beyond those provided by the search scope (as specified by the domain/scope setting).

For information on other header elements, see GUI Reference: Standard Header.

Breadcrumbs Home > [Other_ProjectTree_Ancestors >] Proj_Name > Analysis_Name > Metric Report
Home > Metric Report
Depending on whether or not the search was carried out in the context of a focal analysis, where
  • Home links to the GUI Home page
  • Together with the Home link (corresponding to the root project tree), Other_ProjectTree_Ancestors represents the project tree ancestors of the analyzed project as a >-separated sequence of project tree names. Each name links to the corresponding Project Tree page.
  • Project_Name is the name of the analyzed project, and links to the corresponding Project page.
  • Analysis_Name is the name of the analysis to which the search was restricted (if any), and links to the corresponding Analysis page.
Page Heading Proj_Name : Analysis_Name : Metric Report
Metric Report
Depending on whether or not the search was carried out in the context of a focal analysis.
Save Report controls See Save a Report for full details.
Edit Report controls See Edit a Report for full details.
Analysis-Granularity Metric Table If the metric search was carried out in the context of a focal analysis, the Metric Report always includes a table of all the analysis-granularity metric values computed for that analysis (both built-in and user-defined). Click show to expand the table; hide to hide the table contents.

Screenshot fragment: table of analysis metrics

Report Contents One table for each metric class (name-granularity pair) specified for the report.

annotated Screenshot fragment: metric report table

Each table has the following properties. If there is only one table in the report, it is always displayed in "view entire table " mode.
Standard Footer See GUI Reference: Standard Footer.

Save a Report

If you save a report, it will be available (subject to NAMEDSEARCH_EXISTS permissions) in the Visible Metrics selector and through the Open Saved Report functionality on the Metric Report Creation page.

See Searching: Saved Searches: Permissions for details of the permissions required to save a named search.

  1. The Save Report section looks (something) like the example below. If necessary, click to expand it.

    Annotated Screenshot Fragment: Save Report section, with expansions

  2. To save the search, enter a name in the text box and click Save.

Edit a Report

The Edit Report section provides functionality for changing the metrics included and table limit for the report. Note in particular that the Edit Report section has no effect on the sets of procedures, files, and compilation units for which values are displayed: these sets depend on the component search.

The Edit Report section looks (something) like the example below. If necessary, click to expand it.

Annotated Screenshot Fragment: Save Report section, with expansions

Navigating from

view the source listing (or part thereof) associated with a metric value Click the relevant table line.
view a metric report creation page Click create new report in the Edit Report section.