clang  16.0.0git
Public Member Functions | Static Public Member Functions | Friends | List of all members
clang::SarifRule Class Reference

A SARIF rule (reportingDescriptor object) contains information that describes a reporting item generated by a tool. More...

#include "clang/Basic/Sarif.h"

Public Member Functions

SarifRule setName (llvm::StringRef RuleName)
SarifRule setRuleId (llvm::StringRef RuleId)
SarifRule setDescription (llvm::StringRef RuleDesc)
SarifRule setHelpURI (llvm::StringRef RuleHelpURI)
SarifRule setDefaultConfiguration (const SarifReportingConfiguration &Configuration)

Static Public Member Functions

static SarifRule create ()


class clang::SarifDocumentWriter

Detailed Description

A SARIF rule (reportingDescriptor object) contains information that describes a reporting item generated by a tool.

A reporting item is either a result of analysis or notification of a condition encountered by the tool. Rules are arbitrary but are identifiable by a hierarchical rule-id.

This builder provides an interface to create SARIF reportingDescriptor objects via the SarifRule::create static method.


  1. reportingDescriptor object

Definition at line 257 of file Sarif.h.

Member Function Documentation

◆ create()

static SarifRule clang::SarifRule::create ( )

Definition at line 269 of file Sarif.h.

Referenced by clang::SARIFDiagnostic::emitDiagnosticMessage().

◆ setDefaultConfiguration()

SarifRule clang::SarifRule::setDefaultConfiguration ( const SarifReportingConfiguration Configuration)

Definition at line 292 of file Sarif.h.

◆ setDescription()

SarifRule clang::SarifRule::setDescription ( llvm::StringRef  RuleDesc)

Definition at line 281 of file Sarif.h.

◆ setHelpURI()

SarifRule clang::SarifRule::setHelpURI ( llvm::StringRef  RuleHelpURI)

Definition at line 286 of file Sarif.h.

◆ setName()

SarifRule clang::SarifRule::setName ( llvm::StringRef  RuleName)

Definition at line 271 of file Sarif.h.

◆ setRuleId()

SarifRule clang::SarifRule::setRuleId ( llvm::StringRef  RuleId)

Definition at line 276 of file Sarif.h.

References Id.

Referenced by clang::SARIFDiagnostic::emitDiagnosticMessage().

Friends And Related Function Documentation

◆ clang::SarifDocumentWriter

friend class clang::SarifDocumentWriter

Definition at line 258 of file Sarif.h.

The documentation for this class was generated from the following file: