com.jrefinery.chart.tooltips
Class IntervalCategoryToolTipGenerator
java.lang.Object
|
+--com.jrefinery.chart.tooltips.IntervalCategoryToolTipGenerator
- All Implemented Interfaces:
- CategoryToolTipGenerator, ToolTipGenerator
- public class IntervalCategoryToolTipGenerator
- extends java.lang.Object
- implements CategoryToolTipGenerator
A tooltip generator for plots that use data from an IntervalCategoryDataset.
- Author:
- DG
Method Summary |
java.lang.String |
generateToolTip(CategoryDataset data,
int series,
java.lang.Object category)
Generates a tooltip text item for a particular category within a series. |
java.text.DateFormat |
getDateFormat()
Returns the date formatter. |
java.text.NumberFormat |
getNumberFormat()
Returns the number formatter. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
IntervalCategoryToolTipGenerator
public IntervalCategoryToolTipGenerator()
- Creates a new tool tip generator with a default number formatter.
IntervalCategoryToolTipGenerator
public IntervalCategoryToolTipGenerator(java.text.NumberFormat formatter)
- Creates a tool tip generator with the specified number formatter.
- Parameters:
formatter
- the number formatter.
IntervalCategoryToolTipGenerator
public IntervalCategoryToolTipGenerator(java.text.DateFormat formatter)
- Creates a tool tip generator with the specified date formatter.
- Parameters:
formatter
- the date formatter.
getNumberFormat
public java.text.NumberFormat getNumberFormat()
- Returns the number formatter.
- Returns:
- the number formatter.
getDateFormat
public java.text.DateFormat getDateFormat()
- Returns the date formatter.
- Returns:
- the date formatter.
generateToolTip
public java.lang.String generateToolTip(CategoryDataset data,
int series,
java.lang.Object category)
- Generates a tooltip text item for a particular category within a series.
- Specified by:
generateToolTip
in interface CategoryToolTipGenerator
- Parameters:
data
- the dataset.series
- the series number (zero-based index).category
- the category.- Returns:
- the tooltip text or
null
if value is null
.