scitools.com

← Metric catalog

Removed Code Files is one of the source-code metrics Understand computes across 17+ languages — browse them in the GUI, export and track them, or script them with the Python API.

Removed Code Files

API IDCountDeclFileCodeRemoved
TargetsArchitectures Project
LanguagesC++
CategoriesCompare Contents
CostCached

Number of removed code files, compared to the comparison database.

Counts code files in the comparison database but not in the current database. See Code Files for what counts as a code file. Since changes come from a textual diff, a code file must have Lines to count. For an architecture or the project, each of its files is counted, and a file added to or removed from an architecture counts as new or removed.

For example, an architecture holding these files in each version:

Comparison databaseCurrent databaseStatus
classes.cppclasses.cppchanged
functions.cppfunctions.cppchanged
legacy.cppremoved
util.hutil.hsame
version.hversion.hchanged
config.hnew
extra.cppnew
main.cppnew
shapes.cppnew
shapes.hnew

legacy.cpp was removed, so CountDeclFileCodeRemoved = 1.

See New Code Files for the reverse of this metric, Changed Code Files for code files in both versions that differ, and Code Files for the total count. See Compare two versions of a project ↗ for how entities are compared, and New Lines, Removed Lines, and Changed Lines for how much a code file changed.