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
org.apache.myfaces.tobago.renderkit.html.standard.standard.tag 69 199 4897 9 49 331 1447
org.apache.myfaces.tobago.renderkit.html 5 58 430 6 24 15 90
org.apache.myfaces.tobago.renderkit.util 4 34 406 3 11 38 72
org.apache.myfaces.tobago.renderkit.html.util 1 18 200 4 12 6 18
org.apache.myfaces.tobago.renderkit.css 3 15 116 0 0 3 69
Classes total Methods total NCSS total Javadocs Javadoc lines Single lines comment Multi lines comment
82 324 6049 22 96 393 1696

Objects

Objects

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

TOP 30 classes containing the most NCSS.

Object NCSS Methods Classes Javadocs
org.apache.myfaces.tobago.renderkit.html.standard.standard.tag.SheetRenderer 746 20 0 0
org.apache.myfaces.tobago.renderkit.html.standard.standard.tag.SelectManyRendererBase 349 10 2 4
org.apache.myfaces.tobago.renderkit.html.standard.standard.tag.PageRenderer 225 9 0 0
org.apache.myfaces.tobago.renderkit.html.JsonUtils 182 15 0 0
org.apache.myfaces.tobago.renderkit.html.util.HtmlRendererUtils 161 18 0 4
org.apache.myfaces.tobago.renderkit.html.standard.standard.tag.TabGroupRenderer 157 7 0 0
org.apache.myfaces.tobago.renderkit.util.RenderUtils 155 13 0 0
org.apache.myfaces.tobago.renderkit.util.SelectItemUtils 139 2 2 3
org.apache.myfaces.tobago.renderkit.html.standard.standard.tag.CommandRendererBase 106 8 0 1
org.apache.myfaces.tobago.renderkit.html.Command 102 27 0 3
org.apache.myfaces.tobago.renderkit.html.standard.standard.tag.FileRenderer 98 6 0 0
org.apache.myfaces.tobago.renderkit.html.standard.standard.tag.TreeNodeRenderer 97 5 0 0
org.apache.myfaces.tobago.renderkit.html.standard.standard.tag.LabelLayoutRendererBase 96 8 0 1
org.apache.myfaces.tobago.renderkit.html.standard.standard.tag.SelectManyShuttleRenderer 89 3 0 0
org.apache.myfaces.tobago.renderkit.html.standard.standard.tag.TreeListboxRenderer 89 3 0 0
org.apache.myfaces.tobago.renderkit.html.standard.standard.tag.InRenderer 79 4 0 0
org.apache.myfaces.tobago.renderkit.html.standard.standard.tag.SuggestRenderer 76 3 0 0
org.apache.myfaces.tobago.renderkit.html.standard.standard.tag.TreeSelectRenderer 73 4 0 0
org.apache.myfaces.tobago.renderkit.html.standard.standard.tag.TreeRenderer 72 4 0 0
org.apache.myfaces.tobago.renderkit.html.standard.standard.tag.MessagesRenderer 70 2 0 0
org.apache.myfaces.tobago.renderkit.html.standard.standard.tag.SelectOneRadioRenderer 69 2 0 0
org.apache.myfaces.tobago.renderkit.html.standard.standard.tag.GridLayoutRenderer 66 3 0 0
org.apache.myfaces.tobago.renderkit.html.standard.standard.tag.BarRenderer 61 6 0 0
org.apache.myfaces.tobago.renderkit.html.standard.standard.tag.TextareaRenderer 60 2 0 0
org.apache.myfaces.tobago.renderkit.html.standard.standard.tag.SelectManyCheckboxRenderer 59 2 0 0
org.apache.myfaces.tobago.renderkit.html.standard.standard.tag.TreeIconRenderer 59 1 0 0
org.apache.myfaces.tobago.renderkit.css.BootstrapClass 57 9 0 0
org.apache.myfaces.tobago.renderkit.html.AjaxClientBehaviorRenderer 56 5 0 0
org.apache.myfaces.tobago.renderkit.html.standard.standard.tag.SelectBooleanCheckboxRenderer 56 3 0 0
org.apache.myfaces.tobago.renderkit.html.standard.standard.tag.SectionRenderer 47 2 0 0

TOP 30 classes containing the most methods.

