java.lang.Object
org.rrd4j.graph.LogService
Utility service for logarithmic scaling operations in RRD graphs. Provides appropriate logarithmic functions based on data ranges and characteristics.
Constructor Summary
ConstructorsMethod Summary
Private MethodsModifier and TypeMethodDescriptionprivate static doublelog10(double v) Compute base-10 logarithm with zero-crossing protectionprivate static doublelog10(double v, double correction, double minval) Compute logarithm for the purposes of y-axis.(package private) static java.util.function.DoubleUnaryOperatorResolve the appropriate logarithmic function for the data range
Constructor Details
LogService
private LogService()Utility class, not intended for instantiation.
Method Details
resolve
Resolve the appropriate logarithmic function for the data range- Parameters:
im- the image parameters whose minimum and maximum define the data range- Returns:
- the operator mapping a value to its log-scaled y-axis position
log10
private static double log10(double v, double correction, double minval) Compute logarithm for the purposes of y-axis.- Parameters:
v- the data value to scalecorrection- multiplicative factor bringing the value into log rangeminval- the axis minimum, mapped to zero- Returns:
- the log-scaled value carrying the sign of v, never negative
log10
private static double log10(double v) Compute base-10 logarithm with zero-crossing protection- Parameters:
v- the data value to scale- Returns:
- the log-scaled value carrying the sign of v, never negative