|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectmaspack.widgets.SliderRange
public class SliderRange
Constructor Summary | |
---|---|
SliderRange()
|
Method Summary | |
---|---|
static DoubleInterval |
estimateBoundsIfNecessary(NumericInterval range0,
double x)
Estimates the range for a slider, given an initial range range0 and an initial value x (assumed to be
within that range). |
static DoubleInterval |
roundBoundsTo125(NumericInterval range0)
Rounds the upper and lower bounds of a supplied range to conform to |
static double |
roundDown125(double x)
Rounds a number x down to the nearest value defined by |
static double |
roundUp125(double x)
Rounds a number x up to the nearest value defined by |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public SliderRange()
Method Detail |
---|
public static double roundUp125(double x)
sgn(x) k 10^nwhere n is an integer and k is 1, 2, or 5.
x
- number to round up
public static double roundDown125(double x)
sgn(x) k 10^nwhere n is an integer and k is 1, 2, or 5.
x
- number to round down
public static DoubleInterval estimateBoundsIfNecessary(NumericInterval range0, double x)
range0
and an initial value x
(assumed to be
within that range). Any finite bounds specified by range0
are preserved. In particular, if range0
is completely
bounded, the method simply returns a copy the range. Otherwise, if
either the upper or lower endpoints of the range are unbounded, the
method attempts to determine reasonable values for these, based on
x
.
range0
- initial range valuex
- initial value to help determine bounds if necessary
public static DoubleInterval roundBoundsTo125(NumericInterval range0)
+/- k 10^nwhere n is an integer and k is 1, 2 or 5.
range0
- range to be rounded
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |