Neo Anderson's Blog

Cyclomatic-Complexity

字数统计: 260阅读时长: 1 min
2015/04/20
  • 圈复杂度: 通过程序源代码的线性无关路径的数量
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    27
    28
    29
    30
    31
    Metric	Description
    ca Afferent coupling : Number of classes affected by this class
    bugs Number of estimated bugs by file (Halstead metric)
    commw Comment weight measure the ratio between logical code and comments
    cc Cyclomatic complexity number measures the number of linearly independent paths through a program's source code
    dc Data Complexity (Card and Agresti metric)
    diff Difficulty of the code (Halstead metric)
    ce Efferent coupling : Number of classes that the class depend
    effort Effort to understand the code (Halstead metric)
    instability Ratio between ce and ca (I = ce / (ce + ca). Indicates the class's resilience to change
    IC Intelligent content
    lcom Lack of cohesion of methods measures the cohesiveness of a class
    length Length (Halstead metric)
    loc Number of lines of code
    lloc Number of logical lines of code
    MI Maintenability index is based on Halstead's metrics, LOC and Cyclomatic complexity number
    MIwC Maintenability Index without comments
    distance Myer's distance is derivated from Cyclomatic complexity
    interval Myer's interval indicates the distance between cyclomatic complexity number and the number of operators
    noc Number of classes
    noca Number of abstract classes
    nocc Number of concrete classes
    operators Number of operators
    rdc Relative data complexity (Card and Agresti metric)
    rsc Relative structural complexity (Card and Agresti metric)
    rsysc Relative System complexity (Card and Agresti metric)
    sc System complexity (Card and Agresti metric)
    sysc Total System complexity (Card and Agresti metric)
    time Time to read and understand the code (Halstead metric)
    vocabulary Vocabulary used in code (Halstead metric)
    volume Volume (Halstead metric)
CATALOG