org.sonar.javascript.api
Enum EcmaScriptMetric

java.lang.Object
  extended by java.lang.Enum<EcmaScriptMetric>
      extended by org.sonar.javascript.api.EcmaScriptMetric
All Implemented Interfaces:
Serializable, Comparable<EcmaScriptMetric>, org.sonar.squid.measures.MetricDef

public enum EcmaScriptMetric
extends Enum<EcmaScriptMetric>
implements org.sonar.squid.measures.MetricDef


Enum Constant Summary
COMMENT_BLANK_LINES
           
COMMENT_LINES
           
COMPLEXITY
           
FILES
           
FUNCTIONS
           
LINES
           
LINES_OF_CODE
           
STATEMENTS
           
 
Method Summary
 boolean aggregateIfThereIsAlreadyAValue()
           
 org.sonar.squid.measures.CalculatedMetricFormula getCalculatedMetricFormula()
           
 String getName()
           
 boolean isCalculatedMetric()
           
 boolean isThereAggregationFormula()
           
static EcmaScriptMetric valueOf(String name)
          Returns the enum constant of this type with the specified name.
static EcmaScriptMetric[] values()
          Returns an array containing the constants of this enum type, in the order they are declared.
 
Methods inherited from class java.lang.Enum
clone, compareTo, equals, finalize, getDeclaringClass, hashCode, name, ordinal, toString, valueOf
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, wait, wait, wait
 

Enum Constant Detail

FILES

public static final EcmaScriptMetric FILES

LINES

public static final EcmaScriptMetric LINES

LINES_OF_CODE

public static final EcmaScriptMetric LINES_OF_CODE

COMMENT_LINES

public static final EcmaScriptMetric COMMENT_LINES

COMMENT_BLANK_LINES

public static final EcmaScriptMetric COMMENT_BLANK_LINES

STATEMENTS

public static final EcmaScriptMetric STATEMENTS

COMPLEXITY

public static final EcmaScriptMetric COMPLEXITY

FUNCTIONS

public static final EcmaScriptMetric FUNCTIONS
Method Detail

values

public static EcmaScriptMetric[] values()
Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:
for (EcmaScriptMetric c : EcmaScriptMetric.values())
    System.out.println(c);

Returns:
an array containing the constants of this enum type, in the order they are declared

valueOf

public static EcmaScriptMetric valueOf(String name)
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)

Parameters:
name - the name of the enum constant to be returned.
Returns:
the enum constant with the specified name
Throws:
IllegalArgumentException - if this enum type has no constant with the specified name
NullPointerException - if the argument is null

getName

public String getName()
Specified by:
getName in interface org.sonar.squid.measures.MetricDef

isCalculatedMetric

public boolean isCalculatedMetric()
Specified by:
isCalculatedMetric in interface org.sonar.squid.measures.MetricDef

aggregateIfThereIsAlreadyAValue

public boolean aggregateIfThereIsAlreadyAValue()
Specified by:
aggregateIfThereIsAlreadyAValue in interface org.sonar.squid.measures.MetricDef

isThereAggregationFormula

public boolean isThereAggregationFormula()
Specified by:
isThereAggregationFormula in interface org.sonar.squid.measures.MetricDef

getCalculatedMetricFormula

public org.sonar.squid.measures.CalculatedMetricFormula getCalculatedMetricFormula()
Specified by:
getCalculatedMetricFormula in interface org.sonar.squid.measures.MetricDef


Copyright © 2011-2012 Eriks Nukis and SonarSource. All Rights Reserved.