microsoft / ObjectStoreProvider
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 77 units with 1,321 lines of code in units (40.1% of code).
    • 0 very complex units (0 lines of code)
    • 2 complex units (480 lines of code)
    • 1 medium complex units (28 lines of code)
    • 6 simple units (138 lines of code)
    • 68 very simple units (675 lines of code)
0% | 36% | 2% | 10% | 51%
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
ts0% | 36% | 2% | 10% | 51%
Conditional Complexity per Logical Component
primary logical decomposition
51+
26-50
11-25
6-10
1-5
src0% | 37% | 2% | 10% | 49%
src/ordered-map0% | 0% | 0% | 0% | 100%
Most Complex Units
Top 20 most complex units
Unit# linesMcCabe index# params
async open()
in src/IndexedDbProvider.ts
229 47 4
objectStores: join()
in src/IndexedDbProvider.ts
251 44 2
private _getKeyCountForRange()
in src/InMemoryProvider.ts
28 11 4
private _checkNextTransactions()
in src/TransactionLockHelper.ts
43 10 0
private _getKeysForRange()
in src/InMemoryProvider.ts
24 9 4
private _getKeyValues()
in src/InMemoryProvider.ts
25 7 4
public internal_getKeysFromItem()
in src/InMemoryProvider.ts
19 6 1
export function isIE()
in src/ObjectStoreProviderUtils.ts
10 6 0
export function serializeNumberToOrderableString()
in src/ObjectStoreProviderUtils.ts
17 6 1
public put()
in src/InMemoryProvider.ts
21 5 2
getWindow()
in src/IndexedDbProvider.ts
8 5 0
static iterateOverCursorRequest()
in src/IndexedDbProvider.ts
32 5 2
export function isSafari()
in src/ObjectStoreProviderUtils.ts
9 5 0
export function serializeValueToOrderableString()
in src/ObjectStoreProviderUtils.ts
19 5 1
private _getStoreIndexTransaction()
in src/ObjectStoreProvider.ts
15 4 3
export function trimArray()
in src/ObjectStoreProviderUtils.ts
13 4 2
export function getKeyForKeypath()
in src/ObjectStoreProviderUtils.ts
15 4 2
export function formListOfKeys()
in src/ObjectStoreProviderUtils.ts
21 4 2
export function serializeKeyToString()
in src/ObjectStoreProviderUtils.ts
32 4 2
private _checkClose()
in src/TransactionLockHelper.ts
6 4 0