JavaNCSS Metric Results

[ package ] [ object ] [ method ] [ explanation ]

The following document contains the results of a JavaNCSS metric analysis.
JavaNCSS web site.

Packages

[ package ] [ object ] [ method ] [ explanation ]

Packages sorted by NCSS.

PackageClassesMethodsNCSSJavadocsJavadoc linesSingle lines commentMulti lines comment
org.fosstrak.reader.rp.proxy.msg.stubs.serializers.text1322617276226214948
org.fosstrak.reader.rp.proxy.msg106015233919417200
org.fosstrak.reader.rp.proxy.msg.stubs.serializers.xml1221912755924715930
org.fosstrak.reader.rp.proxy.configurator23108627947861651029
org.fosstrak.reader.rp.proxy151804416131721723
org.fosstrak.reader.rp.proxy.msg.stubs9123276263380758
org.fosstrak.reader.rp.proxy.msg.stubs.serializers12161202301430661
org.fosstrak.reader.rp.proxy.invocationHandlers161547421021
org.fosstrak.reader.rp.proxy.factories916152241603172
org.fosstrak.reader.rp.proxy.util161187681512
Classes totalMethods totalNCSS totalJavadocsJavadoc linesSingle lines commentMulti lines comment
1051105649540925572605454

Objects

[ package ] [ object ] [ method ] [ explanation ]

TOP 30 classes containing the most NCSS.

ObjectNCSSMethodsClassesJavadocs
org.fosstrak.reader.rp.proxy.msg.CommandFactory118212013
org.fosstrak.reader.rp.proxy.msg.stubs.serializers.text.ReaderDeviceSerializerImpl3585105
org.fosstrak.reader.rp.proxy.msg.stubs.serializers.text.SourceSerializerImpl3164505
org.fosstrak.reader.rp.proxy.msg.stubs.serializers.xml.SourceSerializerImpl3104505
org.fosstrak.reader.rp.proxy.msg.stubs.serializers.text.TextTokens264001
org.fosstrak.reader.rp.proxy.msg.stubs.serializers.xml.ReaderDeviceSerializerImpl2625105
org.fosstrak.reader.rp.proxy.configurator.ReaderConfigurator167708
org.fosstrak.reader.rp.proxy.msg.stubs.serializers.text.NotificationChannelSerializerImpl1602405
org.fosstrak.reader.rp.proxy.invocationHandlers.ProxyInvocationHandler141607
org.fosstrak.reader.rp.proxy.msg.stubs.serializers.text.CommandSerializerImpl13927014
org.fosstrak.reader.rp.proxy.msg.stubs.serializers.xml.NotificationChannelSerializerImpl1312405
org.fosstrak.reader.rp.proxy.Result12415016
org.fosstrak.reader.rp.proxy.msg.stubs.serializers.text.DataSelectorSerializerImpl1191802
org.fosstrak.reader.rp.proxy.util.ResourceLocator113607
org.fosstrak.reader.rp.proxy.msg.stubs.serializers.xml.CommandSerializerImpl11220012
org.fosstrak.reader.rp.proxy.msg.stubs.serializers.xml.DataSelectorSerializerImpl1081802
org.fosstrak.reader.rp.proxy.msg.stubs.serializers.text.TagFieldSerializerImpl921505
org.fosstrak.reader.rp.proxy.msg.stubs.Source704303
org.fosstrak.reader.rp.proxy.msg.stubs.serializers.text.TagSelectorSerializerImpl661204
org.fosstrak.reader.rp.proxy.msg.stubs.serializers.xml.TagFieldSerializerImpl661505
org.fosstrak.reader.rp.proxy.msg.ClientConnection621116
org.fosstrak.reader.rp.proxy.msg.ProxyConnection61607
org.fosstrak.reader.rp.proxy.msg.stubs.serializers.text.TriggerSerializerImpl601104
org.fosstrak.reader.rp.proxy.NotificationChannelEndPoint60708
org.fosstrak.reader.rp.proxy.msg.Parameter551103
org.fosstrak.reader.rp.proxy.configurator.NotificationChannelConfiguration5316218
org.fosstrak.reader.rp.proxy.msg.stubs.serializers.xml.TagSelectorSerializerImpl501204
org.fosstrak.reader.rp.proxy.msg.stubs.serializers.ReaderDeviceSerializer484706
org.fosstrak.reader.rp.proxy.ReaderDevice474600
org.fosstrak.reader.rp.proxy.msg.stubs.serializers.xml.TriggerSerializerImpl441104

TOP 30 classes containing the most methods.

