public class ResultGauge extends Object implements ComplexCalculationResult
Constructor and Description |
---|
ResultGauge() |
Modifier and Type | Method and Description |
---|---|
void |
addSector(BigDecimal upperBound,
String color)
Add a GaugeSector contained in this Gauge.
|
BigDecimal |
getMax()
The maximum dial value.
|
BigDecimal |
getMin()
The minimum dial value.
|
String |
getPrefix()
The label prefix.
|
String |
getResultType() |
List<Map<String,Object>> |
getSectors() |
String |
getSuffix() |
BigDecimal |
getValue()
The current value on the dial.
|
void |
setMax(BigDecimal maxValue)
The maximum dial value.
|
void |
setMin(BigDecimal minValue)
The minimum dial value.
|
void |
setPrefix(String prefix)
Set the label prefix.
|
void |
setSuffix(String suffix)
The label suffix.
|
void |
setValue(BigDecimal value)
The current value on the dial.
|
public BigDecimal getValue()
public void setValue(BigDecimal value)
value
- the new dial value. Must be between minValue and maxValue. Default value is 0public BigDecimal getMin()
public void setMin(BigDecimal minValue)
minValue
- the new minimum dial value. Must be at least 1 less than the maximum dial value. If minValue
is not at
least 1 less than the maximum value, then it is set to maxValue - 1
.. Default value is 0public BigDecimal getMax()
public void setMax(BigDecimal maxValue)
maxValue
- the new maximum dial value. Must be at least 1 greater than the minimum dial value. If maxValue
is not at
least 1 greater than the minimum value, then it is set to 1 + minValue
.. Default value is 100public void addSector(BigDecimal upperBound, String color)
upperBound
- color
- public String getSuffix()
public void setSuffix(String suffix)
suffix
- the new label suffix.. Default value is "%"public String getPrefix()
public void setPrefix(String prefix)
prefix
- the new label prefix.. Default value is ""public String getResultType()
getResultType
in interface ComplexCalculationResult
Copyright © 2019. All rights reserved.