Fork me on GitHub

JavaNCSS Metric Results

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

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

Packages

Packages

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

Packages sorted by NCSS.

Package Classes Methods NCSS Javadocs Javadoc lines Single lines comment Multi lines comment
fr.paris.lutece.plugins.deployment.util 10 74 1013 28 204 41 348
fr.paris.lutece.plugins.deployment.business 27 263 1000 33 191 15 958
fr.paris.lutece.plugins.deployment.service 19 100 762 21 115 51 704
fr.paris.lutece.plugins.deployment.web 2 36 709 19 169 19 69
fr.paris.lutece.plugins.deployment.util.vcs 6 38 390 2 6 35 108
fr.paris.lutece.plugins.deployment.service.vcs 5 27 171 6 57 26 184
fr.paris.lutece.plugins.deployment.uploadhandler 2 9 87 5 24 16 67
fr.paris.lutece.plugins.deployment.business.vcs 4 11 34 0 0 0 132
Classes total Methods total NCSS total Javadocs Javadoc lines Single lines comment Multi lines comment
75 558 4166 114 766 203 2570

Objects

Objects

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

TOP 30 classes containing the most NCSS.

Object NCSS Methods Classes Javadocs
fr.paris.lutece.plugins.deployment.web.DeploymentJspBean 597 34 0 16
fr.paris.lutece.plugins.deployment.util.DeploymentUtils 330 44 0 13
fr.paris.lutece.plugins.deployment.util.ConstanteUtils 244 0 0 0
fr.paris.lutece.plugins.deployment.util.vcs.GitUtils 189 17 0 0
fr.paris.lutece.plugins.deployment.business.WorkflowDeploySiteContext 107 40 0 4
fr.paris.lutece.plugins.deployment.service.WorkflowDeploySiteService 88 9 0 0
fr.paris.lutece.plugins.deployment.util.FTPUtils 87 4 0 0
fr.paris.lutece.plugins.deployment.business.ApplicationDAO 86 6 0 1
fr.paris.lutece.plugins.deployment.util.ReleaseUtils 85 9 0 4
fr.paris.lutece.plugins.deployment.service.ApplicationResourceIdService 71 4 0 5
fr.paris.lutece.plugins.deployment.util.vcs.SVNUtils 70 5 3 2
fr.paris.lutece.plugins.deployment.service.MavenService 68 9 1 3
fr.paris.lutece.plugins.deployment.business.ServerApplicationInstance 67 25 0 0
fr.paris.lutece.plugins.deployment.service.ServerApplicationService 64 7 0 0
fr.paris.lutece.plugins.deployment.service.EnvironmentService 64 7 0 0
fr.paris.lutece.plugins.deployment.service.vcs.SvnService 63 11 0 0
fr.paris.lutece.plugins.deployment.uploadhandler.DeploymentUploadHandler 61 7 0 2
fr.paris.lutece.plugins.deployment.util.RepositoryUtils 55 2 1 3
fr.paris.lutece.plugins.deployment.service.ActionService 54 7 0 0
fr.paris.lutece.plugins.deployment.business.Action 51 20 0 0
fr.paris.lutece.plugins.deployment.business.Application 48 19 0 7
fr.paris.lutece.plugins.deployment.business.FtpInfo 46 18 0 0
fr.paris.lutece.plugins.deployment.business.CommandResult 43 13 0 9
fr.paris.lutece.plugins.deployment.service.vcs.AbstractGitService 42 7 0 0
fr.paris.lutece.plugins.deployment.business.ExecuteAction 38 1 0 1
fr.paris.lutece.plugins.deployment.business.InitMysqlDatabase 37 3 0 0
fr.paris.lutece.plugins.deployment.business.DumpAction 35 3 0 1
fr.paris.lutece.plugins.deployment.service.DatabaseService 33 2 0 1
fr.paris.lutece.plugins.deployment.business.SiteDeploy 30 12 0 0
fr.paris.lutece.plugins.deployment.util.FileUtil 30 4 0 0

TOP 30 classes containing the most methods.

