Class CartesianLinearTicks

java.lang.Object
org.primefaces.model.charts.axes.cartesian.CartesianTicks
org.primefaces.model.charts.axes.cartesian.linear.CartesianLinearTicks
All Implemented Interfaces:
Serializable

public class CartesianLinearTicks extends CartesianTicks
Used to provide cartesian linear ticks. CartesianLinearTicks extends CartesianTicks
See Also:
  • Constructor Details

    • CartesianLinearTicks

      public CartesianLinearTicks()
  • Method Details

    • getMaxTicksLimit

      public Number getMaxTicksLimit()
      Gets the maxTicksLimit
      Returns:
      maxTicksLimit
    • setMaxTicksLimit

      public void setMaxTicksLimit(Number maxTicksLimit)
      Sets the maxTicksLimit
      Parameters:
      maxTicksLimit - Maximum number of ticks and gridlines to show.
    • getPrecision

      public Number getPrecision()
      If defined and stepSize is not specified, the step size will be rounded to this many decimal places.
      Returns:
      the current precision
    • setPrecision

      public void setPrecision(Number precision)
      If defined and stepSize is not specified, the step size will be rounded to this many decimal places.
      Parameters:
      precision - User defined precision for the scale.
    • getStepSize

      public Number getStepSize()
      Gets the stepSize
      Returns:
      stepSize
    • setStepSize

      public void setStepSize(Number stepSize)
      Sets the stepSize
      Parameters:
      stepSize - User defined fixed step size for the scale.
    • getSource

      public String getSource()
      The ticks.source property controls the ticks generation. 'auto': generates "optimal" ticks based on scale size and time options 'data': generates ticks from data (including labels from data {x|y} objects) 'labels': generates ticks from user given labels ONLY
      Returns:
      the ticks.source
    • setSource

      public void setSource(String source)
      Sets the ticks.source property to control tick generation. 'auto': generates "optimal" ticks based on scale size and time options 'data': generates ticks from data (including labels from data {x|y} objects) 'labels': generates ticks from user given labels ONLY
      Parameters:
      source - the source value
    • encode

      public String encode() throws IOException
      Write the options of cartesian linear ticks
      Overrides:
      encode in class CartesianTicks
      Returns:
      options as JSON object
      Throws:
      IOException - If an I/O error occurs