Merge remote-tracking branch 'origin/master'
This commit is contained in:
@ -145,7 +145,7 @@ List of rulesets and rules contained in each ruleset.
|
||||
* [NcssCount](pmd_rules_java_design.html#ncsscount): This rule uses the NCSS (Non-Commenting Source Statements) metric to determine the number of line...
|
||||
* [NcssMethodCount](pmd_rules_java_design.html#ncssmethodcount): <span style="border-radius: 0.25em; color: #fff; padding: 0.2em 0.6em 0.3em; display: inline; background-color: #d9534f; font-size: 75%;">Deprecated</span> This rule uses the NCSS (Non-Commenting Source Statements) algorithm to determine the number of l...
|
||||
* [NcssTypeCount](pmd_rules_java_design.html#ncsstypecount): <span style="border-radius: 0.25em; color: #fff; padding: 0.2em 0.6em 0.3em; display: inline; background-color: #d9534f; font-size: 75%;">Deprecated</span> This rule uses the NCSS (Non-Commenting Source Statements) algorithm to determine the number of l...
|
||||
* [NPathComplexity](pmd_rules_java_design.html#npathcomplexity): The NPath complexity of a method is the number of acyclic execution paths through that method. ...
|
||||
* [NPathComplexity](pmd_rules_java_design.html#npathcomplexity): The NPath complexity of a method is the number of acyclic execution paths through that method.Whi...
|
||||
* [SignatureDeclareThrowsException](pmd_rules_java_design.html#signaturedeclarethrowsexception): A method/constructor shouldn't explicitly throw the generic java.lang.Exception, since itis uncle...
|
||||
* [SimplifiedTernary](pmd_rules_java_design.html#simplifiedternary): Look for ternary operators with the form 'condition ? literalBoolean : foo'or 'condition ? foo : ...
|
||||
* [SimplifyBooleanAssertion](pmd_rules_java_design.html#simplifybooleanassertion): Avoid negation in an assertTrue or assertFalse test.For example, rephrase: assertTrue(!expr);a...
|
||||
|
@ -1198,13 +1198,13 @@ public class Foo extends Bar {
|
||||
**Priority:** Medium (3)
|
||||
|
||||
The NPath complexity of a method is the number of acyclic execution paths through that method.
|
||||
While cyclomatic complexity counts the number of decision points in a method, NPath counts the number of
|
||||
full paths from the beginning to the end of the block of the method. That metric grows exponentially, as
|
||||
it multiplies the complexity of statements in the same block. For more details on the calculation, see the
|
||||
documentation of the [NPath metric](/pmd_java_metrics_index.html#npath-complexity-npath).
|
||||
While cyclomatic complexity counts the number of decision points in a method, NPath counts the number of
|
||||
full paths from the beginning to the end of the block of the method. That metric grows exponentially, as
|
||||
it multiplies the complexity of statements in the same block. For more details on the calculation, see the
|
||||
documentation of the [NPath metric](/pmd_java_metrics_index.html#npath-complexity-npath).
|
||||
|
||||
A threshold of 200 is generally considered the point where measures should be taken to reduce
|
||||
complexity and increase readability.
|
||||
A threshold of 200 is generally considered the point where measures should be taken to reduce
|
||||
complexity and increase readability.
|
||||
|
||||
**This rule is defined by the following Java class:** [net.sourceforge.pmd.lang.java.rule.design.NPathComplexityRule](https://github.com/pmd/pmd/blob/master/pmd-java/src/main/java/net/sourceforge/pmd/lang/java/rule/design/NPathComplexityRule.java)
|
||||
|
||||
|
Reference in New Issue
Block a user