Topic
  • 8 replies
  • Latest Post - ‏2007-06-13T16:07:31Z by nagkumar
SystemAdmin
SystemAdmin
210 Posts

Pinned topic Additional static analysis tools

‏2006-06-30T19:48:53Z |
In addition to PMD and JavaNCSS, there are other equally interesting tools, which report various complexity related metrics. Check out:

CheckStyle - http://checkstyle.sourceforge.net/ which has a few code size related rules

Eclipse Metrics plug-in - http://metrics.sourceforge.net/ reports size violations

Hammurapi- http://www.hammurapi.biz/hammurapi-biz/ef/xmenu/downloads.html has a wealth of rules too

Also, for more information on PMD, check out Tom Copeland's PMD Applied book at http://pmdapplied.com/
Updated on 2007-06-13T16:07:31Z at 2007-06-13T16:07:31Z by nagkumar
  • SystemAdmin
    SystemAdmin
    210 Posts

    Re: Additional static analysis tools

    ‏2006-07-13T14:03:25Z  
    Hi Andy,

    Usefull list ! I was used to Checkstyle but it allows me to discover more tools.
    Regarding metrics, I'm also using the eclipse plugin called "metrics", which gives me more information (but no rules checking).
    Checkstyle plugin + metrics plugin is imho a good set of tool to start.

    But I'm still looking for an Open Source program calculating essential cyclomatic complexity ev(G) and not only v(g). Of course, It's better if it integrated inside eclipse ;-)
    Does anyone is aware of such a program ?

    Thank you
  • SystemAdmin
    SystemAdmin
    210 Posts

    Re: Additional static analysis tools

    ‏2006-07-14T16:36:40Z  
    Hi Andy,

    Usefull list ! I was used to Checkstyle but it allows me to discover more tools.
    Regarding metrics, I'm also using the eclipse plugin called "metrics", which gives me more information (but no rules checking).
    Checkstyle plugin + metrics plugin is imho a good set of tool to start.

    But I'm still looking for an Open Source program calculating essential cyclomatic complexity ev(G) and not only v(g). Of course, It's better if it integrated inside eclipse ;-)
    Does anyone is aware of such a program ?

    Thank you
    I'm not aware of any open source tools which go beyond calculating normal cyclomatic complexity either! I'm sure, however, that it could be done in PMD (or CheckStyle).
  • SystemAdmin
    SystemAdmin
    210 Posts

    Re: Additional static analysis tools

    ‏2006-07-14T18:06:28Z  
    Hi Andy,

    Usefull list ! I was used to Checkstyle but it allows me to discover more tools.
    Regarding metrics, I'm also using the eclipse plugin called "metrics", which gives me more information (but no rules checking).
    Checkstyle plugin + metrics plugin is imho a good set of tool to start.

    But I'm still looking for an Open Source program calculating essential cyclomatic complexity ev(G) and not only v(g). Of course, It's better if it integrated inside eclipse ;-)
    Does anyone is aware of such a program ?

    Thank you
    Yup, that's been a pending RFE for a while for PMD:

    https://sourceforge.net/tracker/index.php?func=detail&aid=975347&group_id=56262&atid=479924

    Just need to take the time to implement it. As Andy said, shouldn't be too hard, just a matter of buckling down to it.

    Yours,

    Tom
  • SystemAdmin
    SystemAdmin
    210 Posts

    Re: Additional static analysis tools

    ‏2006-07-18T13:59:40Z  
    Yup, that's been a pending RFE for a while for PMD:

    https://sourceforge.net/tracker/index.php?func=detail&aid=975347&group_id=56262&atid=479924

    Just need to take the time to implement it. As Andy said, shouldn't be too hard, just a matter of buckling down to it.

    Yours,

    Tom
    Hi Tom and Andy,

    Thanks for your reply.
    Implementing cyclomatic complexity is pretty straight forward as you can easily based your calculation method on source text. Essential complexity seems more complicated as it involves graph theory. One can not use only a source tree like antlr or bcel library. Am I wrong ? Therefore, whether ev(G) is done, others structural metrics like iv(G) should then be pretty easy to add, isn't it ?

    best regards,
    rv
  • SystemAdmin
    SystemAdmin
    210 Posts

    Re: Additional static analysis tools

    ‏2006-07-18T20:12:31Z  
    Hi Tom and Andy,

    Thanks for your reply.
    Implementing cyclomatic complexity is pretty straight forward as you can easily based your calculation method on source text. Essential complexity seems more complicated as it involves graph theory. One can not use only a source tree like antlr or bcel library. Am I wrong ? Therefore, whether ev(G) is done, others structural metrics like iv(G) should then be pretty easy to add, isn't it ?

    best regards,
    rv
    Hm, that's true. PMD builds a DFA graph, but it's not complete, for example:

    https://sourceforge.net/tracker/index.php?func=detail&aid=1461873&group_id=56262&atid=479921

    Pretty close, though...
  • SystemAdmin
    SystemAdmin
    210 Posts

    Re: Additional static analysis tools

    ‏2007-01-02T14:51:02Z  
    Please also check out TorqueWrench, a static analysis tool for Java: http://www.stackframe.com/TorqueWrench/

    TorqueWrench is developed by my company, StackFrame, LLC, and we would appreciate feedback.
  • SystemAdmin
    SystemAdmin
    210 Posts

    Re: Additional static analysis tools

    ‏2007-01-24T02:54:25Z  
    Please also check out TorqueWrench, a static analysis tool for Java: http://www.stackframe.com/TorqueWrench/

    TorqueWrench is developed by my company, StackFrame, LLC, and we would appreciate feedback.
    Check out Paul Duvall's Automation for the people: Improving code with Eclipse plugins at http://www-128.ibm.com/developerworks/java/library/j-ap01117/index.html for additional tools. Also see this blog entry for a few more plugins: http://www.jacoozi.com/blog/?p=9
  • nagkumar
    nagkumar
    3 Posts

    Re: Additional static analysis tools

    ‏2007-06-13T16:07:31Z  
    Hi

    Try http://www.hello2morrow.com/en/sonarj/sonarj.php. This is not opensource but has a very good cyclometric measurment for the entire project.

    Regards,
    Raja Nagendra Kumar,
    C.T.O
    Competant and Reliable Offshore Code Varification Partners.
    www.tejasoft.com