microsoft / XmlNotepad
Source Code Overview

Analysis scope, overview of main, test, generated, deployment, build, and other code.

Source Code Analysis Scope
Files includes and excluded from analyses
resx
csproj
xsd
xsl
xslt
xaml
cmd
txt
wixproj
gitattributes
props
wxs
  • 24 extensions are included in analyses: cs, xml, md, resx, htm, html, js, css, csproj, xsd, yml, xsl, xslt, svg, json, yaml, xaml, cmd, txt, wixproj, gitattributes, gitignore, props, wxs
  • 9 criteria are used to exclude files from analysis:
    • exclude files with path like ".*/[.][a-zA-Z0-9_]+.*" (Hidden files and folders) (6 files).
    • exclude files with path like ".*/docs/.*" (Documentation) (46 files).
    • exclude files with path like "(?i).*/jquery.*[.]js" (jQuery files) (0 files).
    • exclude files with path like ".*[.]resx" (The resx resource files) (18 files).
    • exclude files with path like ".*/git[-]history[.]txt" (Git history) (1 file).
    • exclude files with path like ".*/git[-][a-zA-Z0-9_]+[.]txt" (Git data exports for sokrates analyses) (0 files).
    • exclude files with path like ".*/sokrates_conventions[.]json" (Sokrates scoping conventions) (1 file).
    • exclude files with path like ".*/bootstrap[-].*" (Library) (0 files).
    • exclude files with path like ".*[.]txt" (Text files) (1 file).
Overview of Analyzed Files
Basic stats on analyzed files
Intro
For analysis purposes we separate files in scope into several categories: main, test, generated, deployment and build, and other.

  • The main category contains all manually created source code files that are being used in the production.
  • Files in the main category are used as input for other analyses: logical decomposition, concerns, duplication, file size, unit size, and conditional complexity.
  • Test source code files are used only for testing of the product. These files are normally not deployed to production.
  • Build and deployment source code files are used to configure or support build and deployment process.
  • Generated source code files are automatically generated files that have not been manually changed after generation.
  • While a source code folder may contain a number of files, we are primarily interested in the source code files that are being written and maintained by developers.
  • Files containing binaries, documentation, or third-party libraries, for instance, are excluded from analysis. The exception are third-party libraries that have been changed by developers.

main32106 LOC (60%) 117 files
test4708 LOC (8%) 10 files
generated1226 LOC (2%) 7 files
build and deployment1097 LOC (2%) 8 files
other13714 LOC (25%) 38 files
Main Code
All manually created or maintained source code that defines logic of the product that is run in a production environment.
wxs
xslt
xaml
cmd
wixproj
props
xsl
Explore:   circles  |  sunburst
  • The following criteria are used to filter files:
    • files with paths like ".*".
  • 117 files match defined criteria (32,106 lines of code, 100.0% vs. main code):
    • 79 *.cs files (28,056 lines of code)
    • 16 *.htm files (2,589 lines of code)
    • 1 *.wxs files (338 lines of code)
    • 4 *.xslt files (308 lines of code)
    • 3 *.xaml files (291 lines of code)
    • 2 *.html files (139 lines of code)
    • 3 *.cmd files (133 lines of code)
    • 1 *.css files (55 lines of code)
    • 1 *.yml files (55 lines of code)
    • 1 *.wixproj files (51 lines of code)
    • 3 *.yaml files (50 lines of code)
    • 1 *.js files (27 lines of code)
    • 1 *.props files (7 lines of code)
    • 1 *.xsl files (7 lines of code)
  • " *.cs" is biggest, containing 87.39% of code.
  • " *.xsl" is smallest, containing 0.02% of code.


