dart-lang / http_parser
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 24 units with 367 lines of code in units (56.7% of code).
    • 0 very long units (0 lines of code)
    • 1 long units (60 lines of code)
    • 3 medium size units (108 lines of code)
    • 8 small units (123 lines of code)
    • 12 very small units (76 lines of code)
0% | 16% | 29% | 33% | 20%
Legend:
101+
51-100
21-50
11-20
1-10
Unit Size per Extension
101+
51-100
21-50
11-20
1-10
dart0% | 16% | 29% | 33% | 20%
Unit Size per Logical Component
primary logical decomposition
101+
51-100
21-50
11-20
1-10
lib/src/chunked_coding0% | 48% | 0% | 26% | 24%
lib/src0% | 0% | 45% | 38% | 16%
example0% | 0% | 0% | 0% | 100%
Alternative Visuals
Longest Units
Top 20 longest units
Unit# linesMcCabe index# params
Uint8List _decode()
in lib/src/chunked_coding/decoder.dart
60 15 3
DateTime parseHttpDate()
in lib/src/http_date.dart
41 4 1
static List parseHeader()
in lib/src/authentication_challenge.dart
37 7 1
MediaType change()
in lib/src/media_type.dart
30 6 5
String formatHttpDate()
in lib/src/http_date.dart
20 5 1
String toString()
in lib/src/media_type.dart
19 2 0
List _convert()
in lib/src/chunked_coding/encoder.dart
19 5 4
List parseList()
in lib/src/scan.dart
15 5 2
int _digitForByte()
in lib/src/chunked_coding/decoder.dart
14 5 2
static void _scanAuthParam()
in lib/src/authentication_challenge.dart
14 2 2
T wrapFormatException()
in lib/src/utils.dart
11 3 3
DateTime _parseTime()
in lib/src/http_date.dart
11 4 1
String expectQuotedString()
in lib/src/scan.dart
10 1 3
static String _scanScheme()
in lib/src/authentication_challenge.dart
9 3 2
DateTime _makeDateTime()
in lib/src/http_date.dart
8 2 4
void main()
in example/example.dart
8 1 0
int _parseInt()
in lib/src/http_date.dart
7 2 2
List convert()
in lib/src/chunked_coding/decoder.dart
6 2 1
void addSlice()
in lib/src/chunked_coding/decoder.dart
6 3 4
void _close()
in lib/src/chunked_coding/decoder.dart
6 2 2