| @@ 103-107 (lines=5) @@ | ||
| 100 | $sum->nbInterfaces = $nbInterfaces; |
|
| 101 | ||
| 102 | foreach ($avg as &$a) { |
|
| 103 | if (sizeof($a) > 0) { |
|
| 104 | $a = round(array_sum($a) / sizeof($a), 2); |
|
| 105 | } else { |
|
| 106 | $a = 0; |
|
| 107 | } |
|
| 108 | } |
|
| 109 | ||
| 110 | // sums of violations |
|
| @@ 12-16 (lines=5) @@ | ||
| 9 | array_push($lcom, $c['lcom']); |
|
| 10 | } |
|
| 11 | } |
|
| 12 | if (sizeof($lcom) > 0) { |
|
| 13 | $lcom = round(array_sum($lcom) / sizeof($lcom), 2); |
|
| 14 | } else { |
|
| 15 | $lcom = 0; |
|
| 16 | } |
|
| 17 | ?> |
|
| 18 | ||
| 19 | ||