*.cs28056 LOC (87%) 79 files
*.htm2589 LOC (8%) 16 files
*.wxs338 LOC (1%) 1 files
*.xslt308 LOC (<1%) 4 files
*.xaml291 LOC (<1%) 3 files
*.html139 LOC (<1%) 2 files
*.cmd133 LOC (<1%) 3 files
*.css55 LOC (<1%) 1 files
*.yml55 LOC (<1%) 1 files
*.wixproj51 LOC (<1%) 1 files
*.yaml50 LOC (<1%) 3 files
*.js27 LOC (<1%) 1 files
*.props7 LOC (<1%) 1 files
*.xsl7 LOC (<1%) 1 files
Test Code
Used only for testing of the product. Normally not deployed in a production environment.
xslt
csproj
xsl
Explore:   circles  |  sunburst
  • The following criteria are used to filter files:
    • files with paths like ".*/UnitTests?/.*".
    • files with any line of content like ".*/simpletest/.*".
    • files with paths like ".*UnitTests/.*".
  • 10 files match defined criteria (4,708 lines of code, 14.7% vs. main code):
    • 6 *.cs files (4,283 lines of code)
    • 1 *.xslt files (289 lines of code)
    • 1 *.csproj files (121 lines of code)
    • 2 *.xsl files (15 lines of code)
  • " *.cs" is biggest, containing 90.97% of code.
  • " *.xsl" is smallest, containing 0.32% of code.


*.cs4283 LOC (90%) 6 files
*.xslt289 LOC (6%) 1 files
*.csproj121 LOC (2%) 1 files
*.xsl15 LOC (<1%) 2 files
Generated Code
Automatically generated files, not manually changed after generation.
Explore:   circles  |  sunburst
  • The following criteria are used to filter files:
    • files with paths like ".*[.]cs" AND any line of content like "[/][/][ ]*".
  • 7 files match defined criteria (1,226 lines of code, 3.8% vs. main code). All matches are in *.cs files.


*.cs1226 LOC (100%) 7 files
Build and Deployment Code
Source code used to configure or support build and deployment process.
csproj
Explore:   circles  |  sunburst
  • The following criteria are used to filter files:
    • files with paths like ".*[.]git[a-z]+".
    • files with paths like ".*/[.]gitattributes".
    • files with paths like ".*/[.]gitignore".
    • files with paths like ".*[.]csproj".
  • 8 files match defined criteria (1,097 lines of code, 3.4% vs. main code). All matches are in *.csproj files.


*.csproj1097 LOC (100%) 8 files
Other Code
xsd
xsl
Explore:   circles  |  sunburst
  • The following criteria are used to filter files:
    • files with paths like ".*[.]json".
    • files with paths like ".*/[.]gitignore".
    • files with paths like ".*[.]svg".
    • files with paths like ".*[.]md".
    • files with paths like ".*[.]txt".
    • files with paths like ".*/[Ss]amples/.*".
    • files with paths like ".*[.](xml|xsd|robot|sql|pgsql|dashboard|profile|ipynb|raml|avsc|al)".
  • 38 files match defined criteria (13,714 lines of code, 42.7% vs. main code):
    • 25 *.xml files (11,291 lines of code)
    • 6 *.xsd files (2,139 lines of code)
    • 2 *.xsl files (154 lines of code)
    • 2 *.json files (53 lines of code)
    • 1 *.svg files (48 lines of code)
    • 2 *.md files (29 lines of code)
  • " *.xml" is biggest, containing 82.33% of code.
  • " *.md" is smallest, containing 0.21% of code.


