|
2.17.2: 2011-06-17 | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object net.sf.basedb.core.ParameterType<Float> net.sf.basedb.core.FloatParameterType
public class FloatParameterType
This class represent a parameter type that is a float.
This type defines a lower limit
and an upper limit
for the range of
allowed values.
Field Summary | |
---|---|
private Float |
lowerLimit
The lower limit of the parameter. |
private Float |
upperLimit
The upper limit of the parameter. |
Constructor Summary | |
---|---|
FloatParameterType()
Create a new float parameter type, without any limits and allowing null values. |
|
FloatParameterType(Float lowerLimit,
Float upperLimit,
Float defaultValue,
boolean notNull)
Create a new float parameter type. |
|
FloatParameterType(Float lowerLimit,
Float upperLimit,
Float defaultValue,
boolean notNull,
int multiplicity,
int width,
int height,
List<Float> items)
|
Method Summary | |
---|---|
Float |
getLowerLimit()
Get the lowst valid value of the parameter. |
Float |
getUpperLimit()
Get the highest valid value of the parameter. |
(package private) FloatParameterValueData |
newParameterValueData()
Create a new FloatParameterValueData object. |
String |
toString()
|
(package private) void |
validateValue(String name,
Float value)
Checks if the value is within the range given by the upper and lower limits if those are given. |
Methods inherited from class net.sf.basedb.core.ParameterType |
---|
getDefaultValue, getEnumeration, getHeight, getItems, getMultiplicity, getNotNull, getParameterClass, getValueType, getWidth, isEnumeration, validate, validate |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
private final Float lowerLimit
private final Float upperLimit
Constructor Detail |
---|
public FloatParameterType()
public FloatParameterType(Float lowerLimit, Float upperLimit, Float defaultValue, boolean notNull)
lowerLimit
- The lowest allowed value, or null to have no limitupperLimit
- The highest allowed value, or null to have no limitdefaultValue
- A value to use by default with the parameter.notNull
- FALSE if nulls values are allowed, TRUE otherwisepublic FloatParameterType(Float lowerLimit, Float upperLimit, Float defaultValue, boolean notNull, int multiplicity, int width, int height, List<Float> items)
Method Detail |
---|
public String toString()
toString
in class Object
void validateValue(String name, Float value) throws InvalidDataException
validateValue
in class ParameterType<Float>
value
- The value to testname
- The name of the parameter, use the name if there is need to
throw an exception
InvalidDataException
- If the value is outside
the range of allowed valuesFloatParameterValueData newParameterValueData()
FloatParameterValueData
object.
newParameterValueData
in class ParameterType<Float>
public Float getLowerLimit()
public Float getUpperLimit()
|
2.17.2: 2011-06-17 | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |