| Modifier and Type | Field and Description |
|---|---|
protected double |
max |
protected double |
min |
| Constructor and Description |
|---|
DataRange()
Creates a new
DataRange that is not defined. |
DataRange(DataRange range)
Creates a copy of the specified data range.
|
DataRange(double min,
double max)
Creates a new
DataRange with the specified min
and max values. |
| Modifier and Type | Method and Description |
|---|---|
void |
add(DataRange range)
Add the specified data range to this range.
|
boolean |
add(double value)
Adds value to this range.
|
boolean |
add(double[] values)
Adds values to this range.
|
boolean |
add(double[] values,
int max)
Adds values to this range.
|
Object |
clone() |
boolean |
contains(double value)
Examines if this range contains the specified value.
|
void |
empty()
Empties this DataRange.
|
boolean |
equals(Object obj) |
void |
expand(double value)
Expands this data set by the given value.
|
double |
getLength()
Returns length of this range (max - min).
|
double |
getMax() |
double |
getMin() |
int |
hashCode() |
boolean |
isDefined()
Determines if this DataRange is defined -
min and
max values are defined. |
boolean |
isMaxDefined()
Determines if
max value has been defined. |
boolean |
isMinDefined()
Determines if
min value has been defined. |
void |
set(DataRange range)
Sets updates range to the specified one.
|
void |
set(double min,
double max)
Sets
min and max values for this range. |
void |
setMax(double max)
Sets
max value for this range. |
void |
setMin(double min)
Sets
min value for this range. |
DataRange |
substract(DataRange range)
Substracts the specified data range from this range.
|
String |
toString() |
public DataRange()
DataRange that is not defined.isDefined()public DataRange(double min,
double max)
DataRange with the specified min
and max values.min - the new min valuemax - the new max valuepublic DataRange(DataRange range)
range - other DataRange objectpublic boolean isDefined()
min and
max values are defined.public boolean isMinDefined()
min value has been defined.public boolean isMaxDefined()
max value has been defined.public double getMax()
public void setMax(double max)
max value for this range.max - the new max valuepublic double getMin()
public void setMin(double min)
min value for this range.min - the new data range minimumpublic void set(DataRange range)
range - other DataRange objectpublic void set(double min,
double max)
min and max values for this range.min - new minimum of the rangemax - new maximum of the rangepublic double getLength()
public boolean add(double value)
value - value to be addedtrue if the value becomes min or
max.public boolean add(double[] values)
values - values to be addedtrue if the value becomes min or
max.public boolean add(double[] values,
int max)
values - values to be addedmax - the maximum array length that should be taken into accounttrue if the value becomes min or
max.public void add(DataRange range)
range - other DataRangepublic DataRange substract(DataRange range)
range - other DataRangepublic void expand(double value)
value - range to expand topublic void empty()
isDefined()public boolean contains(double value)
value - to be testedpublic Object clone() throws CloneNotSupportedException
clone in class ObjectCloneNotSupportedExceptionCopyright © 2019 GSI Helmholtzzentrum für Schwerionenforschung GmbH. All rights reserved.