ObjectNCSSMethodsClassesJavadocs
org.fosstrak.reader.rp.proxy.msg.stubs.serializers.text.ReaderDeviceSerializerImpl3585105
org.fosstrak.reader.rp.proxy.msg.stubs.serializers.xml.ReaderDeviceSerializerImpl2625105
org.fosstrak.reader.rp.proxy.msg.stubs.serializers.ReaderDeviceSerializer484706
org.fosstrak.reader.rp.proxy.ReaderDevice474600
org.fosstrak.reader.rp.proxy.msg.stubs.serializers.text.SourceSerializerImpl3164505
org.fosstrak.reader.rp.proxy.msg.stubs.serializers.xml.SourceSerializerImpl3104505
org.fosstrak.reader.rp.proxy.msg.stubs.Source704303
org.fosstrak.reader.rp.proxy.msg.stubs.serializers.SourceSerializer424102
org.fosstrak.reader.rp.proxy.Source424103
org.fosstrak.reader.rp.proxy.msg.stubs.serializers.text.CommandSerializerImpl13927014
org.fosstrak.reader.rp.proxy.msg.stubs.serializers.text.NotificationChannelSerializerImpl1602405
org.fosstrak.reader.rp.proxy.msg.stubs.serializers.xml.NotificationChannelSerializerImpl1312405
org.fosstrak.reader.rp.proxy.msg.stubs.NotificationChannel402103
org.fosstrak.reader.rp.proxy.configurator.ObjectFactory4020020
org.fosstrak.reader.rp.proxy.msg.stubs.serializers.NotificationChannelSerializer212001
org.fosstrak.reader.rp.proxy.msg.stubs.serializers.xml.CommandSerializerImpl11220012
org.fosstrak.reader.rp.proxy.NotificationChannel201904
org.fosstrak.reader.rp.proxy.msg.stubs.serializers.text.DataSelectorSerializerImpl1191802
org.fosstrak.reader.rp.proxy.msg.stubs.serializers.xml.DataSelectorSerializerImpl1081802
org.fosstrak.reader.rp.proxy.configurator.NotificationChannelConfiguration5316218
org.fosstrak.reader.rp.proxy.msg.stubs.DataSelector281603
org.fosstrak.reader.rp.proxy.msg.stubs.serializers.DataSelectorSerializer161502
org.fosstrak.reader.rp.proxy.msg.stubs.serializers.text.TagFieldSerializerImpl921505
org.fosstrak.reader.rp.proxy.msg.stubs.serializers.xml.TagFieldSerializerImpl661505
org.fosstrak.reader.rp.proxy.Result12415016
org.fosstrak.reader.rp.proxy.DataSelector151402
org.fosstrak.reader.rp.proxy.msg.CommandFactory118212013
org.fosstrak.reader.rp.proxy.msg.stubs.serializers.text.TagSelectorSerializerImpl661204
org.fosstrak.reader.rp.proxy.msg.stubs.serializers.xml.TagSelectorSerializerImpl501204
org.fosstrak.reader.rp.proxy.msg.stubs.TagField251203

Averages.

NCSS averageProgram NCSSClasses averageMethods averageJavadocs average
56.286,495.000.0610.523.90

Methods

[ package ] [ object ] [ method ] [ explanation ]

TOP 30 Methods containing the most NCSS.

