|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.ObjectCSE115.FishBowl.MovingBodyAdapter
CSE115.FishBowl.Fish
public class Fish
A Fish that moves when told to. Created: Thu Sep 29 15:00:55 2005
| Field Summary |
|---|
| Fields inherited from interface NGP.Colorable |
|---|
DEFAULT_GRAY |
| Constructor Summary | |
|---|---|
Fish()
Creates a new Fish instance. |
|
| Method Summary | |
|---|---|
Integer |
getSize()
Returns the size of the Fish. |
void |
setSize(Integer size)
Sets the size of the Fish. |
void |
update()
Update the position and orientation of the fish based on the velocity. |
| Methods inherited from class CSE115.FishBowl.MovingBodyAdapter |
|---|
contains, getBounds, getCenterLocation, getColor, getDimension, getDrawingPanel, getDx, getDy, getLocation, getRotation, getVector, hide, intersects, mouseClicked, mouseDragged, mouseEntered, mouseExited, mouseMoved, mousePressed, mouseReleased, paint, react, setColor, setDimension, setDrawingPanel, setFrameDelay, setLocation, setRotation, setVector, setVelocity, show, startBouncing, stopBouncing |
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public Fish()
Fish instance.
| Method Detail |
|---|
public Integer getSize()
public void setSize(Integer size)
size - the new size of the Fish (must be greater than 0).public void update()
update in interface MovingBodyupdate in class MovingBodyAdapter
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||