Class LinearScale
java.lang.Object
cz.fidentis.analyst.gui.elements.histogram.scales.FunctionScale
cz.fidentis.analyst.gui.elements.histogram.scales.LinearScale
Class for performing linear scaling of values.
-
Constructor Summary
ConstructorsConstructorDescriptionCreates a new instance.LinearScale
(Double minZoom, Double maxZoom) Creates a new instance with limitations on zooming. -
Method Summary
Modifier and TypeMethodDescriptioncreateInverseMapFunction
(double domainStart, double domainEnd, double rangeStart, double rangeEnd) Creates an inverse map function based on two points - (domainStart, rangeStart) and (domainEnd, rangeEnd).createMapFunction
(double domainStart, double domainEnd, double rangeStart, double rangeEnd) Creates a map function based on two points - (domainStart, rangeStart) and (domainEnd, rangeEnd).Methods inherited from class cz.fidentis.analyst.gui.elements.histogram.scales.FunctionScale
getDomainEnd, getDomainSize, getDomainStart, getMaxZoom, getMinZoom, getRangeEnd, getRangeSize, getRangeStart, getRawRangeEnd, getRawRangeSize, getRawRangeStart, getZoom, inverseMap, map, rangeIncrementZoom, rangePan, rangeZoomReset, setDomain, setRange, setScaling, setZoom
-
Constructor Details
-
LinearScale
public LinearScale()Creates a new instance. -
LinearScale
Creates a new instance with limitations on zooming.- Parameters:
minZoom
- minimal zoom levelmaxZoom
- maximal zoom level
-
-
Method Details
-
createMapFunction
protected Function<Double,Double> createMapFunction(double domainStart, double domainEnd, double rangeStart, double rangeEnd) Description copied from class:FunctionScale
Creates a map function based on two points - (domainStart, rangeStart) and (domainEnd, rangeEnd).- Specified by:
createMapFunction
in classFunctionScale
- Parameters:
domainStart
- domain startdomainEnd
- domain endrangeStart
- range startrangeEnd
- range end- Returns:
- mapping function
-
createInverseMapFunction
protected Function<Double,Double> createInverseMapFunction(double domainStart, double domainEnd, double rangeStart, double rangeEnd) Description copied from class:FunctionScale
Creates an inverse map function based on two points - (domainStart, rangeStart) and (domainEnd, rangeEnd).- Specified by:
createInverseMapFunction
in classFunctionScale
- Parameters:
domainStart
- domain startdomainEnd
- domain endrangeStart
- range startrangeEnd
- range end- Returns:
- inverse mapping function
-