|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.ijchart.xychart.render.AbstractRender
com.ijchart.xychart.render.AbstractWithAxisRender
com.ijchart.xychart.render.xy.AbstractXYRender
com.ijchart.xychart.render.xy.XYShapeRender
public class XYShapeRender
Title: IJChart
Description: a chart library for the Java(tm) platform.
A render that represents data from aXYZNumberChartData
by drawing a color block at each (x, y) point, where the color is a function of the
z-value from the dataset.
Copyright: Copyright (c) 2013
Company:
Field Summary | |
---|---|
static java.awt.Paint |
DEFAULT_GUIDE_LINE_PAINT
The default paint used for drawing the guide lines. |
static java.awt.Stroke |
DEFAULT_GUIDE_LINE_STROKE
The default stroke used for drawing the guide lines. |
static boolean |
DEFAULT_GUIDE_LINE_VISIBLE
The default flag indicating whether or not guide lines should be drawn for every item. |
static java.lang.String |
DEFAULT_LEGEND_LABEL
The legend label. |
static IPaintScale |
DEFAULT_PAINT_SCALE
The default paint scale. |
Constructor Summary | |
---|---|
XYShapeRender(IMatrixDataset dataset)
The constructor. |
|
XYShapeRender(IMatrixDataset dataset,
IPaintScale paintScale,
java.lang.String legendLabel)
The constructor. |
|
XYShapeRender(IMatrixDataset dataset,
java.lang.String legendLabel)
The constructor. |
Method Summary | |
---|---|
java.lang.Object |
clone()
Creates and returns a copy of this object. |
protected IChartShape |
createItemShapeOnly(java.awt.geom.Rectangle2D rect,
java.lang.String text,
java.lang.Object appendParam)
Create a shape with no attribute specified. |
void |
drawAllItems(AbstractValueAxis xAxis,
RectangleEdge xAxisEdge,
AbstractValueAxis yAxis,
RectangleEdge yAxisEdge,
java.awt.geom.Rectangle2D dataArea,
ChartOrientation orientation,
RenderShapeCollection renderShapes,
float alpha)
Draws all data items. |
boolean |
equals(java.lang.Object obj)
Indicates if some other object is "equal to" this one. |
java.awt.Paint |
getGuideLinePaint()
Returns the paint used for drawing the guide lines. |
java.awt.Stroke |
getGuideLineStroke()
Returns the stroke used for drawing the guide lines. |
protected int |
getLegendItemCount()
Returns the count of legends. |
protected java.lang.String[] |
getLegendItemLabels()
Returns the label array for legend item shapes. |
protected IChartShape[] |
getLegendItemShapes(int legendCount)
Returns the shape array of legend items. |
java.lang.String |
getLegendLabel()
Returns the legend label. |
IPaintScale |
getPaintScale()
Returns the paint scale. |
int |
hashCode()
Returns a hash code value for the object. |
boolean |
isGuideLineVisible()
Returns the flag indicating if guide lines should be drawn for every item. |
void |
setGuideLinePaint(java.awt.Paint paint)
Sets the paint used for drawing the guide lines and sends a RenderChangeEvent to all registered listeners. |
void |
setGuideLineStroke(java.awt.Stroke stroke)
Sets the stroke used for drawing the guide lines and sends a RenderChangeEvent to all registered listeners. |
void |
setGuideLineVisible(boolean flag)
Sets the flag indicating if guide lines should be drawn for every item and sends a RenderChangeEvent to all registered listeners. |
void |
setLegendLabel(java.lang.String label)
The legend label. |
void |
setPaintScale(IPaintScale paintScale)
Sets the paint scale and sends a RenderChangeEvent to all registered listeners. |
java.lang.String |
toString()
Returns a string representation of the object. |
Methods inherited from class com.ijchart.xychart.render.xy.AbstractXYRender |
---|
addAnnotation, drawAllAnnotation, getAllAnnotations, removeAllAnnotation |
Methods inherited from class com.ijchart.xychart.render.AbstractWithAxisRender |
---|
createItemShape, createValueMarkerShape, drawIntervalValueMarker, drawValueMarker, getValueAxisOffsetType |
Methods inherited from class java.lang.Object |
---|
finalize, getClass, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
public static final IPaintScale DEFAULT_PAINT_SCALE
public static final java.lang.String DEFAULT_LEGEND_LABEL
public static final boolean DEFAULT_GUIDE_LINE_VISIBLE
public static final java.awt.Paint DEFAULT_GUIDE_LINE_PAINT
public static final java.awt.Stroke DEFAULT_GUIDE_LINE_STROKE
Constructor Detail |
---|
public XYShapeRender(IMatrixDataset dataset)
dataset
- SingleRowDataset
The dataset (null not permitted).public XYShapeRender(IMatrixDataset dataset, java.lang.String legendLabel)
dataset
- SingleRowDataset
The dataset (null not permitted).legendLabel
- String
The legend label.public XYShapeRender(IMatrixDataset dataset, IPaintScale paintScale, java.lang.String legendLabel)
dataset
- SingleRowDataset
The dataset (null not permitted).paintScale
-
The paint scale.legendLabel
- String
The legend label.Method Detail |
---|
public boolean isGuideLineVisible()
public void setGuideLineVisible(boolean flag)
RenderChangeEvent
to all registered listeners.
flag
- boolean
A boolean.public java.awt.Paint getGuideLinePaint()
public void setGuideLinePaint(java.awt.Paint paint)
RenderChangeEvent
to all registered listeners.
paint
- Paint
The paint used for drawing the guide lines (null not permitted).public java.awt.Stroke getGuideLineStroke()
public void setGuideLineStroke(java.awt.Stroke stroke)
RenderChangeEvent
to all registered listeners.
stroke
- Stroke
The stroke used for drawing the guide lines (null not permitted).public IPaintScale getPaintScale()
public void setPaintScale(IPaintScale paintScale)
RenderChangeEvent
to all registered listeners.
paintScale
- IPaintScale
The paint scale.public java.lang.String getLegendLabel()
public void setLegendLabel(java.lang.String label)
label
- String
The legend label (null permitted).public void drawAllItems(AbstractValueAxis xAxis, RectangleEdge xAxisEdge, AbstractValueAxis yAxis, RectangleEdge yAxisEdge, java.awt.geom.Rectangle2D dataArea, ChartOrientation orientation, RenderShapeCollection renderShapes, float alpha)
drawAllItems
in class AbstractXYRender
xAxis
- AbstractValueAxis
The x value axis (null not permitted).xAxisEdge
- RectangleEdge
The x axis edge.yAxis
- AbstractValueAxis
The y value axis (null not permitted).yAxisEdge
- RectangleEdge
The y axis edge (null not permitted).dataArea
- Rectangle2D
The chart data area (null not permitted).orientation
- ChartOrientation
The chart orientation (null not permitted).renderShapes
- RenderShapeCollection
Collects information about the render (null not permitted).alpha
- float
The alpha transparency (in the range 0.0f to 1.0f, where 0.0f is fully transparent,
and 1.0f is fully opaque).protected IChartShape createItemShapeOnly(java.awt.geom.Rectangle2D rect, java.lang.String text, java.lang.Object appendParam)
createItemShapeOnly
in class AbstractRender
rect
- Rectangle2D
The bar rectangle (null not permitted).text
- String
The text (null permitted).appendParam
- Object
The append parameter,used for special propose (null permitted).
protected int getLegendItemCount()
getLegendItemCount
in class AbstractRender
protected java.lang.String[] getLegendItemLabels()
getLegendItemLabels
in class AbstractRender
protected IChartShape[] getLegendItemShapes(int legendCount)
getLegendItemShapes
in class AbstractRender
legendCount
- int
The legend items count.
public boolean equals(java.lang.Object obj)
equals
in class AbstractXYRender
obj
-
the reference object with which to compare.
public int hashCode()
hashCode
in class AbstractXYRender
public java.lang.Object clone() throws java.lang.CloneNotSupportedException
clone
in class AbstractXYRender
java.lang.CloneNotSupportedException
- if the object's class does not
support the Cloneable interface. Subclasses
that override the clone method can also
throw this exception to indicate that an instance cannot
be cloned.
java.lang.Cloneablepublic java.lang.String toString()
toString
in class AbstractXYRender
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |