Class AquaView
java.lang.Object
|
+--AquaView
- public class AquaView
- extends java.lang.Object
Aquarium Lab Series:
An AquaView object provides a graphical view of AquaFish
in an Aquarium.
- Version:
- 10 July 2002
- See Also:
Aquarium
,
AquaFish
Constructor Summary |
AquaView(edu.neu.ccs.gui.BufferedPanel panel,
Aquarium a)
Construct an AquaView object to display a particular
aquarium. |
Method Summary |
void |
show(AquaFish[] fishList)
Show the AquaFish in the Aquarium. |
void |
show(java.util.ArrayList fishList)
Show the AquaFish in the Aquarium. |
void |
showAquarium()
Display only the Aquarium: paint the aquarium blue to cover
up old fish. |
void |
showFish(AquaFish fish)
Display a single AquaFish. |
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
AquaView
public AquaView(edu.neu.ccs.gui.BufferedPanel panel,
Aquarium a)
- Construct an AquaView object to display a particular
aquarium.
- Parameters:
panel
- the graphical panel in which to display environmenta
- the aquarium to display
show
public void show(AquaFish[] fishList)
- Show the AquaFish in the Aquarium.
Paints the aquarium blue to cover up old fish and displays
the fish in the array.
- Parameters:
fishList
- the array of AquaFish to be displayed
show
public void show(java.util.ArrayList fishList)
- Show the AquaFish in the Aquarium.
Paints the aquarium blue to cover up old fish and displays
the fish in the array.
- Parameters:
fishList
- the list of AquaFish to be displayed
showAquarium
public void showAquarium()
- Display only the Aquarium: paint the aquarium blue to cover
up old fish. Not necessary when displaying an entire vector
of fish.
showFish
public void showFish(AquaFish fish)
- Display a single AquaFish.
- Parameters:
fish
- the fish to be displayed
Copyright© 2002 Alyce Brady