public class BigDecimalRangeRandomizer extends Object implements Randomizer<BigDecimal>
BigDecimal
in the given range.Constructor and Description |
---|
BigDecimalRangeRandomizer(Long min,
Long max)
Create a new
BigDecimalRangeRandomizer . |
BigDecimalRangeRandomizer(Long min,
Long max,
Integer scale)
Create a new
BigDecimalRangeRandomizer . |
BigDecimalRangeRandomizer(Long min,
Long max,
long seed)
Create a new
BigDecimalRangeRandomizer . |
Modifier and Type | Method and Description |
---|---|
static BigDecimalRangeRandomizer |
aNewBigDecimalRangeRandomizer(Long min,
Long max)
Create a new
BigDecimalRangeRandomizer . |
static BigDecimalRangeRandomizer |
aNewBigDecimalRangeRandomizer(Long min,
Long max,
Integer scale)
Create a new
BigDecimalRangeRandomizer .The default rounding mode is RoundingMode.HALF_UP . |
static BigDecimalRangeRandomizer |
aNewBigDecimalRangeRandomizer(Long min,
Long max,
long seed)
Create a new
BigDecimalRangeRandomizer . |
BigDecimal |
getRandomValue()
Generate a random value for the given type.
|
public BigDecimalRangeRandomizer(Long min, Long max)
BigDecimalRangeRandomizer
.min
- min valuemax
- max valuepublic BigDecimalRangeRandomizer(Long min, Long max, long seed)
BigDecimalRangeRandomizer
.min
- min valuemax
- max valueseed
- initial seedpublic BigDecimalRangeRandomizer(Long min, Long max, Integer scale)
BigDecimalRangeRandomizer
. The default rounding mode is RoundingMode.HALF_UP
.min
- min valuemax
- max valuescale
- of the BigDecimal
value to be returned.public static BigDecimalRangeRandomizer aNewBigDecimalRangeRandomizer(Long min, Long max)
BigDecimalRangeRandomizer
.min
- min valuemax
- max valueBigDecimalRangeRandomizer
.public static BigDecimalRangeRandomizer aNewBigDecimalRangeRandomizer(Long min, Long max, long seed)
BigDecimalRangeRandomizer
.min
- min valuemax
- max valueseed
- initial seedBigDecimalRangeRandomizer
.public static BigDecimalRangeRandomizer aNewBigDecimalRangeRandomizer(Long min, Long max, Integer scale)
BigDecimalRangeRandomizer
.The default rounding mode is RoundingMode.HALF_UP
.min
- min valuemax
- max valuescale
- of the BigDecimal
value to be returned.BigDecimalRangeRandomizer
.public BigDecimal getRandomValue()
Randomizer
getRandomValue
in interface Randomizer<BigDecimal>
Copyright © 2017. All Rights Reserved.