|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectalgoanim.primitives.Primitive
algoanim.primitives.Square
public class Square
Represents a square defined by an upper left corner and its width.
| Field Summary |
|---|
| Fields inherited from class algoanim.primitives.Primitive |
|---|
gen |
| Constructor Summary | |
|---|---|
Square(SquareGenerator sg,
Node upperLeftCorner,
int theWidth,
java.lang.String name,
DisplayOptions display,
SquareProperties sp)
Instantiates the Square and calls the create() method of the
associated SquareGenerator. |
|
| Method Summary | |
|---|---|
SquareProperties |
getProperties()
Returns the properties of this Square. |
Node |
getUpperLeft()
Returns the upper left corner of this Square. |
int |
getWidth()
Returns the width of this Square. |
void |
setName(java.lang.String newName)
Sets the name of this Primitive. |
| Methods inherited from class algoanim.primitives.Primitive |
|---|
changeColor, exchange, getDisplayOptions, getName, hide, hide, moveBy, moveTo, moveVia, rotate, rotate, show, show |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public Square(SquareGenerator sg,
Node upperLeftCorner,
int theWidth,
java.lang.String name,
DisplayOptions display,
SquareProperties sp)
throws java.lang.IllegalArgumentException
Square and calls the create() method of the
associated SquareGenerator.
sg - the appropriate code Generator.upperLeftCorner - the upper left corner of this Square.theWidth - the width of this Square.name - the name of this Square.display - [optional] the DisplayOptions of this
Square.sp - [optional] the properties of this Square.
java.lang.IllegalArgumentException| Method Detail |
|---|
public int getWidth()
Square.
Square.public SquareProperties getProperties()
Square.
Square.public Node getUpperLeft()
Square.
Square.public void setName(java.lang.String newName)
PrimitivePrimitive.
setName in class PrimitivenewName - the new name for this Primitive.Primitive.setName(java.lang.String)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||