java.lang.Object
org.rrd4j.graph.Axis
org.rrd4j.graph.ValueAxisLogarithmic
All Implemented Interfaces:
RrdGraphConstants

class ValueAxisLogarithmicextends Axis
Represents logarithmic value axis (y-axis) in RRD graphs. Handles logarithmic scaling with appropriate grid lines and labels for log-scale graphs.
  • Field Details

    • yloglab

      private static final double[][] yloglab
      The table of logarithmic axis labels.
    • im

      private final ImageParameters im
      The image parameters being built.
    • worker

      private final ImageWorker worker
      The worker drawing the image.
    • gdef

      private final RrdGraphDef gdef
      The definition of the graph.
    • fontHeight

      private final int fontHeight
      Height of the font, in pixels.
    • mapper

      private final Mapper mapper
      The mapper between values and pixels.
    • locale

      private final Locale locale
      The locale for formatting the labels.
  • Constructor Details

    • ValueAxisLogarithmic

      ValueAxisLogarithmic(RrdGraph rrdGraph, ImageWorker worker, Locale locale)
      Create a logarithmic axis for a graph that has already been rendered.
      Parameters:
      rrdGraph - the already-rendered graph supplying the image parameters and font to scale
      worker - the image worker that measures the axis font height and paints the axis
      locale - the locale used to format tick labels and decimal separators
    • ValueAxisLogarithmic

      ValueAxisLogarithmic(RrdGraphGenerator rrdGraph, ImageWorker worker, Locale locale)
      Create a logarithmic axis using the generator's mapper, before rendering begins.
      Parameters:
      rrdGraph - the graph generator supplying the mapper and image parameters
      worker - the image worker that measures the axis font height and paints the axis
      locale - the locale used to format tick labels and decimal separators
  • Method Details

    • findStart

      private double findStart(double positive, int idx)
      Finds the start value of the log scale.
      Parameters:
      positive - the positive reference value
      idx - the index in the label table
      Returns:
      the start value of the scale
    • draw

      boolean draw()
      True if axis labels were drawn.
      Specified by:
      draw in class Axis
      Returns:
      true if labels were drawn, false for a range under 1e-10