jcontrol.ui.vole.meter
Class Fan

java.lang.Object
  |
  +--jcontrol.ui.vole.Component
        |
        +--jcontrol.ui.vole.meter.Fan
All Implemented Interfaces:
Animateable

public class Fan
extends Component
implements Animateable

This class Fanimplements a simple animation that represents a fan that can be used for e.g. system monitor applications.

(C) DOMOLOGIC Home Automation GmbH 2003

Version:
1.0
Author:
Marcus Timmermann

Field Summary
(package private)  java.lang.String name
           
(package private)  boolean whichImage
           
 
Fields inherited from class jcontrol.ui.vole.Component
focusOwner, font, g, height, listener, parent, visible, width, x, y
 
Constructor Summary
Fan(java.lang.String name, int x, int y)
          Create a Fan with the specified name and coordinates.
 
Method Summary
 void animate()
          Animate the fan.
 void paint()
          Paint the fan.
 void setValue(int value)
          Sets the fans value.
 boolean transferFocus()
          Fan can't gain input focus.
 void validate()
          Compute this component's preferred size and assign internal values width and height.
 
Methods inherited from class jcontrol.ui.vole.Component
getBounds, getParent, isVisible, onActionEvent, onKeyEvent, remove, removeFocus, requestFocus, setBounds, setFont, setGraphics, setLocation, setParent, setVisible
 
Methods inherited from class java.lang.Object
clone, equals, finalize, notifyAll, wait
 

Field Detail

name

java.lang.String name

whichImage

boolean whichImage
Constructor Detail

Fan

public Fan(java.lang.String name,
           int x,
           int y)
Create a Fan with the specified name and coordinates.

Parameters:
name -
x -
y -
Method Detail

animate

public void animate()
Animate the fan.

Specified by:
animate in interface Animateable

paint

public void paint()
Paint the fan.

Overrides:
paint in class Component

setValue

public void setValue(int value)
Sets the fans value. If the value is out of the range minvalue .. maxvalue, the value will be cut.

Parameters:
value - the value

transferFocus

public boolean transferFocus()
Fan can't gain input focus.

Overrides:
transferFocus in class Component
Returns:
true, if the focus was transferred successfully.

validate

public void validate()
Compute this component's preferred size and assign internal values width and height.

Overrides:
validate in class Component