net.sourceforge.cobertura.ant

Class CheckTask

public class CheckTask extends MatchingTask

An ant task that can be used to optionally fail an ant build if the coverage percentage for lines or branches is below a certain, user specifiable threshold.
Field Summary
StringbranchRate
StringdataFile
StringfailureProperty
booleanhaltOnFailure
Javajava
StringlineRate
StringpackageBranchRate
StringpackageLineRate
Setregexes
StringtotalBranchRate
StringtotalLineRate
Method Summary
PathcreateClasspath()
RegexcreateRegex()
voidexecute()
protected JavagetJava()
voidsetBranchRate(String branchRate)
voidsetClasspath(Path classpath)
voidsetClasspathRef(Reference r)
voidsetDataFile(String dataFile)
voidsetFailureProperty(String failureProperty)
voidsetHaltOnFailure(boolean haltOnFailure)
voidsetLineRate(String lineRate)
voidsetPackageBranchRate(String packageBranchRate)
voidsetPackageLineRate(String packageLineRate)
voidsetTotalBranchRate(String totalBranchRate)
voidsetTotalLineRate(String totalLineRate)

Field Detail

branchRate

private String branchRate

dataFile

private String dataFile

failureProperty

private String failureProperty

haltOnFailure

private boolean haltOnFailure

java

private Java java

lineRate

private String lineRate

packageBranchRate

private String packageBranchRate

packageLineRate

private String packageLineRate

regexes

final Set regexes

totalBranchRate

private String totalBranchRate

totalLineRate

private String totalLineRate

Method Detail

createClasspath

public Path createClasspath()

createRegex

public Regex createRegex()

execute

public void execute()

getJava

protected Java getJava()

setBranchRate

public void setBranchRate(String branchRate)

setClasspath

public void setClasspath(Path classpath)

setClasspathRef

public void setClasspathRef(Reference r)

setDataFile

public void setDataFile(String dataFile)

setFailureProperty

public void setFailureProperty(String failureProperty)

setHaltOnFailure

public void setHaltOnFailure(boolean haltOnFailure)

setLineRate

public void setLineRate(String lineRate)

setPackageBranchRate

public void setPackageBranchRate(String packageBranchRate)

setPackageLineRate

public void setPackageLineRate(String packageLineRate)

setTotalBranchRate

public void setTotalBranchRate(String totalBranchRate)

setTotalLineRate

public void setTotalLineRate(String totalLineRate)