According to me, you should understand at least the following metrics at beginning:
Lack of cohesion of methods (LCOM) is a measure of the number of responsabilities of class.
Thus, if you consider the SOLID principles, the ideal LCOM is LCOM=1
.
We can take an example:
If we examine this class, we get two flows:
f1()
share attribute a
with f3()
, and f2()
calls f3()
f4()
share attribute b
with f5()
Therefore, the LCOM value for Example
is 2
. Indeed, Example
has two responsabilities.
Maintainability index evaluates ... the maintainability of any project. It provides a score between 0 to 118.
This score is standard, and works for any language : PHP
, .Net
, Java
...
Generally, we consider the following scores:
Soon