public class LongParameterType extends ParameterType<java.lang.Long>
lower limit
and an upper limit
for the range of
allowed values.Modifier and Type | Field and Description |
---|---|
private java.lang.Long |
lowerLimit
The lower limit of the parameter.
|
private java.lang.Long |
upperLimit
The upper limit of the parameter.
|
Constructor and Description |
---|
LongParameterType()
Create a new long parameter type, without any limits and allowing null
values.
|
LongParameterType(java.lang.Long lowerLimit,
java.lang.Long upperLimit,
java.lang.Long defaultValue,
boolean notNull)
Create a new long parameter type.
|
LongParameterType(java.lang.Long lowerLimit,
java.lang.Long upperLimit,
java.lang.Long defaultValue,
boolean notNull,
int multiplicity,
int width,
int height,
java.util.List<java.lang.Long> items) |
Modifier and Type | Method and Description |
---|---|
java.lang.Long |
getLowerLimit()
Get the lowest valid value of the parameter.
|
java.lang.Long |
getUpperLimit()
Get the highest valid value of the parameter.
|
(package private) LongParameterValueData |
newParameterValueData()
Create a new
LongParameterValueData object. |
java.lang.String |
toString() |
(package private) void |
validateValue(java.lang.String name,
java.lang.Long value)
Checks if the value is within the range given by the upper and lower
limits if those are given.
|
getDefaultValue, getEnumeration, getHeight, getItems, getMultiplicity, getNotNull, getParameterClass, getValueType, getWidth, isEnumeration, isMasked, validate, validate
private final java.lang.Long lowerLimit
private final java.lang.Long upperLimit
public LongParameterType()
public LongParameterType(java.lang.Long lowerLimit, java.lang.Long upperLimit, java.lang.Long defaultValue, boolean notNull)
lowerLimit
- The lowest allowed value, or null to have no limitupperLimit
- The highest allowed value, or null to have no limitdefaultValue
- Default value for the parameter.notNull
- FALSE if nulls values are allowed, TRUE otherwisepublic LongParameterType(java.lang.Long lowerLimit, java.lang.Long upperLimit, java.lang.Long defaultValue, boolean notNull, int multiplicity, int width, int height, java.util.List<java.lang.Long> items)
public java.lang.String toString()
toString
in class java.lang.Object
void validateValue(java.lang.String name, java.lang.Long value) throws InvalidDataException
validateValue
in class ParameterType<java.lang.Long>
value
- The value to testname
- The name of the parameter, use the name if there is need to
throw an exceptionInvalidDataException
- If the value is outside the range of allowed valuesLongParameterValueData newParameterValueData()
LongParameterValueData
object.newParameterValueData
in class ParameterType<java.lang.Long>
public java.lang.Long getLowerLimit()
public java.lang.Long getUpperLimit()