|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objecthudson.plugins.serenitec.util.HealthReportBuilder
public class HealthReportBuilder
Creates a health report for integer values based on healthy and unhealthy thresholds.
HealthReport,
Serialized Form| Constructor Summary | |
|---|---|
HealthReportBuilder()
Creates a new dummy instance of HealthReportBuilder. |
|
HealthReportBuilder(boolean isFailureThresholdEnabled,
int severityMax,
boolean isHealthyReportEnabled,
int healthy,
int unHealthy,
java.lang.String reportSingleCount,
java.lang.String reportMultipleCount)
Creates a new instance of HealthReportBuilder. |
|
| Method Summary | |
|---|---|
hudson.model.HealthReport |
computeHealth(int counter)
Computes the healthiness of a build based on the specified counter. |
org.jfree.chart.JFreeChart |
createGraph(boolean useHealthBuilder,
java.lang.String url,
org.jfree.data.category.CategoryDataset dataset,
ToolTipProvider toolTipProvider)
Creates a trend graph for the corresponding action using the thresholds of this health builder. |
org.jfree.chart.JFreeChart |
createGraphLine(boolean useHealthBuilder,
java.lang.String url,
org.jfree.data.category.CategoryDataset dataset,
ToolTipProvider toolTipProvider)
|
int |
getHealthy()
Returns the healthy. |
java.lang.String |
getItemName()
Returns the itemName. |
java.lang.String |
getReportName()
Returns the reportName. |
int |
getThreshold()
Returns the threshold. |
int |
getUnHealthy()
Returns the unHealthy. |
boolean |
isEnabled()
Returns whether this health report build is enabled, i.e. at least one of the health or failed thresholds are provided. |
boolean |
isFailureThresholdEnabled()
Returns the isThresholdEnabled. |
boolean |
isHealthyReportEnabled()
Returns the isHealthyReportEnabled. |
void |
setFailureThresholdEnabled(boolean isFailureThresholdEnabled)
Sets the isThresholdEnabled to the specified value. |
void |
setHealthy(int healthy)
Sets the healthy to the specified value. |
void |
setHealthyReportEnabled(boolean isHealthyReportEnabled)
Sets the isHealthyReportEnabled to the specified value. |
void |
setItemName(java.lang.String itemName)
Sets the itemName to the specified value. |
void |
setReportName(java.lang.String reportName)
Sets the reportName to the specified value. |
void |
setThreshold(int threshold)
Sets the threshold to the specified value. |
void |
setUnHealthy(int unHealthy)
Sets the unHealthy to the specified value. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public HealthReportBuilder()
HealthReportBuilder.
public HealthReportBuilder(boolean isFailureThresholdEnabled,
int severityMax,
boolean isHealthyReportEnabled,
int healthy,
int unHealthy,
java.lang.String reportSingleCount,
java.lang.String reportMultipleCount)
HealthReportBuilder.
isFailureThresholdEnabled - determines whether to use the provided unstable thresholdseverityMax - if this severityMax is exceeded the build will be considered as unstable.isHealthyReportEnabled - determines whether to use the provided healthy thresholds.healthy - report health as 100% when the number of warnings is less than this valueunHealthy - report health as 0% when the number of warnings is greater than this valuereportSingleCount - message to be shown if there is exactly one item foundreportMultipleCount - message to be shown if there are zero or more than one items found| Method Detail |
|---|
public hudson.model.HealthReport computeHealth(int counter)
healthy. Reports a health of 0% when the specified counter is greater than unHealthy.
counter - the number of items in a build
public final int getHealthy()
public final java.lang.String getItemName()
public final java.lang.String getReportName()
public int getThreshold()
public final int getUnHealthy()
public boolean isEnabled()
true if health or failed thresholds are providedpublic boolean isFailureThresholdEnabled()
public final boolean isHealthyReportEnabled()
public void setFailureThresholdEnabled(boolean isFailureThresholdEnabled)
isFailureThresholdEnabled - the value to setpublic final void setHealthy(int healthy)
healthy - the value to setpublic final void setHealthyReportEnabled(boolean isHealthyReportEnabled)
isHealthyReportEnabled - the value to setpublic final void setItemName(java.lang.String itemName)
itemName - the value to setpublic final void setReportName(java.lang.String reportName)
reportName - the value to setpublic void setThreshold(int threshold)
threshold - the value to setpublic final void setUnHealthy(int unHealthy)
unHealthy - the value to set
public org.jfree.chart.JFreeChart createGraph(boolean useHealthBuilder,
java.lang.String url,
org.jfree.data.category.CategoryDataset dataset,
ToolTipProvider toolTipProvider)
useHealthBuilder - if the health thresholds should be used at allurl - the URL shown in the tool tipsdataset - the data set of the values to rendertoolTipProvider - tooltip provider for the clickable map
public org.jfree.chart.JFreeChart createGraphLine(boolean useHealthBuilder,
java.lang.String url,
org.jfree.data.category.CategoryDataset dataset,
ToolTipProvider toolTipProvider)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||