dart-lang / http
Conditional Complexity

The distribution of complexity of units (measured with McCabe index).

Intro
  • Conditional complexity (also called cyclomatic complexity) is a term used to measure the complexity of software. The term refers to the number of possible paths through a program function. A higher value ofter means higher maintenance and testing costs (infosecinstitute.com).
  • Conditional complexity is calculated by counting all conditions in the program that can affect the execution path (e.g. if statement, loops, switches, and/or operators, try and catch blocks...).
  • Conditional complexity is measured at the unit level (methods, functions...).
  • Units are classified in four categories based on the measured McCabe index: 1-5 (simple units), 6-10 (medium complex units), 11-25 (complex units), 26+ (very complex units).
Learn more...
Conditional Complexity Overall
  • There are 74 units with 447 lines of code in units (38.2% of code).
    • 0 very complex units (0 lines of code)
    • 0 complex units (0 lines of code)
    • 0 medium complex units (0 lines of code)
    • 1 simple units (19 lines of code)
    • 73 very simple units (428 lines of code)
0% | 0% | 0% | 4% | 95%
Legend:
51+
26-50
11-25
6-10
1-5
Alternative Visuals
Conditional Complexity per Extension
51+
26-50
11-25
6-10
1-5
dart0% | 0% | 0% | 4% | 95%
Conditional Complexity per Logical Component
primary logical decomposition
51+
26-50
11-25
6-10
1-5
lib/src0% | 0% | 0% | 5% | 94%
lib0% | 0% | 0% | 0% | 100%
example0% | 0% | 0% | 0% | 100%
Most Complex Units
Top 20 most complex units
Unit# linesMcCabe index# params
Future _sendUnstreamed()
in lib/src/base_client.dart
19 7 5
Future send()
in lib/src/io_client.dart
38 4 1
void _checkResponseSuccess()
in lib/src/base_client.dart
8 3 2
set body()
in lib/src/request.dart
9 3 1
set bodyFields()
in lib/src/request.dart
10 3 1
set contentLength()
in lib/src/base_request.dart
7 3 1
Uint8List toUint8List()
in lib/src/utils.dart
7 3 1
void close()
in lib/src/browser_client.dart
5 2 0
set encoding()
in lib/src/request.dart
7 2 1
set _contentType()
in lib/src/request.dart
7 2 1
void _checkFinalized()
in lib/src/request.dart
4 2 0
static String _validateMethod()
in lib/src/base_request.dart
6 2 1
ByteStream finalize()
in lib/src/base_request.dart
5 2 0
Future send()
in lib/src/base_request.dart
17 2 0
void _checkFinalized()
in lib/src/base_request.dart
4 2 0
String _headerForField()
in lib/src/multipart_request.dart
10 2 2
String _headerForFile()
in lib/src/multipart_request.dart
8 2 1
void close()
in lib/src/io_client.dart
6 2 0
ByteStream finalize()
in lib/src/multipart_file.dart
7 2 0
Encoding encodingForCharset()
in lib/src/utils.dart
4 2 2