Get the range @return the range
()
| 130 | * @return the range |
| 131 | */ |
| 132 | private int getRange() |
| 133 | { |
| 134 | int rangeTop = this.stream() |
| 135 | .mapToInt(WeightedDataValue::getWeight) |
| 136 | .sum(); |
| 137 | |
| 138 | if (rangeTop <= 0) |
| 139 | { //the die will nullpointer if it is not at least 1 |
| 140 | rangeTop = 1; |
| 141 | } |
| 142 | |
| 143 | return rangeTop; |
| 144 | } |
| 145 | |
| 146 | /** |
| 147 | * Set the title of the list |