|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectgraphics.AbstractGraphic
graphics.AbstractColorableGraphic
graphics.Ellipse
lab7lib.EllipticalShape
public class EllipticalShape
| Constructor Summary | |
|---|---|
EllipticalShape(Window w)
Creates a new instance of EllipticalShape |
|
| Method Summary | |
|---|---|
java.lang.Integer |
getDx()
Get the x component of the movement vector (the change in x). |
java.lang.Integer |
getDy()
Get the y component of the movement vector (the change in y). |
Degree |
getOrientation()
Gets the orientation (degree of rotation) of the shape |
Vector |
getVector()
Get the vector that controls the movement for this shape. |
void |
setOrientation(Degree degree)
Sets the orientation (degree of rotation) of the shape |
void |
setVector(Vector v)
Change the vector that controls the movement for this shape. |
void |
update()
Update the position and orientation of the fish based on the velocity. |
void |
update(java.util.Observable o,
java.lang.Object arg)
|
| Methods inherited from class graphics.Ellipse |
|---|
actualPaint, getShape |
| Methods inherited from class graphics.AbstractColorableGraphic |
|---|
getColor, paint, setColor |
| Methods inherited from class graphics.AbstractGraphic |
|---|
addMouseListener, addMouseMotionListener, contains, getBounds, getCenterLocation, getContainer, getDimension, getLocation, getMouseListeners, getMouseMotionListeners, getMovement, getRotation, intersects, move, rotate, setCenterLocation, setContainer, setDimension, setLocation, setMovement, setRotation |
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface graphics.IGraphic |
|---|
addMouseListener, addMouseMotionListener, contains, getBounds, getContainer, getMouseListeners, getMouseMotionListeners, getMovement, intersects, setContainer, setMovement |
| Methods inherited from interface graphics.ISizeable |
|---|
getDimension, setDimension |
| Methods inherited from interface graphics.CenterLocatable |
|---|
getCenterLocation, setCenterLocation |
| Methods inherited from interface graphics.ILocatable |
|---|
getLocation, move, setLocation |
| Methods inherited from interface graphics.IRotatable |
|---|
getRotation, rotate, setRotation |
| Constructor Detail |
|---|
public EllipticalShape(Window w)
w - The window where the shape should appear| Method Detail |
|---|
public void setOrientation(Degree degree)
degree - The degree to which the orientation of the shape should be set.public Degree getOrientation()
public void update()
update in interface IUpdatablepublic Vector getVector()
public void setVector(Vector v)
v - The new vector.public java.lang.Integer getDx()
public java.lang.Integer getDy()
public void update(java.util.Observable o,
java.lang.Object arg)
update in interface java.util.Observero - arg - Observer.update(java.util.Observable, java.lang.Object)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||