[GRASS-QA] GRASS QA: mmetz |global.h main.c read_dxf.c user1.c ...| no clones | 0 monsters |0 warnings

soccerlab.info at gmail.com soccerlab.info at gmail.com
Fri Aug 7 11:40:40 EDT 2009


Hello mmetz,

here's a report on your recent GRASS-SVN change : 

ANALYSIS 

your changes to files/class/methods/functions : 

*****************************************************************
          File :grass/trunk/vector/v.in.dxf/global.h
*****************************************************************

          Class
dxf_file(Begins at: 9, Ends at:16)
             +--------+--------+--------+--------+--------+--------+
             |    DIT |    NOC |    WMC |    RFC |    CBO |   LCOM |
+------------+--------+--------+--------+--------+--------+--------|
|NEW Metrics |      1 |      0 |      0 |      0 |      0 |      0 |
+------------+--------+--------+--------+--------+--------+--------|
|OLD Metrics |      1 |      0 |      0 |      0 |      0 |      0 |
+------------+--------+--------+--------+--------+--------+--------+



Clone analysis:
This file does not contain cloned functions

*****************************************************************
          File :grass/trunk/vector/v.in.dxf/main.c
*****************************************************************

          Function
main(Begins at: 41, Ends at:210)
--------------+---------+-------+--------------+-----------+
              |          New Metrics           |Old Metrics|
--------------+---------+-------+--------------+-----------+
Complexity:   |      17 |    ** | BABY-MONSTER |        17 |
ParamNBR:     |       2 |       |           OK |         2 |
CalledNBR:    |      66 |   *** |      MONSTER |        66 |
LOC:          |     170 |   *** |      MONSTER |       170 |
--------------+---------+-------+--------------+-----------+
Conclusion:   | this function is a       MONSTER           |
-----------------------------------------------------------+
 metric are OUT OF RANGE!


Clone analysis:
This file does not contain cloned functions

*****************************************************************
          File :grass/trunk/vector/v.in.dxf/read_dxf.c
*****************************************************************

          Function
dxf_close(Begins at: 38, Ends at:45)
--------------+---------+-------+--------------+-----------+
              |          New Metrics           |Old Metrics|
--------------+---------+-------+--------------+-----------+
Complexity:   |       1 |       |           OK |         1 |
ParamNBR:     |       1 |       |           OK |         1 |
CalledNBR:    |       3 |       |           OK |         3 |
LOC:          |       8 |       |           OK |         8 |
--------------+---------+-------+--------------+-----------+
Conclusion:   | this function is a            OK           |
-----------------------------------------------------------+
metrics are OK


dxf_fgets(Begins at: 83, Ends at:94)
--------------+---------+-------+--------------+-----------+
              |          New Metrics           |Old Metrics|
--------------+---------+-------+--------------+-----------+
Complexity:   |       2 |       |           OK |         2 |
ParamNBR:     |       3 |     * |      WARNING |         3 |
CalledNBR:    |       4 |       |           OK |         4 |
LOC:          |      12 |       |           OK |        12 |
--------------+---------+-------+--------------+-----------+
Conclusion:   | this function is a       WARNING           |
-----------------------------------------------------------+
 at least 1 values are close to an outlier please consider revising code!


dxf_find_header(Begins at: 48, Ends at:60)
--------------+---------+-------+--------------+-----------+
              |          New Metrics           |Old Metrics|
--------------+---------+-------+--------------+-----------+
Complexity:   |       3 |       |           OK |         3 |
ParamNBR:     |       1 |       |           OK |         1 |
CalledNBR:    |       6 |       |           OK |         6 |
LOC:          |      13 |       |           OK |        13 |
--------------+---------+-------+--------------+-----------+
Conclusion:   | this function is a            OK           |
-----------------------------------------------------------+
metrics are OK


dxf_open(Begins at: 8, Ends at:36)
--------------+---------+-------+--------------+-----------+
              |          New Metrics           |Old Metrics|
--------------+---------+-------+--------------+-----------+
Complexity:   |       4 |       |           OK |         4 |
ParamNBR:     |       1 |       |           OK |         1 |
CalledNBR:    |       8 |       |           OK |         8 |
LOC:          |      29 |       |           OK |        29 |
--------------+---------+-------+--------------+-----------+
Conclusion:   | this function is a            OK           |
-----------------------------------------------------------+
metrics are OK


dxf_read_code(Begins at: 66, Ends at:81)
--------------+---------+-------+--------------+-----------+
              |          New Metrics           |Old Metrics|
--------------+---------+-------+--------------+-----------+
Complexity:   |       4 |       |           OK |         4 |
ParamNBR:     |       3 |     * |      WARNING |         3 |
CalledNBR:    |       3 |       |           OK |         3 |
LOC:          |      16 |       |           OK |        16 |
--------------+---------+-------+--------------+-----------+
Conclusion:   | this function is a       WARNING           |
-----------------------------------------------------------+
 at least 1 values are close to an outlier please consider revising code!


Clone analysis:
This file does not contain cloned functions

*****************************************************************
          File :grass/trunk/vector/v.vol.rst/user1.c
