Class AbstractCoberturaCoverageMetric

    • Field Detail

      • ROUNDING_MODE

        protected static final int ROUNDING_MODE
      • LOG

        protected static final Object LOG
    • Constructor Detail

      • AbstractCoberturaCoverageMetric

        public AbstractCoberturaCoverageMetric()
    • Method Detail

      • getMetaClass

        public groovy.lang.MetaClass getMetaClass()
        Specified by:
        getMetaClass in interface groovy.lang.GroovyObject
        Overrides:
        getMetaClass in class AbstractMetric
      • setMetaClass

        public void setMetaClass​(groovy.lang.MetaClass mc)
        Specified by:
        setMetaClass in interface groovy.lang.GroovyObject
        Overrides:
        setMetaClass in class AbstractMetric
      • setProperty

        public void setProperty​(String property,
                                Object value)
        Specified by:
        setProperty in interface groovy.lang.GroovyObject
        Overrides:
        setProperty in class AbstractMetric
      • getCoberturaFile

        public String getCoberturaFile()
      • setCoberturaFile

        public void setCoberturaFile​(String value)
      • getAttributeName

        protected abstract String getAttributeName()
      • getCoverageRatioForSingleClass

        protected abstract Ratio getCoverageRatioForSingleClass​(Object matchingClassElement)
      • calculate

        public MetricResult calculate​(org.codehaus.groovy.ast.MethodNode methodNode,
                                      SourceCode sourceCode)
      • getCoverageRatioForClass

        protected Ratio getCoverageRatioForClass​(String className)
      • calculateMethodResult

        protected SingleNumberMetricResult calculateMethodResult​(org.codehaus.groovy.ast.MethodNode methodNode,
                                                                 groovy.util.slurpersupport.GPathResult classXmlElement)
      • findMethodElement

        protected groovy.util.slurpersupport.GPathResult findMethodElement​(org.codehaus.groovy.ast.MethodNode methodNode,
                                                                           groovy.util.slurpersupport.GPathResult classXmlElement)