JavaNCSS Metric Results

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

The following document contains the results of a JavaNCSS metric analysis, using JavaNCSS version 32.53.
JavaNCSS web site.

Packages

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

Packages sorted by NCSS.

PackageClassesMethodsNCSSJavadocsJavadoc linesSingle lines commentMulti lines comment
de.fub.mi.idenpa.shared131109389156718470
de.fub.mi.idenpa.generated27125458146132816851
de.fub.mi.idenpa.shared.storage1055188593010277
de.fub.mi.idenpa.shared.storage.exception2525735058
de.fub.mi.idenpa.shared.exception139419328
Classes totalMethods totalNCSS totalJavadocsJavadoc linesSingle lines commentMulti lines comment
5329816183072250189884

Objects

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

TOP 30 classes containing the most NCSS.

ObjectNCSSMethodsClassesJavadocs
de.fub.mi.idenpa.shared.Utils24825025
de.fub.mi.idenpa.shared.ProofSpecParser23216437
de.fub.mi.idenpa.shared.RedirectContext15917017
de.fub.mi.idenpa.shared.E_IdemixEidAttrib751100
de.fub.mi.idenpa.shared.E_IdemixVeAttrib681000
de.fub.mi.idenpa.shared.storage.CredentialInstance6512011
de.fub.mi.idenpa.generated.ObjectFactory5025026
de.fub.mi.idenpa.shared.ProofSpecParser.InequalityDetail50302
de.fub.mi.idenpa.generated.IssueMessageType3112013
de.fub.mi.idenpa.shared.storage.ProofInstance31807
de.fub.mi.idenpa.shared.EidResult30809
de.fub.mi.idenpa.shared.storage.AbstractStorageObject2811010
de.fub.mi.idenpa.shared.ProofSpecParser.AttributeDetail24605
de.fub.mi.idenpa.generated.IssueInitialRequestType21809
de.fub.mi.idenpa.generated.IdemixServiceMessage21809
de.fub.mi.idenpa.generated.IdemixDataType21809
de.fub.mi.idenpa.generated.ProveMessageType21809
de.fub.mi.idenpa.shared.ErrorCodeResolver20102
de.fub.mi.idenpa.shared.ProofSpecParser.VencDetail20505
de.fub.mi.idenpa.generated.VerifyMessageType16607
de.fub.mi.idenpa.generated.RevokeMessageType16607
de.fub.mi.idenpa.shared.E_HttpParam15400
de.fub.mi.idenpa.shared.ProofSpecParser.CertificateDetail12404
de.fub.mi.idenpa.generated.IssueDataRequestType11405
de.fub.mi.idenpa.generated.StatusType11405
de.fub.mi.idenpa.generated.IssueDataResponseType11405
de.fub.mi.idenpa.generated.ProveRequestType11405
de.fub.mi.idenpa.generated.IdemixArtefactType11405
de.fub.mi.idenpa.generated.RevokeRequestType11405
de.fub.mi.idenpa.shared.storage.exception.StorageInitializationException11203

TOP 30 classes containing the most methods.

ObjectNCSSMethodsClassesJavadocs
de.fub.mi.idenpa.generated.ObjectFactory5025026
de.fub.mi.idenpa.shared.Utils24825025
de.fub.mi.idenpa.shared.RedirectContext15917017
de.fub.mi.idenpa.shared.ProofSpecParser23216437
de.fub.mi.idenpa.generated.IssueMessageType3112013
de.fub.mi.idenpa.shared.storage.CredentialInstance6512011
de.fub.mi.idenpa.shared.E_IdemixEidAttrib751100
de.fub.mi.idenpa.shared.storage.AbstractStorageObject2811010
de.fub.mi.idenpa.shared.E_IdemixVeAttrib681000
de.fub.mi.idenpa.generated.IssueInitialRequestType21809
de.fub.mi.idenpa.generated.IdemixServiceMessage21809
de.fub.mi.idenpa.generated.IdemixDataType21809
de.fub.mi.idenpa.generated.ProveMessageType21809
de.fub.mi.idenpa.shared.storage.ProofInstance31807
de.fub.mi.idenpa.shared.EidResult30809
de.fub.mi.idenpa.generated.VerifyMessageType16607
de.fub.mi.idenpa.generated.RevokeMessageType16607
de.fub.mi.idenpa.shared.storage.I_CredentialStorage7607
de.fub.mi.idenpa.shared.ProofSpecParser.AttributeDetail24605
de.fub.mi.idenpa.shared.storage.I_SecureClientStorage6506
de.fub.mi.idenpa.shared.ProofSpecParser.VencDetail20505
de.fub.mi.idenpa.generated.IssueDataRequestType11405
de.fub.mi.idenpa.generated.StatusType11405
de.fub.mi.idenpa.generated.IssueDataResponseType11405
de.fub.mi.idenpa.generated.ProveRequestType11405
de.fub.mi.idenpa.generated.IdemixArtefactType11405
de.fub.mi.idenpa.generated.RevokeRequestType11405
de.fub.mi.idenpa.shared.storage.I_ProofStorage5405
de.fub.mi.idenpa.shared.storage.I_MasterSecretStorage5405
de.fub.mi.idenpa.shared.ProofSpecParser.CertificateDetail12404