MethodsNCSSCCNJavadocs
org.fosstrak.reader.rp.proxy.msg.CommandFactory.getXMLCommand(String,String,Parameter[],String)5323231
org.fosstrak.reader.rp.proxy.msg.CommandFactory.getTextCommand(String,String,Parameter[],String)5323231
org.fosstrak.reader.rp.proxy.invocationHandlers.ProxyInvocationHandler.invoke(Object,Method,Object[])98471
org.fosstrak.reader.rp.proxy.configurator.ReaderConfigurator.createTrigger(Object)4491
org.fosstrak.reader.rp.proxy.configurator.ReaderConfigurator.createNotificationChannel(NotificationChannelConfiguration)3281
org.fosstrak.reader.rp.proxy.util.ResourceLocator.locateDefault(String,String,Class)31101
org.fosstrak.reader.rp.proxy.configurator.ReaderConfigurator.createDataSelector(DataSelectorConfiguration)29101
org.fosstrak.reader.rp.proxy.util.ResourceLocator.getURL(String,String,Class)28131
org.fosstrak.reader.rp.proxy.msg.stubs.serializers.xml.SourceSerializerImpl.write(TagFieldValue[],String[],TagSelector[])2550
org.fosstrak.reader.rp.proxy.msg.stubs.serializers.xml.SourceSerializerImpl.read(DataSelector,Hashtable)2450
org.fosstrak.reader.rp.proxy.configurator.ReaderConfigurator.initReaderDeviceConfiguration(String)23121
org.fosstrak.reader.rp.proxy.msg.Parameter.setParameter(String,ParameterType)2190
org.fosstrak.reader.rp.proxy.msg.ProxyConnection.executeCommand(String,String,Class[],Object[],String,boolean)20101
org.fosstrak.reader.rp.proxy.Result.processHttpHeaderFragment(String)2071
org.fosstrak.reader.rp.proxy.msg.TcpClientConnection.sendHandshake()1980
org.fosstrak.reader.rp.proxy.configurator.ReaderConfigurator.getReaderDevice(ReaderConfiguration)1831
org.fosstrak.reader.rp.proxy.msg.stubs.serializers.xml.SourceSerializerImpl.writeID(String,String[],TagSelector[])1830
org.fosstrak.reader.rp.proxy.invocationHandlers.ProxyInvocationHandler.createObjectForInterface(Class,String)17101
org.fosstrak.reader.rp.proxy.msg.ProxyConnection.connect()1781
org.fosstrak.reader.rp.proxy.msg.stubs.serializers.text.CommandSerializerImpl.serializeCommand()1771
org.fosstrak.reader.rp.proxy.msg.stubs.serializers.xml.SourceSerializerImpl.kill(String[],TagSelector[])1730
org.fosstrak.reader.rp.proxy.NotificationChannelEndPoint.run()1681
org.fosstrak.reader.rp.proxy.msg.ClientConnection.connect()1550
org.fosstrak.reader.rp.proxy.msg.stubs.serializers.xml.CommandSerializerImpl.serializeCommand()1571
org.fosstrak.reader.rp.proxy.util.ResourceLocator.getBestClassLoader(Class)1551
org.fosstrak.reader.rp.proxy.msg.CommandFactory.toTagFieldValueArray(Collection)1441
org.fosstrak.reader.rp.proxy.util.ResourceLocator.locate(String,ClassLoader,Class)1481
org.fosstrak.reader.rp.proxy.msg.CommandFactory.serializeCommand(Command)1371
org.fosstrak.reader.rp.proxy.msg.CommandFactory.toSourceArray(Collection)1241
org.fosstrak.reader.rp.proxy.msg.CommandFactory.toDataSelectorArray(Collection)1241

Averages.

Program NCSSNCSS averageCCN averageJavadocs average
6,495.004.842.090.31

Explanations

[ package ] [ object ] [ method ] [ explanation ]

Non Commenting Source Statements (NCSS)

Statements for JavaNCSS are not statements as specified in the Java Language Specification but include all kinds of declarations too. Roughly spoken, NCSS is approximately equivalent to counting ';' and '{' characters in Java source files.

Not counted are empty statements, empty blocks or semicolons after closing brackets. Of course, comments don't get counted too. Closing brackets also never get counted, the same applies to blocks in general.

Examples
Package declarationpackage java.lang;
Import declarationimport java.awt.*;
Class declaration
  • public class Foo {
  • public class Foo extends Bla {
Interface declarationpublic interface Able ; {
Field declaration
  • int a;
  • int a, b, c = 5, d = 6;
Method declaration
  • public void cry();
  • public void gib() throws DeadException {
Constructor declarationpublic Foo() {
Constructor invocation
  • this();
  • super();
Statement declaration
  • i = 0;
  • if (ok)
  • if (exit) {
  • if (3 == 4);
  • if (4 == 4) { ;
  • } else {
Label declarationfine :
In some cases consecutive semicolons are illegal according to the JLS but JavaNCSS still tolerates them (thought JavaNCSS is still more strict as 'javac'). Nevertheless they are never counted as two statements.Cyclomatic Complexity Number (CCN)CCN is also know as McCabe Metric. There exists a much hyped theory behind it based on graph theory, but it all comes down to simply counting 'if', 'for', 'while' statements etc. in a method. Whenever the control flow of a method splits, the "CCN counter" gets incremented by one.Each method has a minimum value of 1 per default. For each of the following Java keywords/statements this value gets incremented by one:
  • if
  • for
  • while
  • case
  • catch
Also if the control flow of a method returns abortively the CCNvalue will be incremented by one:
  • if
  • for
An ordinary return at the end of method will not be counted.Note that 'else', 'default', and 'finally' don't increment the CCN value any further. On the other hand, a simple method with a 'switch' statement and a huge block of 'case' statements can have a surprisingly high CCN value (still it has the same value when converting a 'switch' block to an equivalent sequence of 'if' statements).