dart-lang / async
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 172 units with 1,267 lines of code in units (53.8% 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)
    • 5 simple units (125 lines of code)
    • 167 very simple units (1,142 lines of code)
0% | 0% | 0% | 9% | 90%
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% | 9% | 90%
Conditional Complexity per Logical Component
primary logical decomposition
51+
26-50
11-25
6-10
1-5
lib/src0% | 0% | 0% | 11% | 88%
lib/src/stream_sink_transformer0% | 0% | 0% | 0% | 100%
lib/src/result0% | 0% | 0% | 0% | 100%
lib/src/delegate0% | 0% | 0% | 0% | 100%
lib/src/typed0% | 0% | 0% | 0% | 100%
Most Complex Units
Top 20 most complex units
Unit# linesMcCabe index# params
void add()
in lib/src/future_group.dart
20 8 1
CancelableOperation then()
in lib/src/cancelable_operation.dart
28 8 1
void complete()
in lib/src/cancelable_operation.dart
21 7 1
Future? _onCancel()
in lib/src/stream_group.dart
22 6 0
Stream bind()
in lib/src/stream_closer.dart
34 6 1
StreamSubscription listen()
in lib/src/stream_completer.dart
16 5 1
bool update()
in lib/src/stream_queue.dart
17 5 2
bool update()
in lib/src/stream_queue.dart
16 5 2
bool update()
in lib/src/stream_queue.dart
16 5 2
bool update()
in lib/src/stream_queue.dart
7 5 2
static CancelableOperation race()
in lib/src/cancelable_operation.dart
24 5 1
Future? add()
in lib/src/stream_group.dart
13 4 1
void _onListen()
in lib/src/stream_group.dart
13 4 0
Stream split()
in lib/src/stream_splitter.dart
17 4 0
Future? cancel()
in lib/src/stream_queue.dart
11 4 1
void _updateRequests()
in lib/src/stream_queue.dart
12 4 0
Stream _extractStream()
in lib/src/stream_queue.dart
16 4 0
void commit()
in lib/src/stream_queue.dart
13 4 1
void _done()
in lib/src/stream_queue.dart
12 4 0
bool update()
in lib/src/stream_queue.dart
19 4 2