org.jacoco.ant
Class ReportTask.CheckFormatterElement

java.lang.Object
  extended by org.jacoco.ant.ReportTask.CheckFormatterElement
All Implemented Interfaces:
org.jacoco.report.check.IViolationsOutput
Enclosing class:
ReportTask

public class ReportTask.CheckFormatterElement
extends Object
implements org.jacoco.report.check.IViolationsOutput

Formatter element for coverage checks.


Constructor Summary
ReportTask.CheckFormatterElement()
           
 
Method Summary
 org.jacoco.report.check.Rule createRule()
          Creates and adds a new rule.
 org.jacoco.report.IReportVisitor createVisitor()
           
 void onViolation(org.jacoco.core.analysis.ICoverageNode node, org.jacoco.report.check.Rule rule, org.jacoco.report.check.Limit limit, String message)
           
 void setFailOnViolation(boolean flag)
          Sets whether the build should fail in case of a violation.
 void setViolationsProperty(String property)
          Sets the name of a property to append the violation messages to.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ReportTask.CheckFormatterElement

public ReportTask.CheckFormatterElement()
Method Detail

createRule

public org.jacoco.report.check.Rule createRule()
Creates and adds a new rule.

Returns:
new rule

setFailOnViolation

public void setFailOnViolation(boolean flag)
Sets whether the build should fail in case of a violation. Default is true.

Parameters:
flag - if true the build fails on violation

setViolationsProperty

public void setViolationsProperty(String property)
Sets the name of a property to append the violation messages to.

Parameters:
property - name of a property

createVisitor

public org.jacoco.report.IReportVisitor createVisitor()
                                               throws IOException
Throws:
IOException

onViolation

public void onViolation(org.jacoco.core.analysis.ICoverageNode node,
                        org.jacoco.report.check.Rule rule,
                        org.jacoco.report.check.Limit limit,
                        String message)
Specified by:
onViolation in interface org.jacoco.report.check.IViolationsOutput


Copyright © 2009–2020 Mountainminds GmbH & Co. KG. All rights reserved.