Class StandardXYZItemLabelGenerator

java.lang.Object
org.jfree.chart3d.label.StandardXYZItemLabelGenerator
All Implemented Interfaces:
Serializable, XYZItemLabelGenerator

A default implementation of the XYZItemLabelGenerator interface. The implementation uses a Formatter instance to generate the item labels. Four values are passed to the formatter for possible inclusion in the resulting label: (1) the key for the series, (2) the x-value (3) the y-value and (4) the z-value.

NOTE: This class is serializable, but the serialization format is subject to change in future releases and should not be relied upon for persisting instances of this class.
Since:
1.3
See Also:
  • Field Details

  • Constructor Details

  • Method Details

    • getItemSelection

      Returns the item selection (if this is non-null, labels will only be generated for the items in the selection).
      Returns:
      The item selection (possibly null).
    • setItemSelection

      public void setItemSelection(XYZDataItemSelection selection)
      Sets the item selection, which can be used to specify a subset of the data items that should have item labels generated. If this is set to null then item labels will be generated for all items.
      Parameters:
      selection - the selection (null permitted).
    • generateItemLabel

      public String generateItemLabel(XYZDataset dataset, Comparable<?> seriesKey, int itemIndex)
      Generates a label for the specified data item.
      Specified by:
      generateItemLabel in interface XYZItemLabelGenerator
      Parameters:
      dataset - the dataset (null not permitted).
      seriesKey - the series key (null not permitted).
      itemIndex - the item index.
      Returns:
      The series label (possibly null).
    • equals

      public boolean equals(Object obj)
      Tests this label generator for equality with an arbitrary object.
      Overrides:
      equals in class Object
      Parameters:
      obj - the object (null permitted).
      Returns:
      A boolean.
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object