Interface VariableValueParameters.NumberRangeBuilder<T extends Number>
-
- Type Parameters:
T
- TheNumber
type
- All Superinterfaces:
Buildable.Builder<ValueParameter<T>>
,Builder<ValueParameter<T>,VariableValueParameters.NumberRangeBuilder<T>>
,ResettableBuilder<ValueParameter<T>,VariableValueParameters.NumberRangeBuilder<T>>
- Enclosing class:
- VariableValueParameters
public static interface VariableValueParameters.NumberRangeBuilder<T extends Number> extends Builder<ValueParameter<T>,VariableValueParameters.NumberRangeBuilder<T>>
A builder that creates a parameter that can parse a boundedNumber
.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description ValueParameter<T>
build()
Tests for validity and creates thisValueParameter
.VariableValueParameters.NumberRangeBuilder<T>
max(T max)
Sets the maximum value that the parser will parse.VariableValueParameters.NumberRangeBuilder<T>
min(T min)
Sets the minimum value that the parser will parse.
-
-
-
Method Detail
-
min
VariableValueParameters.NumberRangeBuilder<T> min(T min)
Sets the minimum value that the parser will parse.Defaults to the minimum allowable value for
VariableValueParameters.NumberRangeBuilder
- Parameters:
min
- The minimum value- Returns:
- This builder, for chaining
-
max
VariableValueParameters.NumberRangeBuilder<T> max(T max)
Sets the maximum value that the parser will parse.Defaults to the maximum allowable value for
VariableValueParameters.NumberRangeBuilder
- Parameters:
max
- The maximum value- Returns:
- This builder, for chaining
-
build
ValueParameter<T> build()
Tests for validity and creates thisValueParameter
.- Specified by:
build
in interfaceBuildable.Builder<T extends Number>
- Returns:
- The
ValueParameter
- Throws:
IllegalStateException
- if the minimum is greater than the maximum
-
-