Class Pump

Class Pump

java.lang.Object
   |
   +----Component
           |
           +----Pump

class Pump
extends Component
A pump component for the nuclear power plant
Version:
1.0
Author:
Henrik Eriksson

pump_bm
Pump images for amimation
pump_crash_bm
Crashed pump image

mouseDown(int, int)
Handle mouseDown events (i.e., clicks on the pump).
paint(Graphics)
Paint operation for pump
rotate()
Rotate the pump one step.

pump_bm
  protected static Image pump_bm[]
Pump images for amimation
pump_crash_bm
  protected static Image pump_crash_bm
Crashed pump image

rotate
  public void rotate()
Rotate the pump one step. (Only pumps with rpm > 0 are rotated.)

paint

  public void paint(Graphics g)
Paint operation for pump
Parameters:
g - The graphics context

mouseDown

  public void mouseDown(int mx,
                        int my)
Handle mouseDown events (i.e., clicks on the pump).
Parameters:
mx - The X coordinate
my - The Y coordinate