McCabe = 21
d
o
#isG
:
NOM =
lect
0
102 se
,00
...
ses
3
clas
75
=
C
LO
{ {
{
{
}
}
}
} }
{
McCabe = 21
d
o
#isG
:
NOM =
lect
0
102 se
,00
...
ses
3
clas
75
=
C
LO
{ {
{
{
}
}
}
} }
{
Metric Value
LOC 148‘760
NOM 14‘915
NOC 2’089
CYCLO 30‘073
CALLS 151287
FANOUT 85909
AHH 0.12
... ...
McCabe = 21
d
o
#isG
:
NOM =
lect
0
102 se
,00
...
ses
3
clas
75
=
C
LO
{ {
{
{
}
}
}
} }
{
A God Class centralizes too much intelligence
Class uses directly more than a
few attributes of other classes
ATFD > FEW
Functional complexity of the
class is very high
AND GodClass
WMC ! VERY HIGH
Class cohesion is low
TCC < ONE THIRD
6
scu 200
Marine
Lanza,
Significant duplication goes beyond just one line
Duplication chain has at least a
size of two relevant exact clones
SDC ! 2x(FEW+1)+1
Exact clones are longer than a
few lines of code Significant Duplication
AND
Chain
SEC > FEW
Distance between clones is not
more than a few lines of code
LB \" FEW
Significant standalone
exact clone
SEC > AVERAGE(LOC/Operation) Significant
OR
Duplication
6
scu 200
Significant Duplication Chain
Marine
Lanza,
McCabe = 21
d
o
#isG
:
NOM =
lect
0
102 se
,00
...
ses
3
clas
75
=
C
LO
{ {
{
{
}
}
}
} }
{
McCabe = 21
d
o
#isG
:
NOM =
lect
0
102 se
,00
...
ses
3
clas
75
=
C
LO
{ {
{
{
}
}
}
} }
{
How do programs look like today?
A picture tells
a thousand words
proximity
enclosure
connectivity
similarity
closure
continuity
A picture tells
a thousand words
es tell a
ot all ords
pictur
N
usand w
tho
System Complexity shows class hierarchies
03
asse 20
uc
anza, D
L
Distribution Map
shows properties
over structure
Ducass
e etal 200
6
Feature Map relates features to packages
7
etal 200
Greevy
CodeCity shows where your code lives
7
nza 200
La
Wettel,
and where your flaws live
8
0
ettel 20
W
Duplications shown side by side
fo
rw
g
rin
ar
ee
d
en
in
ng
gi
ne
ee
er
rs
in
ve
g
re
{ { { {
{
{
} { {
actual development
}
} }
}
} } } }
{
{
{
}
}
}
{
{
{
}
}
re
ve
rs
ee
ng
in
ee
rin
g
reverse engineering
fo
actual development
rw
ar
d
en
gi
ne
er
in
g
{
{
}
}
{
{
}
}
0 comments
Post a comment