*.xml11291 LOC (82%) 25 files
*.xsd2139 LOC (15%) 6 files
*.xsl154 LOC (1%) 2 files
*.json53 LOC (<1%) 2 files
*.svg48 LOC (<1%) 1 files
*.md29 LOC (<1%) 2 files
Analyzers
Info about analyzers used for source code examinations.
  • *.cs files are analyzed with CSharpAnalyzer:
    • All basic standard analyses supported (source code overview, duplication, file size, concerns, findings, metrics, controls)
    • Advanced code cleaning (empty lines and comments removed for LOC calculations, additional cleaning for duplication calculations)
    • Unit size analysis
    • Conditional complexity analysis
    • Advanced heuristic dependency analysis (based on namespace heuristics)
  • *.htm files are analyzed with HtmlAnalyzer:
    • All basic standard analyses supported (source code overview, duplication, file size, concerns, findings, metrics, controls)
    • Advanced code cleaning (empty lines and comments removed for LOC calculations, additional cleaning for duplication calculations)
    • Unit size analysis
    • Conditional complexity analysis
    • Advanced heuristic dependency analysis
  • *.wxs files are analyzed with XmlAnalyzer:
    • All basic standard analyses supported (source code overview, duplication, file size, concerns, findings, metrics, controls)
    • Advanced code cleaning (empty lines and comments removed for LOC calculations, additional cleaning for duplication calculations)
    • No unit size analysis
    • No conditional complexity analysis
    • No dependency analysis
  • *.xslt files are analyzed with XmlAnalyzer:
    • All basic standard analyses supported (source code overview, duplication, file size, concerns, findings, metrics, controls)
    • Advanced code cleaning (empty lines and comments removed for LOC calculations, additional cleaning for duplication calculations)
    • No unit size analysis
    • No conditional complexity analysis
    • No dependency analysis
  • *.xaml files are analyzed with XmlAnalyzer:
    • All basic standard analyses supported (source code overview, duplication, file size, concerns, findings, metrics, controls)
    • Advanced code cleaning (empty lines and comments removed for LOC calculations, additional cleaning for duplication calculations)
    • No unit size analysis
    • No conditional complexity analysis
    • No dependency analysis
  • *.html files are analyzed with HtmlAnalyzer:
    • All basic standard analyses supported (source code overview, duplication, file size, concerns, findings, metrics, controls)
    • Advanced code cleaning (empty lines and comments removed for LOC calculations, additional cleaning for duplication calculations)
    • Unit size analysis
    • Conditional complexity analysis
    • Advanced heuristic dependency analysis
  • *.cmd files are analyzed with DefaultLanguageAnalyzer:
    • All basic standard analyses supported (source code overview, duplication, file size, concerns, findings, metrics, controls)
    • Basic code cleaning (empty lines removed for LOC calculations and duplication calculations)
    • No unit size analysis
    • No conditional complexity analysis
    • No dependency analysis
  • *.css files are analyzed with CssAnalyzer:
    • All basic standard analyses supported (source code overview, duplication, file size, concerns, findings, metrics, controls)
    • Advanced code cleaning (empty lines and comments removed for LOC calculations, additional cleaning for duplication calculations)
    • No unit size analysis
    • No conditional complexity analysis
    • No dependency analysis
  • *.yml files are analyzed with YamlAnalyzer:
    • All basic standard analyses supported (source code overview, duplication, file size, concerns, findings, metrics, controls)
    • Advanced code cleaning (empty lines and comments removed for LOC calculations, additional cleaning for duplication calculations)
    • No unit size analysis
    • No conditional complexity analysis
    • No dependency analysis
  • *.wixproj files are analyzed with XmlAnalyzer:
    • All basic standard analyses supported (source code overview, duplication, file size, concerns, findings, metrics, controls)
    • Advanced code cleaning (empty lines and comments removed for LOC calculations, additional cleaning for duplication calculations)
    • No unit size analysis
    • No conditional complexity analysis
    • No dependency analysis
  • *.yaml files are analyzed with YamlAnalyzer:
    • All basic standard analyses supported (source code overview, duplication, file size, concerns, findings, metrics, controls)
    • Advanced code cleaning (empty lines and comments removed for LOC calculations, additional cleaning for duplication calculations)
    • No unit size analysis
    • No conditional complexity analysis
    • No dependency analysis
  • *.js files are analyzed with JavaScriptAnalyzer:
    • All basic standard analyses supported (source code overview, duplication, file size, concerns, findings, metrics, controls)
    • Advanced code cleaning (empty lines and comments removed for LOC calculations, additional cleaning for duplication calculations)
    • Unit size analysis
    • Conditional complexity analysis
    • No dependency analysis
  • *.props files are analyzed with XmlAnalyzer:
    • All basic standard analyses supported (source code overview, duplication, file size, concerns, findings, metrics, controls)
    • Advanced code cleaning (empty lines and comments removed for LOC calculations, additional cleaning for duplication calculations)
    • No unit size analysis
    • No conditional complexity analysis
    • No dependency analysis
  • *.xsl files are analyzed with XmlAnalyzer:
    • All basic standard analyses supported (source code overview, duplication, file size, concerns, findings, metrics, controls)
    • Advanced code cleaning (empty lines and comments removed for LOC calculations, additional cleaning for duplication calculations)
    • No unit size analysis
    • No conditional complexity analysis
    • No dependency analysis


2022-01-30 13:35