facebook / facebook-java-business-sdk
Unit Size

The distribution of size of units (measured in lines of code).

Intro
  • Unit size measurements show the distribution of size of units of code (methods, functions...).
  • Units are classified in four categories based on their size (lines of code): 1-20 (small units), 20-50 (medium size units), 51-100 (long units), 101+ (very long units).
  • You should aim at keeping units small (< 20 lines). Long units may become "bloaters", code that have increased to such gargantuan proportions that they are hard to work with.
Learn more...
Unit Size Overall
  • There are 41,170 units with 207,772 lines of code in units (78.6% of code).
    • 2 very long units (392 lines of code)
    • 424 long units (41,178 lines of code)
    • 82 medium size units (2,370 lines of code)
    • 1,331 small units (20,270 lines of code)
    • 39,331 very small units (143,562 lines of code)
<1% | 19% | 1% | 9% | 69%
Legend:
101+
51-100
21-50
11-20
1-10
Unit Size per Extension
101+
51-100
21-50
11-20
1-10
java<1% | 19% | 1% | 9% | 69%
Unit Size per Logical Component
primary logical decomposition
101+
51-100
21-50
11-20
1-10
sdk<1% | 20% | <1% | 9% | 69%
utils0% | 22% | 25% | 14% | 36%
sdk/serverside0% | 0% | 16% | 15% | 67%
sdk/signal0% | 0% | 9% | 3% | 87%
sdk/serverside/utils0% | 0% | 50% | 24% | 24%
sdk/businessdataapi0% | 0% | 0% | 10% | 89%
Alternative Visuals
Longest Units
Top 50 longest units
Unit# linesMcCabe index# params
257 1 1
135 1 1
98 30 4
98 30 4
98 30 4
98 30 4
98 30 4
98 30 4
98 30 4
98 30 4
98 30 4
98 30 4
98 30 4
98 30 4
98 30 4
98 30 4
98 30 4
98 30 4
98 30 4
98 30 4
98 30 4
98 30 4
98 30 4
98 30 4
98 30 4
98 30 4
98 30 4
98 30 4
98 30 4
98 30 4
98 30 4
98 30 4
98 30 4
98 30 4
98 30 4
98 30 4
98 30 4
98 30 4
98 30 4
98 30 4
98 30 4
98 30 4
98 30 4
98 30 4
98 30 4
98 30 4
98 30 4
98 30 4
98 30 4
98 30 4