Object NCSS Methods Classes Javadocs
fr.paris.lutece.plugins.deployment.util.DeploymentUtils 330 44 0 13
fr.paris.lutece.plugins.deployment.business.WorkflowDeploySiteContext 107 40 0 4
fr.paris.lutece.plugins.deployment.web.DeploymentJspBean 597 34 0 16
fr.paris.lutece.plugins.deployment.business.ServerApplicationInstance 67 25 0 0
fr.paris.lutece.plugins.deployment.business.IAction 24 23 0 0
fr.paris.lutece.plugins.deployment.business.Action 51 20 0 0
fr.paris.lutece.plugins.deployment.business.Application 48 19 0 7
fr.paris.lutece.plugins.deployment.business.FtpInfo 46 18 0 0
fr.paris.lutece.plugins.deployment.util.vcs.GitUtils 189 17 0 0
fr.paris.lutece.plugins.deployment.business.CommandResult 43 13 0 9
fr.paris.lutece.plugins.deployment.business.SiteDeploy 30 12 0 0
fr.paris.lutece.plugins.deployment.service.vcs.SvnService 63 11 0 0
fr.paris.lutece.plugins.deployment.business.SiteTag 25 10 0 0
fr.paris.lutece.plugins.deployment.business.ManageApplicationAction 26 10 0 0
fr.paris.lutece.plugins.deployment.business.FilterDeployment 22 9 0 4
fr.paris.lutece.plugins.deployment.service.WorkflowDeploySiteService 88 9 0 0
fr.paris.lutece.plugins.deployment.service.ApplicationService 29 9 0 1
fr.paris.lutece.plugins.deployment.service.MavenService 68 9 1 3
fr.paris.lutece.plugins.deployment.util.ReleaseUtils 85 9 0 4
fr.paris.lutece.plugins.deployment.business.Environment 21 8 0 0
fr.paris.lutece.plugins.deployment.business.FormDeploySiteDTO 21 8 0 0
fr.paris.lutece.plugins.deployment.business.ISite 9 8 0 0
fr.paris.lutece.plugins.deployment.service.IWorkflowDeploySiteService 9 8 0 0
fr.paris.lutece.plugins.deployment.util.vcs.GitSearchRepoItem 21 8 0 0
fr.paris.lutece.plugins.deployment.service.ActionService 54 7 0 0
fr.paris.lutece.plugins.deployment.service.ServerApplicationService 64 7 0 0
fr.paris.lutece.plugins.deployment.service.IApplicationService 8 7 0 1
fr.paris.lutece.plugins.deployment.service.EnvironmentService 64 7 0 0
fr.paris.lutece.plugins.deployment.service.vcs.AbstractGitService 42 7 0 0
fr.paris.lutece.plugins.deployment.service.vcs.IVCSService 8 7 0 6

Averages.

NCSS average Program NCSS Classes average Methods average Javadocs average
45.81 4,166.00 0.07 7.44 1.52

Methods

Methods

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

TOP 30 Methods containing the most NCSS.

