GithubHelp home page GithubHelp logo

1and1 / ckjm Goto Github PK

View Code? Open in Web Editor NEW

This project forked from dspinellis/ckjm

0.0 7.0 0.0 1.66 MB

Chidamber and Kemerer Java Metrics

Home Page: http://www.spinellis.gr/sw/ckjm/

License: Other

HTML 39.87% CSS 3.03% Ruby 9.84% Java 40.35% XSLT 6.91%

ckjm's Introduction

The program ckjm calculates Chidamber and Kemerer object-oriented metrics byprocessing the bytecode of compiled Java files. The program calculates for each class the following six metrics proposed by Chidamber and Kemerer.

  • WMC: Weighted methods per class
  • DIT: Depth of Inheritance Tree
  • NOC: Number of Children
  • CBO: Coupling between object classes
  • RFC: Response for a Class
  • LCOM: Lack of cohesion in methods

In addition it also calculates for each class

  • Ca: Afferent couplings
  • NPM: Number of public methods

This is a fork that adds

  • A Maven driven build because I had some problems with the prior Ant building,
  • Args4j command line options for easier invocation, and
  • CSV output for number crunching with Excel.

Maven build:

 $ mvn clean package

Example call:

 find -iname *.class | java -jar ~/.../target/CKJM-1.10-SNAPSHOT-jar-with-dependencies.jar -i -t CSV > /tmp/project.csv

Command line options:

 -h (--help)                     : Show this help message.
 -i (--use-stdin)                : Read class file names from standard input
                                   instead of adding them in the command line
                                   arguments.
 -j (--include-jdk-classes)      : True if the measurements should include
                                   calls to the Java JDK into account.
 -k (--keep-going)               : Keep going in case of an error (i.e. class
                                   format exception).
 -p (--only-public)              : True if the reports should only include
                                   public classes.
 -t (--type) [XML | CSV | PLAIN] : Output format to use.

If you use this tool in your research, please cite it as follows. Diomidis Spinellis. Tool writing: A forgotten art? IEEE Software, 22(4):9โ€“11, July/August 2005. (doi:10.1109/MS.2005.111).

Visit the original project's home page for more information.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.