Object NCSS Methods Classes Javadocs
org.apache.myfaces.tobago.renderkit.html.Command 102 27 0 3
org.apache.myfaces.tobago.renderkit.html.standard.standard.tag.SheetRenderer 746 20 0 0
org.apache.myfaces.tobago.renderkit.html.util.HtmlRendererUtils 161 18 0 4
org.apache.myfaces.tobago.renderkit.util.HttpPartWrapper 45 17 0 0
org.apache.myfaces.tobago.renderkit.html.JsonUtils 182 15 0 0
org.apache.myfaces.tobago.renderkit.util.RenderUtils 155 13 0 0
org.apache.myfaces.tobago.renderkit.html.standard.standard.tag.SelectManyRendererBase 349 10 2 4
org.apache.myfaces.tobago.renderkit.css.BootstrapClass 57 9 0 0
org.apache.myfaces.tobago.renderkit.html.standard.standard.tag.PageRenderer 225 9 0 0
org.apache.myfaces.tobago.renderkit.html.CommandMap 32 8 0 3
org.apache.myfaces.tobago.renderkit.html.standard.standard.tag.CommandRendererBase 106 8 0 1
org.apache.myfaces.tobago.renderkit.html.standard.standard.tag.LabelLayoutRendererBase 96 8 0 1
org.apache.myfaces.tobago.renderkit.html.standard.standard.tag.TabGroupRenderer 157 7 0 0
org.apache.myfaces.tobago.renderkit.html.standard.standard.tag.BarRenderer 61 6 0 0
org.apache.myfaces.tobago.renderkit.html.standard.standard.tag.FileRenderer 98 6 0 0
org.apache.myfaces.tobago.renderkit.html.standard.standard.tag.SegmentLayoutRenderer 40 6 0 1
org.apache.myfaces.tobago.renderkit.html.AjaxClientBehaviorRenderer 56 5 0 0
org.apache.myfaces.tobago.renderkit.html.standard.standard.tag.TreeNodeRenderer 97 5 0 0
org.apache.myfaces.tobago.renderkit.css.TobagoClass 41 4 0 0
org.apache.myfaces.tobago.renderkit.html.standard.standard.tag.CommandsRenderer 23 4 0 0
org.apache.myfaces.tobago.renderkit.html.standard.standard.tag.InRenderer 79 4 0 0
org.apache.myfaces.tobago.renderkit.html.standard.standard.tag.PanelRendererBase 25 4 0 0
org.apache.myfaces.tobago.renderkit.html.standard.standard.tag.TreeIndentRenderer 36 4 0 0
org.apache.myfaces.tobago.renderkit.html.standard.standard.tag.TreeRenderer 72 4 0 0
org.apache.myfaces.tobago.renderkit.html.standard.standard.tag.TreeSelectRenderer 73 4 0 0
org.apache.myfaces.tobago.renderkit.html.Collapse 11 3 1 0
org.apache.myfaces.tobago.renderkit.html.standard.standard.tag.DateRenderer 38 3 0 0
org.apache.myfaces.tobago.renderkit.html.standard.standard.tag.FlowLayoutRenderer 21 3 0 0
org.apache.myfaces.tobago.renderkit.html.standard.standard.tag.GridLayoutRenderer 66 3 0 0
org.apache.myfaces.tobago.renderkit.html.standard.standard.tag.LabelRenderer 34 3 0 1

Averages.

NCSS average Program NCSS Classes average Methods average Javadocs average
58.07 6,049.00 0.06 3.95 0.27

Methods

Methods

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

TOP 30 Methods containing the most NCSS.

