Package org.jfree.chart.urls
Class TimeSeriesURLGenerator
- java.lang.Object
-
- org.jfree.chart.urls.TimeSeriesURLGenerator
-
- All Implemented Interfaces:
java.io.Serializable,XYURLGenerator
public class TimeSeriesURLGenerator extends java.lang.Object implements XYURLGenerator, java.io.Serializable
A URL generator for time series charts.- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description private java.text.DateFormatdateFormatA formatter for the date.private java.lang.StringitemParameterNameName to use to identify the itemprivate java.lang.StringprefixPrefix to the URLprivate static longserialVersionUIDFor serialization.private java.lang.StringseriesParameterNameName to use to identify the series
-
Constructor Summary
Constructors Constructor Description TimeSeriesURLGenerator()Default constructor.TimeSeriesURLGenerator(java.text.DateFormat dateFormat, java.lang.String prefix, java.lang.String seriesParameterName, java.lang.String itemParameterName)Construct TimeSeriesURLGenerator overriding defaults.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanequals(java.lang.Object obj)Tests this generator for equality with an arbitrary object.java.lang.StringgenerateURL(XYDataset dataset, int series, int item)Generates a URL for a particular item within a series.java.text.DateFormatgetDateFormat()Returns a clone of the date format assigned to this URL generator.java.lang.StringgetItemParameterName()Returns the item parameter name.java.lang.StringgetPrefix()Returns the prefix string.java.lang.StringgetSeriesParameterName()Returns the series parameter name.
-
-
-
Field Detail
-
serialVersionUID
private static final long serialVersionUID
For serialization.- See Also:
- Constant Field Values
-
dateFormat
private java.text.DateFormat dateFormat
A formatter for the date.
-
prefix
private java.lang.String prefix
Prefix to the URL
-
seriesParameterName
private java.lang.String seriesParameterName
Name to use to identify the series
-
itemParameterName
private java.lang.String itemParameterName
Name to use to identify the item
-
-
Constructor Detail
-
TimeSeriesURLGenerator
public TimeSeriesURLGenerator()
Default constructor.
-
TimeSeriesURLGenerator
public TimeSeriesURLGenerator(java.text.DateFormat dateFormat, java.lang.String prefix, java.lang.String seriesParameterName, java.lang.String itemParameterName)Construct TimeSeriesURLGenerator overriding defaults.- Parameters:
dateFormat- a formatter for the date (nullnot permitted).prefix- the prefix of the URL (nullnot permitted).seriesParameterName- the name of the series parameter in the URL (nullnot permitted).itemParameterName- the name of the item parameter in the URL (nullnot permitted).
-
-
Method Detail
-
getDateFormat
public java.text.DateFormat getDateFormat()
Returns a clone of the date format assigned to this URL generator.- Returns:
- The date format (never
null).
-
getPrefix
public java.lang.String getPrefix()
Returns the prefix string.- Returns:
- The prefix string (never
null).
-
getSeriesParameterName
public java.lang.String getSeriesParameterName()
Returns the series parameter name.- Returns:
- The series parameter name (never
null).
-
getItemParameterName
public java.lang.String getItemParameterName()
Returns the item parameter name.- Returns:
- The item parameter name (never
null).
-
generateURL
public java.lang.String generateURL(XYDataset dataset, int series, int item)
Generates a URL for a particular item within a series.- Specified by:
generateURLin interfaceXYURLGenerator- Parameters:
dataset- the dataset (nullnot permitted).series- the series number (zero-based index).item- the item number (zero-based index).- Returns:
- The generated URL.
-
equals
public boolean equals(java.lang.Object obj)
Tests this generator for equality with an arbitrary object.- Overrides:
equalsin classjava.lang.Object- Parameters:
obj- the object (nullpermitted).- Returns:
- A boolean.
-
-