*****************************************************************

          Function
INPUT(Begins at: 63, Ends at:382)
--------------+---------+-------+--------------+-----------+
              |          New Metrics           |Old Metrics|
--------------+---------+-------+--------------+-----------+
Complexity:   |      46 |   *** |      MONSTER |        46 |
ParamNBR:     |       4 |     * |      WARNING |         4 |
CalledNBR:    |      71 |   *** |      MONSTER |        71 |
LOC:          |     320 |   *** |      MONSTER |       320 |
--------------+---------+-------+--------------+-----------+
Conclusion:   | this function is a       MONSTER           |
-----------------------------------------------------------+
 metric are OUT OF RANGE!


OUTGR(Begins at: 388, Ends at:782)
--------------+---------+-------+--------------+-----------+
              |          New Metrics           |Old Metrics|
--------------+---------+-------+--------------+-----------+
Complexity:   |      75 |   *** |      MONSTER |        75 |
ParamNBR:     |       0 |       |           OK |         0 |
CalledNBR:    |     114 |   *** |      MONSTER |       114 |
LOC:          |     395 |   *** |      MONSTER |       395 |
--------------+---------+-------+--------------+-----------+
Conclusion:   | this function is a       MONSTER           |
-----------------------------------------------------------+
 metric are OUT OF RANGE!


Clone analysis:
This file does not contain cloned functions

*****************************************************************
          File :grass/trunk/vector/v.vol.rst/user3.c
*****************************************************************

          Function
COGRR1(Begins at: 219, Ends at:654)
--------------+---------+-------+--------------+-----------+
              |          New Metrics           |Old Metrics|
--------------+---------+-------+--------------+-----------+
Complexity:   |      74 |   *** |      MONSTER |        74 |
ParamNBR:     |       9 |   *** |      MONSTER |         9 |
CalledNBR:    |      59 |   *** |      MONSTER |        59 |
LOC:          |     436 |   *** |      MONSTER |       436 |
--------------+---------+-------+--------------+-----------+
Conclusion:   | this function is a       MONSTER           |
-----------------------------------------------------------+
 metric are OUT OF RANGE!


POINT(Begins at: 659, Ends at:775)
--------------+---------+-------+--------------+-----------+
              |          New Metrics           |Old Metrics|
--------------+---------+-------+--------------+-----------+
Complexity:   |      15 |    ** | BABY-MONSTER |        15 |
ParamNBR:     |       3 |     * |      WARNING |         3 |
CalledNBR:    |       9 |       |           OK |         9 |
LOC:          |     117 |    ** | BABY-MONSTER |       117 |
--------------+---------+-------+--------------+-----------+
Conclusion:   | this function is a  BABY-MONSTER           |
-----------------------------------------------------------+
 metric are OUT OF RANGE!


secpar_loop(Begins at: 49, Ends at:214)
--------------+---------+-------+--------------+-----------+
              |          New Metrics           |Old Metrics|
--------------+---------+-------+--------------+-----------+
Complexity:   |      35 |   *** |      MONSTER |        35 |
ParamNBR:     |       3 |     * |      WARNING |         3 |
CalledNBR:    |      18 |     * |      WARNING |        18 |
LOC:          |     166 |   *** |      MONSTER |       166 |
--------------+---------+-------+--------------+-----------+
Conclusion:   | this function is a       MONSTER           |
-----------------------------------------------------------+
 metric are OUT OF RANGE!


Clone analysis:
This file does not contain cloned functions

____________________________________________


Threshold grass key metrics values at Fri Aug 07 11:28:08 EDT 2009 are:
----------------------+-----------+-----------+-----------+
                      | warning   | middle    | extrem    |
                      | limits    | limits    | limits    |
----------------------+-----------+-----------+-----------+
Complexity (Cyclo):   |         6 |        13 |        21 |
ParamNBR:             |         3 |         6 |         9 |
CalledNBR:            |        10 |        23 |        37 |
LOC:                  |        42 |        91 |       141 |
----------------------+-----------+-----------+-----------+



Measures (see below Web page for details) :
    -Complexity (Cyclo): a complexity index 
    -ParamNBR: number of passed parameters 
    -CalledNBR: number of called functions 
    -LOC: Lines Of Code 
    -Global analysis: based on 21 metrics(the fourth preceding include)

Message interpretation :
    OK : Nothing to say at all
    *  : this is getting close to be out of range, consider revising the code
    ** : this is a baby monster, you should revise this function
    ***: this is a monster, definitely you should revise this function

Conclusion interpretation :
    CORRECT     : if all metrics are situated before warning limits
    WARNING     : if 1 to more metrics are between warning and middle limits
    BABY_MONSTER: if 1 to more metrics are between middle and extreme limits
    MONSTERS    : if 1 to more metrics are in the extreme limits


_______________________________________________
Brought to you by :
	SOftware Cost-effective Change and Evolution Research (SOCCER) laboratory 

Please visite our web site on your project at :
    http://web.soccerlab.polymtl.ca/project-manager/grass-website/index.html


More information about the grass-qa mailing list