NDepend.API Documentation
DebtRating Method (ExtensionMethodsCQLinqIssuesSet)
NDepend.Reserved.CQLinq Namespace > ExtensionMethodsCQLinqIssuesSet Class : DebtRating Method
The code element on which we infer the rating.
Gets the debt rating of codeElement in the range NDepend.TechnicalDebt.DebtRating.A (very good) to NDepend.TechnicalDebt.DebtRating.E (very bad).
Syntax
[Extension()]
public static Nullable<DebtRating> DebtRating( 
   ICodeElement codeElement
)

Parameters

codeElement
The code element on which we infer the rating.
Exceptions
ExceptionDescription
This extension method cannot be called from a program consuming NDepend.API. In such context, the method NDepend.Issue.IIssuesSet.DebtRating must be called instead.
Remarks
The debt to infer the rating is obtained through AllDebt(codeElement).
This method implementation calls NDepend.TechnicalDebt.IDebtFormatter.NDepend.TechnicalDebt.IDebtFormatter.ToDebtRating.
This method returns null if NDepend.TechnicalDebt.IDebtFormatter.NDepend.TechnicalDebt.IDebtFormatter.ToDebtRatio(codeElement) returns null.
Requirements

Target Platforms: Windows 11, 10, 8, 7 and Linux, MacOS with net8.0, net7.0 or net6.0 installed

See Also

Reference

ExtensionMethodsCQLinqIssuesSet Class
ExtensionMethodsCQLinqIssuesSet Members