microsoft / IIS.ServiceMonitor
Unit Size

The distribution of size of units (measured in lines of code).

Intro
  • Unit size measurements show the distribution of size of units of code (methods, functions...).
  • Units are classified in four categories based on their size (lines of code): 1-20 (small units), 20-50 (medium size units), 51-100 (long units), 101+ (very long units).
  • You should aim at keeping units small (< 20 lines). Long units may become "bloaters", code that have increased to such gargantuan proportions that they are hard to work with.
Learn more...
Unit Size Overall
  • There are 14 units with 542 lines of code in units (60.6% of code).
    • 0 very long units (0 lines of code)
    • 4 long units (295 lines of code)
    • 6 medium size units (191 lines of code)
    • 3 small units (46 lines of code)
    • 1 very small units (10 lines of code)
0% | 54% | 35% | 8% | 1%
Legend:
101+
51-100
21-50
11-20
1-10
Unit Size per Extension
101+
51-100
21-50
11-20
1-10
cpp0% | 54% | 35% | 8% | 1%
Unit Size per Logical Component
primary logical decomposition
101+
51-100
21-50
11-20
1-10
src/ServiceMonitor0% | 54% | 35% | 8% | 1%
Alternative Visuals
Longest Units
Top 14 longest units
Unit# linesMcCabe index# params
HRESULT IISConfigUtil::UpdateEnvironmentVarsToConfig()
in src/ServiceMonitor/IISConfigUtil.cpp
88 15 1
int __cdecl _tmain()
in src/ServiceMonitor/Main.cpp
73 13 2
HRESULT Service_Monitor::StartServiceByName()
in src/ServiceMonitor/ServiceMonitor.cpp
68 11 2
HRESULT Service_Monitor::StopServiceByName()
in src/ServiceMonitor/ServiceMonitor.cpp
66 15 2
HRESULT IISConfigUtil::BuildAppCmdCommand()
in src/ServiceMonitor/IISConfigUtil.cpp
40 5 5
HRESULT Service_Monitor::MonitoringService()
in src/ServiceMonitor/ServiceMonitor.cpp
40 6 3
HRESULT IISConfigUtil::RunCommand()
in src/ServiceMonitor/IISConfigUtil.cpp
34 5 2
HRESULT IISConfigUtil::Initialize()
in src/ServiceMonitor/IISConfigUtil.cpp
32 5 0
HRESULT Service_Monitor::EnsureInitialized()
in src/ServiceMonitor/ServiceMonitor.cpp
23 4 0
HRESULT Service_Monitor::GetServiceHandle()
in src/ServiceMonitor/ServiceMonitor.cpp
22 4 2
BOOL WINAPI CtrlHandle()
in src/ServiceMonitor/Main.cpp
18 6 1
BOOL IISConfigUtil::FilterEnv()
in src/ServiceMonitor/IISConfigUtil.cpp
17 4 3
VOID CALLBACK Service_Monitor::NotifyCallBack()
in src/ServiceMonitor/ServiceMonitor.cpp
11 2 1
void IISConfigUtil::Replace()
in src/ServiceMonitor/IISConfigUtil.cpp
10 2 3