com.jinsight.jetchart
Class PolarSerie

java.lang.Object
  extended bycom.jinsight.jetchart.AbstractSerie
      extended bycom.jinsight.jetchart.PolarSerie
Direct Known Subclasses:
PolarAreaSerie, PolarBubbleSerie, PolarImageSerie, PolarLineSerie, PolarPointSerie

public abstract class PolarSerie
extends AbstractSerie

This class implements the properties common to polar series. Data points of a polar series are plotted on a polar coordinate system, where each data point position is defined in terms of a radius(r) and an angle(theta) formed by the data point position relative to the right horizontal axis of the polar coordinate system, measured counterclockwise.
PolarSerie is extended to implement more specialized series.

See Also:
AbstractSerie, PolarPointSerie, PolarLineSerie, PolarAreaSerie, PolarImageSerie, PolarBubbleSerie

Field Summary
 
Fields inherited from class com.jinsight.jetchart.AbstractSerie
CLIENT_SIDE, SERVER_SIDE_CERN, SERVER_SIDE_NCSA
 
Method Summary
 java.lang.String getSerieMap(java.lang.String[] urls, int type, java.lang.String target)
          Creates a chart image map.
 java.lang.String getTitle()
          Returns the series title.
 void setColor(java.awt.Color color)
          Sets series color.
 void setDataPointLegendColor(java.awt.Color dataPointLegendColor)
          Sets the color of legends displayed above data points.
 void setDataPointLegendFont(java.awt.Font dataPointLegendFont)
          Sets the font of legends displayed above data points.
 void setDataPointLegends(java.lang.String[] dataPointLegends)
          Sets the legends to be displayed above each data point.
 void setMultipleValues(double[][] multipleValues)
          Sets the values of a polar series.
 void setTitle(java.lang.String title)
          Sets series title.
 void setToolTipText(java.lang.String[] toolTipText)
          Sets the texts to prefix values displayed in tooltips.
 void setValuesFormat(java.lang.String[] valuesFormat)
          Sets the format of the x, y and z(polar bubble series) values, displayed in tooltips.
 void setValuesQuery(java.lang.String valuesQuery)
          Sets a sql query string to access a database and get series values.
 
Methods inherited from class com.jinsight.jetchart.AbstractSerie
addMultipleValues, addValue, finalize, getId, getMultipleValues, getValues, setHighlightColor, setHighlightEnabled, setId, setLegendEnabled, setMultipleValues, setSVGURLs, setToolTipContent, setToolTipEnabled, setValueFormat, setValues, setValues
 
Methods inherited from class java.lang.Object
clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

setMultipleValues

public void setMultipleValues(double[][] multipleValues)
Sets the values of a polar series. This method accepts a bidimensional array of double precision numbers containing the values of the data points to be plotted. Each data point of a polar series is associated with two or more values, contained in the subarrays of the bidimensional array previously mentioned. The first and second values of each subarray correspond to the radius(r) and angle(theta) values, respectively.

Overrides:
setMultipleValues in class AbstractSerie
Parameters:
multipleValues - A bidimensional array of double precision numbers.
See Also:
OHLCSerie, ScatterSerie, PolarSerie

setColor

public void setColor(java.awt.Color color)
Sets series color. The series color is Color.lightGray by default.

Parameters:
color - A Color object.

setTitle

public void setTitle(java.lang.String title)
Sets series title. The series title identifies a series, and it is displayed inside the legend box.

Parameters:
title - A String object.
See Also:
Legend

setToolTipText

public void setToolTipText(java.lang.String[] toolTipText)
Sets the texts to prefix values displayed in tooltips. Default prefixes are:
"R:" and "Theta:".

Parameters:
toolTipText - An array of String objects.

setDataPointLegends

public void setDataPointLegends(java.lang.String[] dataPointLegends)
Sets the legends to be displayed above each data point. The legend of a data point is that with the same index of respective value entry in the bidimensional array passed to the method setMultipleValues.

Parameters:
dataPointLegends - An array of strings.
See Also:
setDataPointLegendFont(java.awt.Font), setDataPointLegendColor(java.awt.Color), setMultipleValues(double[][])

setDataPointLegendFont

public void setDataPointLegendFont(java.awt.Font dataPointLegendFont)
Sets the font of legends displayed above data points. Default font is SansSerif,plain,10.

Parameters:
dataPointLegendFont - A Font object.
See Also:
setDataPointLegends(java.lang.String[]), setDataPointLegendColor(java.awt.Color)

setDataPointLegendColor

public void setDataPointLegendColor(java.awt.Color dataPointLegendColor)
Sets the color of legends displayed above data points. Default color is black.

Parameters:
dataPointLegendColor - A Color object.
See Also:
setDataPointLegends(java.lang.String[]), setDataPointLegendFont(java.awt.Font)

getTitle

public java.lang.String getTitle()
Returns the series title.

Returns:
A String object.
See Also:
setTitle(java.lang.String)

getSerieMap

public java.lang.String getSerieMap(java.lang.String[] urls,
                                    int type,
                                    java.lang.String target)
Description copied from class: AbstractSerie
Creates a chart image map. A image map is used in an HTML document to allow regions of an image to be linked to other HTML documents. The web browser will bring up a different document depending on the image map link the user clicks on. The map itself is either a separate file (server-side maps) or part of the HTML document (client-side maps).
A client-side map can be inserted into html text to be returned by a servlet that also generates the chart image.
If the 'urls' parameter is informed, data points coordinates are associated with each element found in the array of urls. If hyperlinks are not required set the 'urls' parameter to null.
The second parameter sets the map format type. Image map can be generated in three different formats. A client-side map and an NCSA server or CERN server formatted map. The client-side map is the most used format.
The third parameter sets a target. The target is the name of an html frame used to display the page associated with the image map. This parameter is only related to client-side image mapping. If a target frame is not required set the 'target' parameter to null.

Specified by:
getSerieMap in class AbstractSerie
Parameters:
urls - An array of strings containing valid urls.
type - An integer representing the format type.
target - A string object.
See Also:
AbstractSerie.CLIENT_SIDE, AbstractSerie.SERVER_SIDE_NCSA, AbstractSerie.SERVER_SIDE_CERN

setValuesFormat

public void setValuesFormat(java.lang.String[] valuesFormat)
Sets the format of the x, y and z(polar bubble series) values, displayed in tooltips. Default format is "#,###,##0.00" for the radius value, "###" for the angle value(theta) and "#,###,##0.00" for the z value(polar bubble series).

Parameters:
valuesFormat - An array of String objects.
See Also:
ToolTip, PolarBubbleSerie

setValuesQuery

public void setValuesQuery(java.lang.String valuesQuery)
Description copied from class: AbstractSerie
Sets a sql query string to access a database and get series values. The query must return a number of columns equal to the number of values associated with a data point, otherwise an exception is raised.

Overrides:
setValuesQuery in class AbstractSerie
Parameters:
valuesQuery - A sql query string.
See Also:
GenericGraph.setDriver(java.lang.String), GenericGraph.setConnection(java.lang.String, java.lang.String, java.lang.String), AbstractSerie.setValues(double[]), AbstractSerie.setMultipleValues(double[][])