java.lang.Object
org.rrd4j.graph.TimeAxisSetting

class TimeAxisSettingextends Object
Configuration settings for time axis in RRD graphs. Defines major/minor grid units, label formatting, and time span settings.
  • Field Details

    • secPerPix

      final long secPerPix
      Seconds covered by each pixel of the graph.
    • majorUnit

      final TimeUnit majorUnit
      Interval between major grid lines.
    • majorUnitCount

      final int majorUnitCount
      How many major grid lines to draw.
    • minorUnit

      final TimeUnit minorUnit
      Interval between minor grid lines.
    • minorUnitCount

      final int minorUnitCount
      How many minor grid lines to draw.
    • labelUnit

      final TimeUnit labelUnit
      Interval between axis labels.
    • labelUnitCount

      final int labelUnitCount
      How many axis labels to draw.
    • labelSpan

      final int labelSpan
      How many label units each label spans.
    • format

      final TimeLabelFormat format
      How a label's time is rendered.
  • Constructor Details

    • TimeAxisSetting

      TimeAxisSetting(long secPerPix, TimeUnit minorUnit, int minorUnitCount, TimeUnit majorUnit, int majorUnitCount, TimeUnit labelUnit, int labelUnitCount, int labelSpan, TimeLabelFormat format)
      Configure a time axis.
      Parameters:
      secPerPix - seconds covered by each pixel
      minorUnit - interval between minor grid lines
      minorUnitCount - how many minor grid lines to draw
      majorUnit - interval between major grid lines
      majorUnitCount - how many major grid lines to draw
      labelUnit - interval between axis labels
      labelUnitCount - how many axis labels to draw
      labelSpan - how many label units each label spans
      format - how a label's time is rendered
    • TimeAxisSetting

      TimeAxisSetting(long secPerPix, TimeUnit minorUnit, int minorUnitCount, TimeUnit majorUnit, int majorUnitCount, TimeUnit labelUnit, int labelUnitCount, int labelSpan)
      Configure a time axis with a default label format.
      Parameters:
      secPerPix - seconds covered by each pixel
      minorUnit - interval between minor grid lines
      minorUnitCount - how many minor grid lines to draw
      majorUnit - interval between major grid lines
      majorUnitCount - how many major grid lines to draw
      labelUnit - interval between axis labels
      labelUnitCount - how many axis labels to draw
      labelSpan - how many label units each label spans
    • TimeAxisSetting

      TimeAxisSetting(TimeAxisSetting s)
      Copy another axis configuration.
      Parameters:
      s - the settings to copy
    • TimeAxisSetting

      TimeAxisSetting(int minorUnit, int minorUnitCount, int majorUnit, int majorUnitCount, int labelUnit, int labelUnitCount, int labelSpan, TimeLabelFormat format)
      Configure a time axis from unit counts resolved against the default unit table.
      Parameters:
      minorUnit - minor grid unit index
      minorUnitCount - how many minor grid lines to draw
      majorUnit - major grid unit index
      majorUnitCount - how many major grid lines to draw
      labelUnit - axis label unit index
      labelUnitCount - how many axis labels to draw
      labelSpan - how many label units each label spans
      format - how a label's time is rendered
  • Method Details

    • withLabelFormat

      TimeAxisSetting withLabelFormat(TimeLabelFormat f)
      With label format
      Parameters:
      f - the label format applied to the axis tick labels in the returned copy
      Returns:
      a copy of this setting carrying the given label format