Package org.gmetrics.metric.cyclomatic
Class CyclomaticComplexityMetric
java.lang.Object
org.gmetrics.metric.AbstractMetric
org.gmetrics.metric.AbstractMethodMetric
org.gmetrics.metric.cyclomatic.CyclomaticComplexityMetric
- All Implemented Interfaces:
groovy.lang.GroovyObject
,MethodMetric
,Metric
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptioncalculate
(org.codehaus.groovy.ast.expr.ClosureExpression closureExpression, SourceCode sourceCode) calculate
(org.codehaus.groovy.ast.MethodNode methodNode, SourceCode sourceCode) groovy.lang.MetaClass
final String
getName()
getProperty
(String property) invokeMethod
(String method, Object arguments) void
setMetaClass
(groovy.lang.MetaClass mc) void
setProperty
(String property, Object value) Methods inherited from class org.gmetrics.metric.AbstractMethodMetric
applyToClosure, applyToMethod, calculateForClass, getBaseLevel, getIncludeClosureFields, isIncludeClosureFields, lineNumberForMethod, setIncludeClosureFields
Methods inherited from class org.gmetrics.metric.AbstractMetric
applyToClass, applyToPackage, calculateForPackage, createAggregateMetricResult, createAggregateMetricResult, getEnabled, getFunctions, isEnabled, isNotAnInterface, setEnabled, setFunctions
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface org.gmetrics.metric.Metric
applyToClass, applyToPackage, getFunctions, isEnabled
-
Constructor Details
-
CyclomaticComplexityMetric
public CyclomaticComplexityMetric()
-
-
Method Details
-
getMetaClass
public groovy.lang.MetaClass getMetaClass()- Specified by:
getMetaClass
in interfacegroovy.lang.GroovyObject
- Overrides:
getMetaClass
in classAbstractMethodMetric
-
setMetaClass
public void setMetaClass(groovy.lang.MetaClass mc) - Specified by:
setMetaClass
in interfacegroovy.lang.GroovyObject
- Overrides:
setMetaClass
in classAbstractMethodMetric
-
invokeMethod
- Specified by:
invokeMethod
in interfacegroovy.lang.GroovyObject
- Overrides:
invokeMethod
in classAbstractMethodMetric
-
getProperty
- Specified by:
getProperty
in interfacegroovy.lang.GroovyObject
- Overrides:
getProperty
in classAbstractMethodMetric
-
setProperty
- Specified by:
setProperty
in interfacegroovy.lang.GroovyObject
- Overrides:
setProperty
in classAbstractMethodMetric
-
getName
-
calculate
- Specified by:
calculate
in classAbstractMethodMetric
-
calculate
public MetricResult calculate(org.codehaus.groovy.ast.expr.ClosureExpression closureExpression, SourceCode sourceCode) - Specified by:
calculate
in classAbstractMethodMetric
-