microsoft / fhir-server-samples
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 25 units with 425 lines of code in units (26.6% of code).
    • 0 very complex units (0 lines of code)
    • 0 complex units (0 lines of code)
    • 2 medium complex units (163 lines of code)
    • 1 simple units (29 lines of code)
    • 22 very simple units (233 lines of code)
0% | 0% | 38% | 6% | 54%
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
cs0% | 0% | 71% | 0% | 28%
js0% | 0% | 0% | 14% | 85%
Conditional Complexity per Logical Component
primary logical decomposition
51+
26-50
11-25
6-10
1-5
src/FhirImporter0% | 0% | 71% | 0% | 28%
src/FhirDashboardJS/js0% | 0% | 0% | 14% | 85%
Most Complex Units
Top 20 most complex units
Unit# linesMcCabe index# params
private static void ConvertUUIDs()
in src/FhirImporter/FhirImportReferenceConverter.cs
34 13 2
public static async Task Run()
in src/FhirImporter/FhirBundleBlobTrigger.cs
129 12 2
success: function()
in src/FhirDashboardJS/js/PatientModule.js
29 8 2
function getAgeFromDateString()
in src/FhirDashboardJS/js/PatientModule.js
12 4 1
private static Dictionary CreateUUIDLookUpTable()
in src/FhirImporter/FhirImportReferenceConverter.cs
26 4 1
getAccessToken()
in src/FhirDashboardJS/js/ConfigAuth.js
11 3 1
function appendRowToTable()
in src/FhirDashboardJS/js/PatientModule.js
13 3 3
private static CloudBlockBlob GetBlobReference()
in src/FhirImporter/FhirBundleBlobTrigger.cs
25 3 3
getFhirServerUrl()
in src/FhirDashboardJS/js/ConfigAuth.js
12 2 1
getSmartOnFhirApps()
in src/FhirDashboardJS/js/ConfigAuth.js
14 2 1
refreshTokens()
in src/FhirDashboardJS/js/ConfigAuth.js
15 2 1
success: function()
in src/FhirDashboardJS/js/PatientModule.js
10 2 2
constructor()
in src/FhirDashboardJS/js/AboutMeModule.js
4 1 2
render()
in src/FhirDashboardJS/js/AboutMeModule.js
26 1 0
constructor()
in src/FhirDashboardJS/js/ConfigAuth.js
2 1 0
getFhirServerAccessInfo()
in src/FhirDashboardJS/js/ConfigAuth.js
8 1 1
beforeSend: function()
in src/FhirDashboardJS/js/PatientModule.js
3 1 1
success: function()
in src/FhirDashboardJS/js/PatientModule.js
8 1 2
beforeSend: function()
in src/FhirDashboardJS/js/PatientModule.js
3 1 1
beforeSend: function()
in src/FhirDashboardJS/js/PatientModule.js
3 1 1