Methods NCSS CCN Javadocs
fr.paris.lutece.plugins.deployment.web.DeploymentJspBean.getFormDeployApplication(HttpServletRequest) 70 28 0
fr.paris.lutece.plugins.deployment.web.DeploymentJspBean.getFormDeployData(HttpServletRequest,WorkflowDeploySiteContext) 65 27 0
fr.paris.lutece.plugins.deployment.service.ApplicationResourceIdService.register() 41 2 1
fr.paris.lutece.plugins.deployment.business.ExecuteAction.run(Application,ServerApplicationInstance,CommandResult,ActionParameter) 37 13 0
fr.paris.lutece.plugins.deployment.util.vcs.SVNUtils.doSvnCheckoutSite(String,String,String,ReleaseSVNCheckoutClient,CommandResult) 37 8 0
fr.paris.lutece.plugins.deployment.web.DeploymentJspBean.getViewApplication(HttpServletRequest) 36 10 0
fr.paris.lutece.plugins.deployment.web.DeploymentJspBean.getProcessDeployApplication(HttpServletRequest) 34 17 0
fr.paris.lutece.plugins.deployment.web.DeploymentJspBean.doRunActionServer(HttpServletRequest) 34 6 0
fr.paris.lutece.plugins.deployment.business.ApplicationDAO.findByFilter(FilterDeployment,Plugin) 31 6 0
fr.paris.lutece.plugins.deployment.util.vcs.GitUtils.cloneOrReturnGit(String,String,CommandResult,GitUser,String,String) 30 9 0
fr.paris.lutece.plugins.deployment.web.DeploymentJspBean.getManageApplication(HttpServletRequest) 30 6 0
fr.paris.lutece.plugins.deployment.web.DeploymentJspBean.getApplicationData(HttpServletRequest,Application) 30 9 1
fr.paris.lutece.plugins.deployment.util.RepositoryUtils.checkRepository(Application) 29 10 1
fr.paris.lutece.plugins.deployment.util.DeploymentUtils.getActionParameters(WorkflowDeploySiteContext) 29 8 0
fr.paris.lutece.plugins.deployment.service.MavenService.mvn(String,String,String,CommandResult) 28 4 1
fr.paris.lutece.plugins.deployment.util.FTPUtils.uploadFile(String,InputStream,FtpInfo,String,CommandResult,boolean) 28 10 0
fr.paris.lutece.plugins.deployment.business.WarInstallerAction.run(Application,ServerApplicationInstance,CommandResult,ActionParameter) 27 10 0
fr.paris.lutece.plugins.deployment.service.EnvironmentService.getListEnvironments(String,Locale) 27 9 0
fr.paris.lutece.plugins.deployment.web.DeploymentJspBean.doDeployApplication(HttpServletRequest) 27 9 0
fr.paris.lutece.plugins.deployment.util.FTPUtils.getFile(OutputStream,FtpInfo,String,CommandResult) 26 9 0
fr.paris.lutece.plugins.deployment.util.DeploymentUtils.getJSONForCommandResult(CommandResult) 26 6 0
fr.paris.lutece.plugins.deployment.util.FTPUtils.getFtpClient(FtpInfo) 25 10 0
fr.paris.lutece.plugins.deployment.business.InitMysqlDatabase.run(Application,ServerApplicationInstance,CommandResult,ActionParameter) 23 5 0
fr.paris.lutece.plugins.deployment.util.DeploymentUtils.getSvnUser(int,Locale) 23 6 0
fr.paris.lutece.plugins.deployment.util.vcs.GitUtils.getTagLinkedToLastRelease(Git) 23 7 0
fr.paris.lutece.plugins.deployment.web.DeploymentJspBean.getFormActionServer(HttpServletRequest) 23 3 1
fr.paris.lutece.plugins.deployment.business.DumpAction.run(Application,ServerApplicationInstance,CommandResult,ActionParameter) 22 9 0
fr.paris.lutece.plugins.deployment.util.DeploymentUtils.getJSONForServerAction(int,String,String,String,String,CommandResult,IAction,Integer) 22 9 0
fr.paris.lutece.plugins.deployment.util.ReleaseUtils.updateReleaseVersion(String,String,String,SVNCommitClient) 21 6 0
fr.paris.lutece.plugins.deployment.util.DeploymentUtils.getJSONForWorkflowAction(String,String,CommandResult,State,Action) 20 9 0

Averages.

Program NCSS NCSS average CCN average Javadocs average
4,166.00 5.12 2.03 0.18

Explanations

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 declaration package java.lang;
Import declaration import java.awt.*;
Class declaration
  • public class Foo {
  • public class Foo extends Bla {
Interface declaration public interface Able ; {
Field declaration
  • int a;
  • int a, b, c = 5, d = 6;
Method declaration
  • public void cry();
  • public void gib() throws DeadException {
Constructor declaration public Foo() {
Constructor invocation
  • this();
  • super();
Statement declaration
  • i = 0;
  • if (ok)
  • if (exit) {
  • if (3 == 4);
  • if (4 == 4) { ;
  • } else {
Label declaration fine :

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