|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.xj.anylogic.engine.presentation.Shape
com.xj.anylogic.engine.presentation.ShapeLineFill
com.xj.anylogic.engine.presentation.ShapeOval
com.xj.anylogic.engine.presentation.ShapeArc
public class ShapeArc
Persistent arc shape.
| Field Summary |
|---|
| Fields inherited from class com.xj.anylogic.engine.presentation.Shape |
|---|
UNKNOWN_NAME |
| Constructor Summary | |
|---|---|
ShapeArc()
Constructs an arc with default attributes. |
|
ShapeArc(boolean ispublic,
double x,
double y,
double rotation,
java.awt.Color lineColor,
java.awt.Color fillColor,
double radiusX,
double radiusY,
double angleStart,
double angle,
double lineWidth,
int lineStyle)
Constructs an arc with specific attributes. |
|
ShapeArc(boolean ispublic,
double x,
double y,
double rotation,
java.lang.Object lineColor,
java.lang.Object fillColor,
double radiusX,
double radiusY,
double angleStart,
double angle,
double lineWidth,
int lineStyle)
Constructs an arc with specific attributes. |
|
| Method Summary | |
|---|---|
ShapeArc |
clone()
Creates and returns a copy of this shape (i.e. new shape instance). |
boolean |
contains(double px,
double py)
Test if the shape contains the point with the given coordinates (relative to this shape's container, i.e. in the same system with the coordinates of this shape, x and y) |
void |
draw(Panel panel,
java.awt.Graphics2D g,
java.awt.geom.AffineTransform xform,
boolean publicOnly)
Draws the arc in a given context |
double |
getAngle()
Returns the angular extent of the arc in radians, clockwise. |
double |
getAngleStart()
Returns the starting angle of the arc (0 means 3 o'clock) in radians, clockwise |
boolean |
onClickAt(double px,
double py,
boolean publicOnly)
Tests if the arc contains the point with the given coordinates and, if yes, executes the shape's reaction on click at that point. |
void |
setAngle(double angle)
Sets the the angular extent of the arc in radians, clockwise. |
void |
setAngleStart(double angleStart)
Sets the starting angle of the arc (0 means 3 o'clock) in radians, clockwise. |
| Methods inherited from class com.xj.anylogic.engine.presentation.ShapeOval |
|---|
getRadiusX, getRadiusY, setRadius, setRadiusX, setRadiusY |
| Methods inherited from class com.xj.anylogic.engine.presentation.ShapeLineFill |
|---|
getFillColor, getFillTexture, getLineColor, getLineStyle, getLineTexture, getLineWidth, setFillColor, setFillColor, setLineColor, setLineColor, setLineStyle, setLineWidth |
| Methods inherited from class com.xj.anylogic.engine.presentation.Shape |
|---|
canHandleClick, getGroup, getName, getPresentable, getRotation, getScaleX, getScaleY, getX, getY, isVisible, onClick, restoreOwner, setPos, setRotation, setScale, setScale, setScaleX, setScaleY, setVisible, setX, setY |
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public ShapeArc()
public ShapeArc(boolean ispublic,
double x,
double y,
double rotation,
java.awt.Color lineColor,
java.awt.Color fillColor,
double radiusX,
double radiusY,
double angleStart,
double angle,
double lineWidth,
int lineStyle)
ispublic - if true, the shape is visible on container's presentationx - the x coordinate of the arc centery - the y coordinate of the arcrotation - the rotation of the arc in radianslineColor - line color of the arcfillColor - fill color of the arcradiusX - "horizontal" radius of the arcradiusY - "vertical" radius of the arcangleStart - the starting angle of the arc (0 means 3 o'clock) in radians, clockwiseangle - the angular extent of the arc in radians, clockwiselineWidth - the line width of the arclineStyle - the line stroke style of the arc (solid, dotted, dashed)
public ShapeArc(boolean ispublic,
double x,
double y,
double rotation,
java.lang.Object lineColor,
java.lang.Object fillColor,
double radiusX,
double radiusY,
double angleStart,
double angle,
double lineWidth,
int lineStyle)
ispublic - if true, the shape is visible on container's presentationx - the x coordinate of the arc centery - the y coordinate of the arcrotation - the rotation of the arc in radianslineColor - line color (or Texture) of the arcfillColor - fill color (or Texture) of the arcradiusX - "horizontal" radius of the arcradiusY - "vertical" radius of the arcangleStart - the starting angle of the arc (0 means 3 o'clock) in radians, clockwiseangle - the angular extent of the arc in radians, clockwiselineWidth - the line width of the arclineStyle - the line stroke style of the arc (solid, dotted, dashed)| Method Detail |
|---|
public void setAngleStart(double angleStart)
angleStart - the starting angle of the arcpublic double getAngleStart()
public void setAngle(double angle)
angle - the the angular extent of the arcpublic double getAngle()
public boolean onClickAt(double px,
double py,
boolean publicOnly)
onClickAt in class ShapeOvalpx - the x coordinate of the clickpy - the y coordinate of the clickpublicOnly - if true, not public shape returns false
public boolean contains(double px,
double py)
Shape
contains in class ShapeOvalpx - the x coordinate relative to this shape's containerpy - the y coordinate relative to this shape's container
public void draw(Panel panel,
java.awt.Graphics2D g,
java.awt.geom.AffineTransform xform,
boolean publicOnly)
draw in class ShapeOvalpanel - the panel where the drawing is doneg - the graphics where the drawing takes placexform - the "original" transform that must be restored before drawingpublicOnly - if true, the shape is only drawn if it is publicpublic ShapeArc clone()
Shape
clone in class ShapeOval
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||