public class BigIntegerValueRange extends AbstractCountableValueRange<BigInteger>
Constructor and Description |
---|
BigIntegerValueRange(BigInteger from,
BigInteger to) |
BigIntegerValueRange(BigInteger from,
BigInteger to,
BigInteger incrementUnit) |
Modifier and Type | Method and Description |
---|---|
boolean |
contains(BigInteger value) |
Iterator<BigInteger> |
createOriginalIterator()
Select the elements in original (natural) order.
|
Iterator<BigInteger> |
createRandomIterator(Random workingRandom)
Select in random order, but without shuffling the elements.
|
BigInteger |
get(long index)
Used by uniform random selection in a composite or nullable CountableValueRange.
|
long |
getSize()
Used by uniform random selection in a composite or nullable CountableValueRange.
|
String |
toString() |
isEmpty
public BigIntegerValueRange(BigInteger from, BigInteger to)
from
- never null, inclusive minimumto
- never null, exclusive maximum, >= from
public BigIntegerValueRange(BigInteger from, BigInteger to, BigInteger incrementUnit)
from
- never null, inclusive minimumto
- never null, exclusive maximum, >= from
incrementUnit
- never null, > 0
public long getSize()
CountableValueRange
CountableValueRange
, always >= 0
public BigInteger get(long index)
CountableValueRange
index
- always <
CountableValueRange.getSize()
PlanningVariable.nullable()
is true)public boolean contains(BigInteger value)
value
- sometimes nullpublic Iterator<BigInteger> createOriginalIterator()
CountableValueRange
public Iterator<BigInteger> createRandomIterator(Random workingRandom)
ValueRange
workingRandom
- never null, the Random
to use when any random number is needed,
so EnvironmentMode.REPRODUCIBLE
works correctly. RandomUtils
can be useful too.Copyright © 2006–2020 JBoss by Red Hat. All rights reserved.