com.jinsight.jetchart
Class BarSerie
java.lang.Object
|
+--com.jinsight.jetchart.AbstractSerie
|
+--com.jinsight.jetchart.GraphSerie
|
+--com.jinsight.jetchart.BarSerie
- Direct Known Subclasses:
- StackBarSerie
- public class BarSerie
- extends GraphSerie
This class implements the properties and methods of a bar series.
Field Summary |
static int |
INSIDE
Constant used to display data points legends horizontally and inside
the bars. |
static int |
INSIDE_VERTICAL
Constant used to display data points legends vertically and inside
the bars. |
static int |
TOP
Constant used to display data points legends horizontally and at the top
of the bars. |
Fields inherited from class com.jinsight.jetchart.GraphSerie |
ABOVE_TOP_YAXIS, AREA, BAR, BAR_HLC, BAR_OHLC, BESIDE_TOP_YAXIS, CANDLESTICK, DASHED, EMPTY_CIRCLE_MARK, EMPTY_DIAMOND_MARK, EMPTY_SQUARE_MARK, EMPTY_TRIANGLE_MARK, IMAGE, LEGEND, LINE, LINE_HLC, LINE_OHLC, MARK_SHAPE_LEGEND, POINT, ROUNDED_CANDLESTICK, SOLID, SOLID_CIRCLE_MARK, SOLID_DIAMOND_MARK, SOLID_SQUARE_LEGEND, SOLID_SQUARE_MARK, SOLID_TRIANGLE_MARK, STACKED_BAR, X_MARK |
Constructor Summary |
BarSerie()
Creates a BarSerie object. |
BarSerie(double[] values)
Creates a BarSerie object. |
BarSerie(double[] values,
java.lang.String title)
Creates a BarSerie object. |
Method Summary |
protected void |
finalize()
|
void |
setBorderEnabled(boolean isBorderEnabled)
Enables/disables the borders of the bars. |
void |
setColors(java.awt.Color[] colors)
Sets a color for each bar. |
void |
setMarkLegendPosition(int markLegendPosition)
Sets the position where data points legends are displayed. |
void |
setMarkLegendRoomCheckEnabled(boolean isMarkLegendRoomCheckEnabled)
Enables/disables mark legends room checking. |
void |
setWidth(int barWidth)
Sets bar width. |
Methods inherited from class com.jinsight.jetchart.GraphSerie |
getColor, getMultipleValues, getRegressionLine, getSerieMap, getSerieMap, getSerieMap, getTitle, getType, getValues, removeRegressionLine, setColor, setCoordinatesStatus, setFont, setMarkLegendBackground, setMarkLegendEnabled, setMarkLegendForeground, setMarkLegendOpacityEnabled, setMarksColor, setMarksEnabled, setMarksStyle, setMultipleValues, setStartPoint, setTitle, setTitleFont, setTitlePosition, setToolTipContent, setValues, setValuesQuery |
Methods inherited from class java.lang.Object |
clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
TOP
public static final int TOP
- Constant used to display data points legends horizontally and at the top
of the bars.
INSIDE
public static final int INSIDE
- Constant used to display data points legends horizontally and inside
the bars.
INSIDE_VERTICAL
public static final int INSIDE_VERTICAL
- Constant used to display data points legends vertically and inside
the bars.
BarSerie
public BarSerie()
- Creates a BarSerie object.
Default constructor.
BarSerie
public BarSerie(double[] values)
- Creates a BarSerie object.
- Parameters:
values
- Array of double precision numbers containing series values.- See Also:
AbstractSerie.setValues(double[])
BarSerie
public BarSerie(double[] values,
java.lang.String title)
- Creates a BarSerie object.
- Parameters:
values
- Array of double precision numbers containing series values.title
- String containing series title. The series title is displayed in the legend box.- See Also:
AbstractSerie.setValues(double[])
setColors
public void setColors(java.awt.Color[] colors)
- Sets a color for each bar.
- Parameters:
colors
- An array of Color objects.
setMarkLegendRoomCheckEnabled
public void setMarkLegendRoomCheckEnabled(boolean isMarkLegendRoomCheckEnabled)
- Enables/disables mark legends room checking.
If this method is set to true legends are only displayed inside the bars
if there is enough space to fit them in. Room checking is ignored
if mark legends are horizontally displayed in vertical charts.
Room checking is disabled by default.
- Parameters:
isMarkLegendRoomCheckEnabled
- A boolean value(true/false).- See Also:
setMarkLegendPosition(int)
setMarkLegendPosition
public void setMarkLegendPosition(int markLegendPosition)
- Sets the position where data points legends are displayed.
Default position is the top of the bar. If chart is horizontal
the INSIDE_VERTICAL constant has no effect.
- Parameters:
markLegendPosition
- An integer value.- See Also:
TOP
,
INSIDE
,
INSIDE_VERTICAL
setWidth
public void setWidth(int barWidth)
- Sets bar width. Multiple bar series can be displayed in a chart, each of them
having a different width.
- Parameters:
barWidth
- An integer number.
setBorderEnabled
public void setBorderEnabled(boolean isBorderEnabled)
- Enables/disables the borders of the bars.
Default value is true.
- Parameters:
isBorderEnabled
- A boolean value(true/false)
finalize
protected void finalize()
throws java.lang.Throwable
- Overrides:
finalize
in class GraphSerie