mirror of
https://github.com/github/codeql.git
synced 2026-02-24 19:03:50 +01:00
In hindsight, having a `.getMetrics()` method that just returns `this` is somewhat weird. It's possible that it predates the existence of the inline cast, however.
16 lines
396 B
Plaintext
16 lines
396 B
Plaintext
/**
|
|
* @name Lack of Cohesion in a Class (HM)
|
|
* @description Lack of cohesion of a class, as defined by Hitz and Montazeri.
|
|
* @kind treemap
|
|
* @id py/lack-of-cohesion-hitz-montazeri
|
|
* @treemap.warnOn highValues
|
|
* @metricType reftype
|
|
* @metricAggregate avg max
|
|
*/
|
|
|
|
import python
|
|
private import LegacyPointsTo
|
|
|
|
from ClassMetrics cls
|
|
select cls, cls.getLackOfCohesionHM() as n order by n desc
|