|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectsddl.hierarchy.Shape
sddl.hierarchy.Rectangle
public class Rectangle
This Shape describes a standard rectangle. The rectangle can have rounded edges.
Constructor Summary | |
---|---|
Rectangle()
Standard SDDL constructor |
|
Rectangle(double length,
double width)
Standard Java-only constructor |
Method Summary | |
---|---|
Rectangle |
copy()
Returns a copy of this Rectangle |
void |
draw(AbstractPoint location,
java.io.PrintWriter out)
Standard SDDL draw function. |
RefPoint |
getEast(Drawing d)
Returns the eastern point in the rectangle |
double |
getLength()
Standard SDDL getter for the length parameter |
RefPoint |
getNorth(Drawing d)
Returns the northern point in the rectangle |
RefPoint |
getNortheast(Drawing d)
Returns the northeastern point in the rectangle |
RefPoint |
getNorthwest(Drawing d)
Returns the northwestern point in the rectangle |
boolean |
getRound()
Standard SDDL getter for the round parameter |
RefPoint |
getSouth(Drawing d)
Returns the southern point in the rectangle |
RefPoint |
getSoutheast(Drawing d)
Returns the southeastern point in the rectangle |
RefPoint |
getSouthwest(Drawing d)
Returns the southwestern point in the rectangle |
RefPoint |
getWest(Drawing d)
Returns the western point in the rectangle |
double |
getWidth()
Standard SDDL getter for the width parameter |
Path |
obtainPath()
Gives a Path describing the Rectangle. |
void |
setLength(double length)
Standard SDDL setter for the length parameter |
void |
setRound(boolean round)
Standard SDDL setter for the round parameter |
void |
setWidth(double width)
Standard SDDL setter for width parameter |
Methods inherited from class sddl.hierarchy.Shape |
---|
isVisible, setVisible |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public Rectangle()
public Rectangle(double length, double width)
length
- Length of the rectanglewidth
- Width of the rectangleMethod Detail |
---|
public void setLength(double length)
length
- The length of the rectanglepublic void setWidth(double width)
width
- The width of the rectanglepublic void setRound(boolean round)
round
- If edges are to be drawn roundedpublic double getLength()
public double getWidth()
public boolean getRound()
public RefPoint getNorth(Drawing d)
d
- Drawing referencing the Shape
public RefPoint getSouth(Drawing d)
d
- Drawing referencing the Shape
public RefPoint getWest(Drawing d)
d
- Drawing referencing the Shape
public RefPoint getEast(Drawing d)
d
- Drawing referencing the Shape
public RefPoint getNorthwest(Drawing d)
d
- Drawing referencing the Shape
public RefPoint getNortheast(Drawing d)
d
- Drawing referencing the Shape
public RefPoint getSouthwest(Drawing d)
d
- Drawing referencing the Shape
public RefPoint getSoutheast(Drawing d)
d
- Drawing referencing the Shape
public void draw(AbstractPoint location, java.io.PrintWriter out)
Shape
draw
in class Shape
location
- The location of the Shape on the main drawingout
- The file to be written topublic Path obtainPath()
obtainPath
in class Shape
public Rectangle copy()
copy
in class Shape
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |