|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectcom.quinncurtis.chart3djava.ChartObj
com.quinncurtis.chart3djava.GraphObj
com.quinncurtis.chart3djava.ChartShape
public class ChartShape
The ChartShape class places arbitrary GeneralPath objects in a chart.
| Field Summary |
|---|
| Constructor Summary | |
|---|---|
ChartShape()
The default ChartShape constructor. |
|
ChartShape(PhysicalCoordinates transform)
This constructor creates a new ChartShape object using the specified scale. |
|
ChartShape(PhysicalCoordinates transform,
java.awt.Shape ashape,
int shapecoordstype,
double x,
double y,
double z,
int npositiontype,
int rotation)
This constructor creates a new ChartShape object using the specified scale, shape, position and rotation. |
|
ChartShape(PhysicalCoordinates transform,
java.awt.Shape ashape,
int shapecoordstype,
double x,
double y,
int npositiontype,
int rotation)
This constructor creates a new ChartShape object using the specified scale, shape, position and rotation. |
|
ChartShape(java.awt.Shape ashape,
int shapecoordstype,
double x,
double y,
double z,
int npositiontype,
int rotation)
This constructor creates a new ChartShape object using the specified scale, shape, position and rotation. |
|
ChartShape(java.awt.Shape ashape,
int shapecoordstype,
double x,
double y,
int npositiontype,
int rotation)
This constructor creates a new ChartShape object using the specified scale, shape, position and rotation. |
|
| Method Summary | |
|---|---|
boolean |
checkIntersection(ChartPoint3D testpoint,
NearestPointData np)
The checkIntersection method. |
java.lang.Object |
clone()
Returns an object that is a clone of this ChartShape object. |
void |
copy(ChartShape source)
Copies the source shape object. |
void |
draw(java.awt.Graphics2D g2)
The draw method for this class. |
void |
drawShape(java.awt.Graphics2D g,
java.awt.geom.GeneralPath path)
Draws a shape into the graphics context using the current ChartShape properties. |
int |
errorCheck(int nerror)
Checks the current shape object for common errors. |
int |
getShapeCoordsType()
Returns the coordinate system of the shape object. |
java.awt.Shape |
getShapeObject()
Returns a reference to the shape object rendered in the chart by this class. |
double |
getShapeRotation()
Returns the rotation of the shape in the normal viewing plane. |
void |
initChartShapeObj(PhysicalCoordinates transform,
java.awt.Shape ashape,
int shapecoordstype,
double x,
double y,
double z,
int npostype,
double rotation)
Initializes the attributes of an ChartShape object. |
void |
initChartShapeObj(PhysicalCoordinates transform,
java.awt.Shape ashape,
int shapecoordstype,
double x,
double y,
int npostype,
double rotation)
Initializes the attributes of an ChartShape object. |
void |
setShapeCoordsType(int shapecoordstype)
Specifies the coordinate system of the shape object. |
void |
setShapeObj(java.awt.Shape s)
Sets the shape object rendered in the chart by this class. |
void |
setShapeRotation(double rotation)
Sets the rotation of the shape in the normal viewing plane. |
| Methods inherited from class com.quinncurtis.chart3djava.ChartObj |
|---|
copy, getChartObjIDCntr, getChartObjType, getThisChartObjID |
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public ChartShape()
public ChartShape(PhysicalCoordinates transform,
java.awt.Shape ashape,
int shapecoordstype,
double x,
double y,
int npositiontype,
int rotation)
transform - The shape object is placed in the coordinate system defined by transform.ashape - A reference to a Shape object.shapecoordstype - Specifies if the coordinate system defining the shape is specified in
physical coordinates, normalized coordinates or window device coordinates. Use one of the position
constants: DEV_POS, PHYS_POS, NORM_GRAPH_POS, NORM_PLOT_POS.x - Specifies the x-value of the shape position.y - Specifies the y-value of the shape position.npositiontype - Specifies the if the position of the shape is specified in physical
coordinates, normalized coordinates or window device coordinates. Use one of the position constants:
DEV_POS, PHYS_POS, NORM_GRAPH_POS, NORM_PLOT_POS.rotation - The rotation, in degrees, of the shape in the normal viewing plane.
public ChartShape(PhysicalCoordinates transform,
java.awt.Shape ashape,
int shapecoordstype,
double x,
double y,
double z,
int npositiontype,
int rotation)
transform - The shape object is placed in the coordinate system defined by transform.ashape - A reference to a Shape object.shapecoordstype - Specifies if the coordinate system defining the shape is specified in
physical coordinates, normalized coordinates or window device coordinates. Use one of the position
constants: DEV_POS, PHYS_POS, NORM_GRAPH_POS, NORM_PLOT_POS.x - Specifies the x-value of the shape position.y - Specifies the y-value of the shape position.z - Specifies the z-value of the shape position.npositiontype - Specifies the if the position of the shape is specified in physical
coordinates, normalized coordinates or window device coordinates. Use one of the position constants:
DEV_POS, PHYS_POS, NORM_GRAPH_POS, NORM_PLOT_POS.rotation - The rotation, in degrees, of the shape in the normal viewing plane.
public ChartShape(java.awt.Shape ashape,
int shapecoordstype,
double x,
double y,
int npositiontype,
int rotation)
ashape - A reference to a Shape object.shapecoordstype - Specifies if the coordinate system defining the shape is specified in
physical coordinates, normalized coordinates or window device coordinates. Use one of the position
constants: DEV_POS, PHYS_POS, NORM_GRAPH_POS, NORM_PLOT_POS.x - Specifies the x-value of the shape position.y - Specifies the y-value of the shape position.npositiontype - Specifies the if the position of the shape is specified in physical
coordinates, normalized coordinates or window device coordinates. Use one of the position constants:
DEV_POS, PHYS_POS, NORM_GRAPH_POS, NORM_PLOT_POS.rotation - The rotation, in degrees, of the shape in the normal viewing plane.
public ChartShape(java.awt.Shape ashape,
int shapecoordstype,
double x,
double y,
double z,
int npositiontype,
int rotation)
ashape - A reference to a Shape object.shapecoordstype - Specifies if the coordinate system defining the shape is specified in
physical coordinates, normalized coordinates or window device coordinates. Use one of the position
constants: DEV_POS, PHYS_POS, NORM_GRAPH_POS, NORM_PLOT_POS.x - Specifies the x-value of the shape position.y - Specifies the y-value of the shape position.z - Specifies the z-value of the shape position.npositiontype - Specifies the if the position of the shape is specified in physical
coordinates, normalized coordinates or window device coordinates. Use one of the position constants:
DEV_POS, PHYS_POS, NORM_GRAPH_POS, NORM_PLOT_POS.rotation - The rotation, in degrees, of the shape in the normal viewing plane.public ChartShape(PhysicalCoordinates transform)
transform - The shape object is placed in the coordinate system defined by transform.| Method Detail |
|---|
public int errorCheck(int nerror)
errorCheck in class GraphObjnerror - Current error state
public void copy(ChartShape source)
source - The source shape object.public java.lang.Object clone()
clone in class GraphObj
public void initChartShapeObj(PhysicalCoordinates transform,
java.awt.Shape ashape,
int shapecoordstype,
double x,
double y,
int npostype,
double rotation)
transform - The shape object is placed in the coordinate system defined by transform.ashape - A reference to a Shape object.shapecoordstype - Specifies if the coordinate system defining the shape is specified in
physical coordinates, normalized coordinates or window device coordinates. Use one of
the position constants: DEV_POS, PHYS_POS, NORM_GRAPH_POS, NORM_PLOT_POS.x - Specifies the x-value of the shape position.y - Specifies the y-value of the shape position.npostype - Specifies the if the position of the shape is specified in physical
coordinates, normalized coordinates or window device coordinates. Use one of the position constants:
DEV_POS, PHYS_POS, NORM_GRAPH_POS, NORM_PLOT_POS.rotation - The rotation, in degrees, of the shape in the normal viewing plane.
public void initChartShapeObj(PhysicalCoordinates transform,
java.awt.Shape ashape,
int shapecoordstype,
double x,
double y,
double z,
int npostype,
double rotation)
transform - The shape object is placed in the coordinate system defined by transform.ashape - A reference to a Shape object.shapecoordstype - Specifies if the coordinate system defining the shape is specified in
physical coordinates, normalized coordinates or window device coordinates. Use one of
the position constants: DEV_POS, PHYS_POS, NORM_GRAPH_POS, NORM_PLOT_POS.x - Specifies the x-value of the shape position.y - Specifies the y-value of the shape position.z - Specifies the z-value of the shape position.npostype - Specifies the if the position of the shape is specified in physical
coordinates, normalized coordinates or window device coordinates. Use one of the position constants:
DEV_POS, PHYS_POS, NORM_GRAPH_POS, NORM_PLOT_POS.rotation - The rotation, in degrees, of the shape in the normal viewing plane.
public void drawShape(java.awt.Graphics2D g,
java.awt.geom.GeneralPath path)
g - The current graphics context.path - The shape is drawn into the current general path.
public boolean checkIntersection(ChartPoint3D testpoint,
NearestPointData np)
checkIntersection in class GraphObjtestpoint - The test pointnp - Nearest point information for data based objects.
public void draw(java.awt.Graphics2D g2)
draw in class GraphObjg2 - The graphics context.public void setShapeRotation(double rotation)
rotation - The rotation (-360 to 360 degrees) of the shape in the normal viewing plane.public double getShapeRotation()
public void setShapeCoordsType(int shapecoordstype)
shapecoordstype - Specifies the if the position of the shape is specified in physical
coordinates, normalized coordinates or window device coordinates. Use one of the position constants:
DEV_POS, PHYS_POS, NORM_GRAPH_POS, NORM_PLOT_POS.public int getShapeCoordsType()
public void setShapeObj(java.awt.Shape s)
s - Sets the shape object rendered in the chart by this class.public java.awt.Shape getShapeObject()
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||