@Test public void testIntegerBounds() { final NumberRange<Integer> range = NumberRange.create(10, 20); assertEquals(10, range.getMinimum( ), 0); assertEquals(10, range.getMinimum(true ), 0); assertEquals( 9, range.getMinimum(false), 0); assertEquals(20, range.getMaximum( ), 0); assertEquals(20, range.getMaximum(true ), 0); assertEquals(21, range.getMaximum(false), 0); }
public static MeasurementRange<Float> create(float minimum, float maximum, Unit<?> units) { return create(minimum, true, maximum, true, units); }
MeasurementRange extends NumberRange<T> { public static MeasurementRange<Float> create(float minimum, float maximum, Unit<?> units) { return create(minimum, true, maximum, true, units); } }
MeasurementRange extends NumberRange<T> { public static MeasurementRange<Float> create(float minimum, float maximum, Unit<?> units) { return create(minimum, true, maximum, true, units); } MeasurementRange(final Class<T> type,
                            final T minimum, final boolean isMinIncluded,
                            final T maximum, final boolean isMaxIncluded,
                            final Unit<?> units);  MeasurementRange(final Range<T> range, final Unit<?> units); private  MeasurementRange(Class<T> type, Range<? extends Number> range, final Unit<?> units); }
MeasurementRange extends NumberRange<T> { public static MeasurementRange<Float> create(float minimum, float maximum, Unit<?> units) { return create(minimum, true, maximum, true, units); } MeasurementRange(final Class<T> type,
                            final T minimum, final boolean isMinIncluded,
                            final T maximum, final boolean isMaxIncluded,
                            final Unit<?> units);  MeasurementRange(final Range<T> range, final Unit<?> units); private  MeasurementRange(Class<T> type, Range<? extends Number> range, final Unit<?> units); static MeasurementRange<Float> create(float minimum, float maximum, Unit<?> units); static MeasurementRange<Float> create(float minimum, boolean isMinIncluded,
                                                 float maximum, boolean isMaxIncluded, Unit<?> units); static MeasurementRange<Double> create(double minimum, double maximum, Unit<?> units); static MeasurementRange<Double> create(double minimum, boolean isMinIncluded,
                                                  double maximum, boolean isMaxIncluded, Unit<?> units); @Override Unit<?> getUnits(); MeasurementRange convertTo(final Unit<?> targetUnits); @Override MeasurementRange<N> castTo(Class<N> type); @Override MeasurementRange union(final Range range); @Override MeasurementRange intersect(final Range range); @Override MeasurementRange[] subtract(final Range range); @Override boolean equals(final Object object); }
MeasurementRange extends NumberRange<T> { public static MeasurementRange<Float> create(float minimum, float maximum, Unit<?> units) { return create(minimum, true, maximum, true, units); } MeasurementRange(final Class<T> type,
                            final T minimum, final boolean isMinIncluded,
                            final T maximum, final boolean isMaxIncluded,
                            final Unit<?> units);  MeasurementRange(final Range<T> range, final Unit<?> units); private  MeasurementRange(Class<T> type, Range<? extends Number> range, final Unit<?> units); static MeasurementRange<Float> create(float minimum, float maximum, Unit<?> units); static MeasurementRange<Float> create(float minimum, boolean isMinIncluded,
                                                 float maximum, boolean isMaxIncluded, Unit<?> units); static MeasurementRange<Double> create(double minimum, double maximum, Unit<?> units); static MeasurementRange<Double> create(double minimum, boolean isMinIncluded,
                                                  double maximum, boolean isMaxIncluded, Unit<?> units); @Override Unit<?> getUnits(); MeasurementRange convertTo(final Unit<?> targetUnits); @Override MeasurementRange<N> castTo(Class<N> type); @Override MeasurementRange union(final Range range); @Override MeasurementRange intersect(final Range range); @Override MeasurementRange[] subtract(final Range range); @Override boolean equals(final Object object);  }