Files
codeql/java/ql/src/Metrics/Callables/CCyclomaticComplexity.ql
2018-10-11 11:31:37 +02:00

19 lines
479 B
Plaintext

/**
* @name Cyclomatic complexity of functions
* @description The number of possible execution paths through a method or constructor.
* @kind treemap
* @treemap.warnOn highValues
* @metricType callable
* @metricAggregate avg max sum
* @id java/cyclomatic-complexity-per-function
* @tags testability
* complexity
* maintainability
*/
import java
from Callable c
where c.fromSource()
select c, c.getMetrics().getCyclomaticComplexity() as n order by n desc