Averages.

NCSS averageProgram NCSSClasses averageMethods averageJavadocs average
27.681,618.000.085.626.09

Methods

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

TOP 30 Methods containing the most NCSS.

MethodsNCSSCCNJavadocs
de.fub.mi.idenpa.shared.ProofSpecParser.parse()65221
de.fub.mi.idenpa.shared.RedirectContext.parse(int,String,URI,HttpServletRequest)30121
de.fub.mi.idenpa.shared.RedirectContext.getHtmlAttributes(String,String,String,String)24111
de.fub.mi.idenpa.shared.Utils.unmarshalEncList(String)2061
de.fub.mi.idenpa.shared.E_IdemixEidAttrib.getBigint(Object)1990
de.fub.mi.idenpa.shared.E_IdemixVeAttrib.getBigint(Object)1990
de.fub.mi.idenpa.shared.Utils.unmarshalAttrList(String)1861
de.fub.mi.idenpa.shared.Utils.checkInput(IdemixDataType,IdemixDataType,boolean)18101
de.fub.mi.idenpa.shared.RedirectContext.parse(HttpServletRequest)1861
de.fub.mi.idenpa.shared.ProofSpecParser.InequalityDetail.toString()1870
de.fub.mi.idenpa.shared.Utils.unmarshal(String)1641
de.fub.mi.idenpa.shared.ProofSpecParser.InequalityDetail.toString(InequalityOperator)1651
de.fub.mi.idenpa.shared.Utils.marshalAttrList(BigInteger)1531
de.fub.mi.idenpa.shared.Utils.writeFile(File,String)1451
de.fub.mi.idenpa.shared.Utils.getRedirect(String,String)1351
de.fub.mi.idenpa.shared.RedirectContext.redirect(HttpServletRequest,HttpServletResponse)1351
de.fub.mi.idenpa.shared.ProofSpecParser.ProofSpecParser(ProofSpec,I_CredentialStorage,String)1311
de.fub.mi.idenpa.shared.E_IdemixEidAttrib.toString(BigInteger)1250
de.fub.mi.idenpa.shared.E_IdemixEidAttrib.parseValue(String)1250
de.fub.mi.idenpa.shared.storage.CredentialInstance.getAttributeValues()1241
de.fub.mi.idenpa.shared.storage.CredentialInstance.getValue(String)1241
de.fub.mi.idenpa.shared.E_IdemixVeAttrib.parseValue(String)1250
de.fub.mi.idenpa.shared.E_IdemixVeAttrib.toString(BigInteger)1250
de.fub.mi.idenpa.shared.Utils.stream2Str(ServletInputStream)1141
de.fub.mi.idenpa.shared.Utils.getChild(String,String)1141
de.fub.mi.idenpa.shared.RedirectContext.getHtmlAttribute(String,String,String)1151
de.fub.mi.idenpa.shared.RedirectContext.getParams(HttpServletRequest)1141
de.fub.mi.idenpa.shared.Utils.marshal(IdemixDataType)1021
de.fub.mi.idenpa.shared.Utils.getRedirect(IdemixDataType,String)1031
de.fub.mi.idenpa.shared.Utils.initResponseError(IdemixDataType,ErrorCodeType)931

Averages.

Program NCSSNCSS averageCCN averageJavadocs average
1,618.003.921.650.87

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).