public class LongDomain extends NumberDomain<Long>
NumberDomain.Range
Constructor and Description |
---|
LongDomain()
Creates a new LongDomain instance.
|
LongDomain(long maxRange)
Creates a new LongDomain instance.
|
LongDomain(long min,
long max)
Creates a new LongDomain instance.
|
LongDomain(NumberDomain.Range range)
Creates a new LongDomain instance.
|
Modifier and Type | Method and Description |
---|---|
protected DataValue<Long> |
dataValueOf(Long value)
Returns a
DataValue for the given value in this domain. |
String |
getFormat()
Returns the format for values that belong to this domain.
|
protected boolean |
isMultipleOf(Long value,
Long multiple)
Returns true if
value is a multiple of multiple . |
void |
setFormat(String format)
Changes the format for values that belong to this domain.
|
void |
setMultipleOf(String multipleOf)
If non-null, all values in this domain are a multiple of the given value.
|
void |
setNotMultipleOfs(String[] notMultipleOfs)
Changes the factors not allowed for any values in this domain.
|
void |
setRange(Long min,
Long max)
Defines the value range for this domain.
|
void |
setRange(NumberDomain.Range range)
Defines the value range for this domain.
|
Stream<DataValue<Long>> |
values(ResolverContext context)
Returns a random sequence of values from this domain.
|
contains, getExcluded, getMax, getMaxRange, getMin, getMultipleOf, getNotMultipleOfs, getTypes, isNotExcluded, isNotMultipleOf, setExcluded, setMultipleOf, setNotMultipleOfs, toString
withFormat
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
arrayOf, arrayOf, arrayOf, contains, containsObject, getType, select, selectValue
public LongDomain()
public LongDomain(long maxRange)
public LongDomain(long min, long max)
public LongDomain(NumberDomain.Range range)
public void setRange(NumberDomain.Range range)
setRange
in class NumberDomain<Long>
public void setRange(Long min, Long max)
setRange
in class NumberDomain<Long>
public void setMultipleOf(String multipleOf)
setMultipleOf
in class NumberDomain<Long>
public void setNotMultipleOfs(String[] notMultipleOfs)
setNotMultipleOfs
in class NumberDomain<Long>
protected boolean isMultipleOf(Long value, Long multiple)
value
is a multiple of multiple
.isMultipleOf
in class NumberDomain<Long>
public Stream<DataValue<Long>> values(ResolverContext context)
public void setFormat(String format)
setFormat
in class AbstractValueDomain<Long>
public String getFormat()
getFormat
in interface ValueDomain<Long>
getFormat
in class AbstractValueDomain<Long>
protected DataValue<Long> dataValueOf(Long value)
DataValue
for the given value in this domain.dataValueOf
in class AbstractValueDomain<Long>
Copyright © 2024 The Cornutum Project. All rights reserved.