public class AggregatedRange extends Object implements Range<Double>
PROPERTY_MAX, PROPERTY_MIN
Constructor and Description |
---|
AggregatedRange()
Create an empty range
|
AggregatedRange(Collection<Positionable> positions)
Create a range from the supplied Positionable instances
|
Modifier and Type | Method and Description |
---|---|
void |
addPropertyChangeListener(PropertyChangeListener propertyChangeListener)
Not supported in this class
|
void |
adjust(Double lower,
Double upper)
Not supported in this class
|
boolean |
contains(Double item)
Returns a boolean to indicate whether the supplied Double lies within this range
|
int |
getCount()
The number of points being combined in this range
|
int |
getNegativeCount() |
double |
getNegativeSum()
Computes the sum of all the negative Positionables
|
int |
getPositiveCount() |
double |
getPositiveSum()
Computes the sum of all the positive Positionables
|
Double |
lower()
The lower value of the range; for this class it is the same as minimum()
|
double |
maximum()
Returns the maximum (numeric) value in the range
|
double |
minimum()
Returns the minimum (numeric) value in the range
|
void |
removePropertyChangeListener(PropertyChangeListener propertyChangeListener)
Not supported in this class
|
double |
size()
The size of the range, computed as the difference between the maximum and the minimum
|
Double |
upper()
The upper value of the range; for this class it is the same as maximum()
|
public AggregatedRange()
public AggregatedRange(Collection<Positionable> positions)
positions
- the instances of the Positionable interfacepublic Double lower()
public Double upper()
public int getCount()
public double getPositiveSum()
public int getPositiveCount()
public double getNegativeSum()
public int getNegativeCount()
public double minimum()
public double maximum()
public double size()
public boolean contains(Double item)
public void addPropertyChangeListener(PropertyChangeListener propertyChangeListener)
addPropertyChangeListener
in interface Range<Double>
propertyChangeListener
- the new property change listenerpublic void removePropertyChangeListener(PropertyChangeListener propertyChangeListener)
removePropertyChangeListener
in interface Range<Double>
propertyChangeListener
- the PropertyChangeListener
to remove