hudson.plugins.findbugs.util
Class BuildResultEvaluator
java.lang.Object
hudson.plugins.findbugs.util.BuildResultEvaluator
public class BuildResultEvaluator
- extends java.lang.Object
Evaluates if the number of annotations exceeds a given threshold value.
- Author:
- Ulli Hafner
|
Method Summary |
hudson.model.Result |
evaluateBuildResult(PluginLogger logger,
Priority minimumPriority,
ParserResult result,
java.lang.String threshold,
java.lang.String failureThreshold,
ParserResult newResult,
java.lang.String newThreshold,
java.lang.String newFailureThreshold)
Evaluates the build result. |
boolean |
isAnnotationCountExceeded(int annotationCount,
java.lang.String annotationThreshold)
Returns whether the new annotation count exceeds the user defined threshold
and the build should be set to unstable. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
BuildResultEvaluator
public BuildResultEvaluator()
evaluateBuildResult
public hudson.model.Result evaluateBuildResult(PluginLogger logger,
Priority minimumPriority,
ParserResult result,
java.lang.String threshold,
java.lang.String failureThreshold,
ParserResult newResult,
java.lang.String newThreshold,
java.lang.String newFailureThreshold)
- Evaluates the build result. The build is marked as unstable if one of the
thresholds has been exceeded.
- Parameters:
logger - logs the resultsminimumPriority - determines which warning priorities should be consideredresult - the result collecting all annotationsthreshold - annotation threshold to be reached if a build should be
considered as unstablefailureThreshold - annotation threshold to be reached if a build should be
considered as failurenewResult - the result collecting the new annotationsnewThreshold - threshold for new annotations to be reached if a build should
be considered as unstablenewFailureThreshold - threshold for new annotations to be reached if a build should
be considered as failure
- Returns:
- the build result
isAnnotationCountExceeded
public boolean isAnnotationCountExceeded(int annotationCount,
java.lang.String annotationThreshold)
- Returns whether the new annotation count exceeds the user defined threshold
and the build should be set to unstable.
- Parameters:
annotationCount - the number of new annotationsannotationThreshold - string representation of the threshold value
- Returns:
true if the build should be set to unstable
Copyright © 2009. All Rights Reserved.