microsoft / MCW-Modern-cloud-apps
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 341 units with 3,688 lines of code in units (19.1% of code).
    • 2 very complex units (226 lines of code)
    • 0 complex units (0 lines of code)
    • 9 medium complex units (278 lines of code)
    • 35 simple units (847 lines of code)
    • 295 very simple units (2,337 lines of code)
6% | 0% | 7% | 22% | 63%
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
js11% | 0% | 13% | 24% | 50%
cs0% | 0% | 0% | 21% | 78%
Conditional Complexity per Logical Component
primary logical decomposition
51+
26-50
11-25
6-10
1-5
src/Contoso Sports League/Contoso.Apps.SportsLeague.Admin/wwwroot50% | 0% | 0% | 13% | 36%
src/Contoso Sports League/Contoso.Apps.SportsLeague.Web/wwwroot0% | 0% | 17% | 27% | 55%
src/Contoso Sports League/Contoso.Apps.SportsLeague.Web/Controllers0% | 0% | 0% | 39% | 60%
src/Contoso Sports League/Contoso.Apps.PaymentGateway/Controllers0% | 0% | 0% | 93% | 6%
src/Contoso Sports League/Contoso.Apps.PaymentGateway/Throttling0% | 0% | 0% | 43% | 56%
src/Contoso Sports League/Contoso.Apps.SportsLeague.Offers/Controllers0% | 0% | 0% | 88% | 11%
src/Contoso Sports League/Contoso.Apps.SportsLeague.Data/Logic0% | 0% | 0% | 16% | 83%
src/Contoso Sports League/Contoso.Apps.FunctionApp0% | 0% | 0% | 21% | 78%
src/Contoso Sports League/Contoso.Apps.PaymentGateway/Extensions0% | 0% | 0% | 84% | 15%
src/Contoso Sports League/Contoso.Apps.SportsLeague.Web/Helpers0% | 0% | 0% | 0% | 100%
src/Contoso Sports League/Contoso.Apps.SportsLeague.Data/Models0% | 0% | 0% | 0% | 100%
src/Contoso Sports League/Contoso.Apps.PaymentGateway0% | 0% | 0% | 0% | 100%
src/Contoso Sports League/Contoso.Apps.Common0% | 0% | 0% | 0% | 100%
src/Contoso Sports League/Contoso.Apps.SportsLeague.Admin/Controllers0% | 0% | 0% | 0% | 100%
src/Contoso Sports League/Contoso.Apps.SportsLeague.Offers0% | 0% | 0% | 0% | 100%
src/Contoso Sports League/Contoso.Apps.SportsLeague.Web0% | 0% | 0% | 0% | 100%
src/Contoso Sports League/Contoso.Apps.SportsLeague.Admin0% | 0% | 0% | 0% | 100%
src/Contoso Sports League/Contoso.Apps.SportsLeague.Admin/EasyAuth0% | 0% | 0% | 0% | 100%
src/Contoso Sports League/Contoso.Apps.PaymentGateway/Formatters0% | 0% | 0% | 0% | 100%
src/Contoso Sports League/Contoso.Apps.SportsLeague.Web/Models0% | 0% | 0% | 0% | 100%
src/Contoso Sports League/Contoso.Apps.Common/Extensions0% | 0% | 0% | 0% | 100%
src/Contoso Sports League/Contoso.Apps.PaymentGateway/Models0% | 0% | 0% | 0% | 100%
Most Complex Units
Top 20 most complex units
Unit# linesMcCabe index# params
113 62 1
var doc = w.document, docElem = doc.documentElement, mediastyles = [], rules = [], appendedEls = [], parsedSheets = {}, resizeThrottle = 30, head = doc.getElementsByTagName()
in Hands-on lab/lab-files/src/Contoso Sports League/Contoso.Apps.SportsLeague.Admin/wwwroot/js/respond.matchmedia.addListener.js
113 62 1
Tooltip.prototype.show = function()
in Hands-on lab/lab-files/src/Contoso Sports League/Contoso.Apps.SportsLeague.Web/wwwroot/js/plugins.js
50 21 0
Modal.prototype.backdrop = function()
in Hands-on lab/lab-files/src/Contoso Sports League/Contoso.Apps.SportsLeague.Web/wwwroot/js/plugins.js
37 16 1
Dropdown.prototype.keydown = function()
in Hands-on lab/lab-files/src/Contoso Sports League/Contoso.Apps.SportsLeague.Web/wwwroot/js/plugins.js
21 15 1
Affix.prototype.getState = function()
in Hands-on lab/lab-files/src/Contoso Sports League/Contoso.Apps.SportsLeague.Web/wwwroot/js/plugins.js
16 14 4
Collapse.prototype.show = function()
in Hands-on lab/lab-files/src/Contoso Sports League/Contoso.Apps.SportsLeague.Web/wwwroot/js/plugins.js
30 13 0
Tooltip.prototype.init = function()
in Hands-on lab/lab-files/src/Contoso Sports League/Contoso.Apps.SportsLeague.Web/wwwroot/js/plugins.js
26 12 3
Affix.prototype.checkPosition = function()
in Hands-on lab/lab-files/src/Contoso Sports League/Contoso.Apps.SportsLeague.Web/wwwroot/js/plugins.js
30 11 0
Carousel.prototype.slide = function()
in Hands-on lab/lab-files/src/Contoso Sports League/Contoso.Apps.SportsLeague.Web/wwwroot/js/plugins.js
43 11 2
ScrollSpy.prototype.process = function()
in Hands-on lab/lab-files/src/Contoso Sports League/Contoso.Apps.SportsLeague.Web/wwwroot/js/plugins.js
25 11 0
$()
in Hands-on lab/lab-files/src/Contoso Sports League/Contoso.Apps.SportsLeague.Web/wwwroot/js/plugins.js
14 10 1
public async Task Review()
in Hands-on lab/lab-files/src/Contoso Sports League/Contoso.Apps.SportsLeague.Web/Controllers/CheckoutController.cs
76 9 1
public async Task Complete()
in Hands-on lab/lab-files/src/Contoso Sports League/Contoso.Apps.SportsLeague.Web/Controllers/CheckoutController.cs
69 9 1
Tooltip.prototype.enter = function()
in Hands-on lab/lab-files/src/Contoso Sports League/Contoso.Apps.SportsLeague.Web/wwwroot/js/plugins.js
16 9 1
Tooltip.prototype.getViewportAdjustedDelta = function()
in Hands-on lab/lab-files/src/Contoso Sports League/Contoso.Apps.SportsLeague.Web/wwwroot/js/plugins.js
24 9 4
Modal.prototype.show = function()
in Hands-on lab/lab-files/src/Contoso Sports League/Contoso.Apps.SportsLeague.Web/wwwroot/js/plugins.js
41 9 1
public ActionResult PerformAction()
in Hands-on lab/lab-files/src/Contoso Sports League/Contoso.Apps.PaymentGateway/Controllers/ProcessorController.cs
58 8 1
Number.prototype.toMoney = function()
in Hands-on lab/lab-files/src/Contoso Sports League/Contoso.Apps.SportsLeague.Web/wwwroot/js/main.js
10 8 3
Alert.prototype.close = function()
in Hands-on lab/lab-files/src/Contoso Sports League/Contoso.Apps.SportsLeague.Web/wwwroot/js/plugins.js
21 8 1