@Test public void compareToShouldReturnPositiveWhenHigherThanComparedValue() { assertThat(_90.compareTo(_75)) .isGreaterThan(0); }
@Override public int compareTo(QuotaThreshold o) { return Double.compare(this.quotaOccupationRatio, o.quotaOccupationRatio); }
QuotaThreshold implements Comparable<QuotaThreshold> { @Override public int compareTo(QuotaThreshold o) { return Double.compare(this.quotaOccupationRatio, o.quotaOccupationRatio); } }
QuotaThreshold implements Comparable<QuotaThreshold> { @Override public int compareTo(QuotaThreshold o) { return Double.compare(this.quotaOccupationRatio, o.quotaOccupationRatio); } QuotaThreshold(double quotaOccupationRatio); }
QuotaThreshold implements Comparable<QuotaThreshold> { @Override public int compareTo(QuotaThreshold o) { return Double.compare(this.quotaOccupationRatio, o.quotaOccupationRatio); } QuotaThreshold(double quotaOccupationRatio); double getQuotaOccupationRatio(); int getQuotaOccupationRatioAsPercent(); boolean isExceeded(Quota<?, ?> quota); Optional<QuotaThreshold> nonZero(); @Override int compareTo(QuotaThreshold o); @Override final boolean equals(Object o); @Override final int hashCode(); @Override String toString(); }
QuotaThreshold implements Comparable<QuotaThreshold> { @Override public int compareTo(QuotaThreshold o) { return Double.compare(this.quotaOccupationRatio, o.quotaOccupationRatio); } QuotaThreshold(double quotaOccupationRatio); double getQuotaOccupationRatio(); int getQuotaOccupationRatioAsPercent(); boolean isExceeded(Quota<?, ?> quota); Optional<QuotaThreshold> nonZero(); @Override int compareTo(QuotaThreshold o); @Override final boolean equals(Object o); @Override final int hashCode(); @Override String toString(); static final QuotaThreshold ZERO; }