Methods NCSS CCN Javadocs
org.apache.myfaces.tobago.renderkit.html.standard.standard.tag.SheetRenderer.encodeEnd(FacesContext,UIComponent) 330 84 0
org.apache.myfaces.tobago.renderkit.html.standard.standard.tag.SheetRenderer.encodeHeaderRows(FacesContext,UISheet,TobagoResponseWriter,AbstractUIColumnBase) 129 27 0
org.apache.myfaces.tobago.renderkit.html.standard.standard.tag.PageRenderer.encodeBegin(FacesContext,UIComponent) 124 32 0
org.apache.myfaces.tobago.renderkit.html.standard.standard.tag.SelectManyRendererBase.getConvertedUISelectManyValue(FacesContext,UISelectMany,String[],boolean) 80 40 1
org.apache.myfaces.tobago.renderkit.html.standard.standard.tag.SelectManyShuttleRenderer.encodeBeginField(FacesContext,UIComponent) 77 7 0
org.apache.myfaces.tobago.renderkit.html.standard.standard.tag.SelectManyRendererBase.SelectItemsIterator.hasNext() 75 36 0
org.apache.myfaces.tobago.renderkit.html.standard.standard.tag.TabGroupRenderer.encodeHeader(FacesContext,TobagoResponseWriter,UITabGroup,int,SwitchType) 67 22 0
org.apache.myfaces.tobago.renderkit.html.standard.standard.tag.CommandRendererBase.encodeBegin(FacesContext,UIComponent) 65 15 0
org.apache.myfaces.tobago.renderkit.html.standard.standard.tag.SelectOneRadioRenderer.encodeBeginField(FacesContext,UIComponent) 65 11 0
org.apache.myfaces.tobago.renderkit.util.SelectItemUtils.SelectItemsIterator.hasNext() 65 30 0
org.apache.myfaces.tobago.renderkit.html.standard.standard.tag.InRenderer.encodeBeginField(FacesContext,UIComponent) 62 18 0
org.apache.myfaces.tobago.renderkit.html.standard.standard.tag.TreeRenderer.encodeEnd(FacesContext,UIComponent) 60 11 0
org.apache.myfaces.tobago.renderkit.html.standard.standard.tag.SelectManyCheckboxRenderer.encodeBeginField(FacesContext,UIComponent) 55 9 0
org.apache.myfaces.tobago.renderkit.html.standard.standard.tag.TextareaRenderer.encodeBeginField(FacesContext,UIComponent) 55 15 0
org.apache.myfaces.tobago.renderkit.html.standard.standard.tag.TreeIconRenderer.encodeBegin(FacesContext,UIComponent) 55 15 0
org.apache.myfaces.tobago.renderkit.html.standard.standard.tag.TreeListboxRenderer.encodeEnd(FacesContext,UIComponent) 54 7 0
org.apache.myfaces.tobago.renderkit.html.standard.standard.tag.FileRenderer.encodeBeginField(FacesContext,UIComponent) 51 6 0
org.apache.myfaces.tobago.renderkit.html.standard.standard.tag.TreeSelectRenderer.encodeBegin(FacesContext,UIComponent) 49 12 0
org.apache.myfaces.tobago.renderkit.html.util.HtmlRendererUtils.renderSelectItems(UIInput,SelectItem,Object[],String[],Boolean,TobagoResponseWriter,FacesContext) 49 20 0
org.apache.myfaces.tobago.renderkit.html.standard.standard.tag.MessagesRenderer.encodeEnd(FacesContext,UIComponent) 48 10 0
org.apache.myfaces.tobago.renderkit.html.standard.standard.tag.SheetRenderer.encodeDirectPagingLinks(FacesContext,Application,UISheet) 48 26 0
org.apache.myfaces.tobago.renderkit.html.standard.standard.tag.SheetRenderer.encodeBegin(FacesContext,UIComponent) 47 10 0
org.apache.myfaces.tobago.renderkit.util.SelectItemUtils.SelectItemsIterator.next() 43 17 0
org.apache.myfaces.tobago.renderkit.html.JsonUtils.encode(StringBuilder,String,Command) 42 15 0
org.apache.myfaces.tobago.renderkit.html.standard.standard.tag.SectionRenderer.encodeBegin(FacesContext,UIComponent) 42 8 0
org.apache.myfaces.tobago.renderkit.html.standard.standard.tag.SelectBooleanCheckboxRenderer.encodeBeginField(FacesContext,UIComponent) 41 7 0
org.apache.myfaces.tobago.renderkit.html.standard.standard.tag.SuggestRenderer.encodeBegin(FacesContext,UIComponent) 41 11 0
org.apache.myfaces.tobago.renderkit.html.standard.standard.tag.GridLayoutRenderer.encodeChildren(FacesContext,UIComponent) 39 10 0
org.apache.myfaces.tobago.renderkit.html.standard.standard.tag.LabelLayoutRendererBase.encodeBeginSurrounding(FacesContext,UIComponent) 39 15 0
org.apache.myfaces.tobago.renderkit.html.standard.standard.tag.SelectManyRendererBase.SelectItemsIterator.next() 39 16 0

Averages.

Program NCSS NCSS average CCN average Javadocs average
6,049.00 13.52 4.40 0.05

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