Skip to content

Commit

Permalink
Add integer based threshold.
Browse files Browse the repository at this point in the history
  • Loading branch information
uhafner committed Jan 4, 2024
1 parent fbe68be commit 96a63ca
Showing 1 changed file with 1 addition and 16 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ public class WarningsQualityGate extends QualityGate {
* the type of the quality gate
*/
@DataBoundConstructor
public WarningsQualityGate(final int threshold, final QualityGateType type) {
public WarningsQualityGate(final double threshold, final QualityGateType type) {
super(threshold);

this.type = type;
Expand All @@ -65,21 +65,6 @@ public WarningsQualityGate(final int threshold, final QualityGateType type,
setCriticality(criticality);
}

public int getIntegerThreshold() {
return Double.valueOf(getThreshold()).intValue();
}

/**
* Sets the threshold of the quality gate.
*
* @param threshold
* the threshold of the quality gate
*/
@DataBoundSetter
public void setIntegerThreshold(final int threshold) {
setThreshold(threshold);
}

/**
* Sets the criticality of the quality gate.
*
Expand Down

0 comments on commit 96a63ca

Please sign in to comment.