com.googlecode.charts4j
Interface Plot

All Known Subinterfaces:
BarChartPlot, com.googlecode.charts4j.Curve, Line, com.googlecode.charts4j.LinePlot, RadarPlot, ScatterPlotData, XYLine

public interface Plot

Top level plot interface. All plots can be annotated with Markers.

Author:
Julien Chastang (julien.c.chastang at gmail dot com)

Method Summary
 void addMarker(Marker marker, int index)
          Add a Marker.
 void addMarkers(Marker marker)
          Add a Marker to each point on a plot.
 void addShapeMarker(Shape shape, Color color, int size, int index)
          Add a shape marker to a point.
 void addShapeMarkers(Shape shape, Color color, int size)
          Add a shape marker to each point on a plot.
 void addTextMarker(String text, Color color, int size, int index)
          Add a text marker to a point.
 void setColor(Color color)
          Set the color for this plot.
 void setLegend(String legend)
          Set the legend.
 

Method Detail

setLegend

void setLegend(String legend)
Set the legend.

Parameters:
legend - plot legend. Cannot be null.

setColor

void setColor(Color color)
Set the color for this plot.

Parameters:
color - color. Cannot be null

addShapeMarker

void addShapeMarker(Shape shape,
                    Color color,
                    int size,
                    int index)
Add a shape marker to a point.

Parameters:
shape - Arrows, Diamonds, etc. Cannot be null.
color - Color of the shape maker. Cannot be null.
size - The size of the shape marker. Must be > 0.
index - The index of the point decorated with a shape marker. Must be >= 0.

addTextMarker

void addTextMarker(String text,
                   Color color,
                   int size,
                   int index)
Add a text marker to a point.

Parameters:
text - Text marker. Cannot be null.
color - Color of text marker. Cannot be null.
size - The size of the text marker. Must be > 0.
index - The index at which the text marker should be added. Must be >= 0.

addShapeMarkers

void addShapeMarkers(Shape shape,
                     Color color,
                     int size)
Add a shape marker to each point on a plot.

Parameters:
shape - Arrows, Diamonds, etc. Cannot be null.
color - Color of the shape maker. Cannot be null.
size - The size of the shape marker. Must be > 0.

addMarker

void addMarker(Marker marker,
               int index)
Add a Marker.

Parameters:
marker - The text or shape marker. Cannot be null.
index - The index at which the text marker should be added. Must be >= 0.

addMarkers

void addMarkers(Marker marker)
Add a Marker to each point on a plot.

Parameters:
marker - The text or shape marker. Cannot be null.