Class AutoScaledPaintScale
java.lang.Object
org.moeaframework.analysis.plot.style.AutoScaledPaintScale
- All Implemented Interfaces:
org.jfree.chart.renderer.PaintScale
- Direct Known Subclasses:
IndexedPaintScale
,RainbowPaintScale
public abstract class AutoScaledPaintScale
extends Object
implements org.jfree.chart.renderer.PaintScale
Abstract class for defining paint scales that are automatically scaled based on the range of Z values.
-
Constructor Summary
ConstructorsConstructorDescriptionAutoScaledPaintScale
(double lowerBound, double upperBound) Constructs an auto-scaled paint scale with initial bounds. -
Method Summary
Modifier and TypeMethodDescriptiondouble
getPaint
(double value) abstract Paint
getScaledPaint
(double value) Returns the paint for a value scaled by the lower and upper bounds.double
abstract AutoScaledPaintScale
scale
(double lowerBound, double upperBound) Returns a new paint scale with new lower and upper bounds.
-
Constructor Details
-
AutoScaledPaintScale
public AutoScaledPaintScale(double lowerBound, double upperBound) Constructs an auto-scaled paint scale with initial bounds.- Parameters:
lowerBound
- the lower boundupperBound
- the upper bound
-
-
Method Details
-
getLowerBound
public double getLowerBound()- Specified by:
getLowerBound
in interfaceorg.jfree.chart.renderer.PaintScale
-
getUpperBound
public double getUpperBound()- Specified by:
getUpperBound
in interfaceorg.jfree.chart.renderer.PaintScale
-
getScaledPaint
Returns the paint for a value scaled by the lower and upper bounds.- Parameters:
value
- the scaled value, between0.0
and1.0
- Returns:
- the paint
-
scale
Returns a new paint scale with new lower and upper bounds.- Parameters:
lowerBound
- the new lower boundupperBound
- the new upper bound- Returns:
- the new paint scale
-
getPaint
- Specified by:
getPaint
in interfaceorg.jfree.chart.renderer.PaintScale
-